WHFSFile::UpdateMetadata (open)

Update the metadata for this whfs object. Throws on invalid data.

Syntax

LOADLIB "mod::system/lib/internal/whfs/objects.whlib";

MACRO UpdateMetadata(RECORD newmetadata, RECORD options)

Parameters

RECORD newmetadata

New metadata. All cells are optional.

creationdate

Creationdate for this object (datetime)

data

Data of the file (blob, files only)

description

Description of the object (string, max 2048 characters)

externallink

URL this file links to (string, files only)

filelink

Id of object this file links to (integer, files only)

indexdoc

Id of indexdocument of this folder (integer, folders only, must link to file within this folder)

keywords

Keywords (string, max 1024 characters)

modificationdate

Modificationdate for this object (datetime)

name

Name of this object (string, must check ok with IsValidWHFSName);

ordering

Relative ordering vs other objects in the parent folder (integer)

publish

Whether this file is published. Ignored for non-publishable file types. (boolean, files only)

published

Publication status of this file is published (integer, files only)

title

Title of the object (string, max 256 characters)

type

Id of the type of this object (integer)

RECORD options

Options

BOOLEAN setindex

If TRUE, make this file the index of its parent folder

Description

Modification date and modified by are updated when the data or type of a file is updated. Auto-detects and updates type, title, description and keywords if not specified when replacing a 0-byte file.