A lightweight, serialisable summary of a WebDAV resource (a file or a folder), used to pass basic identifying information about a resource to templates or GraalJS controller code without exposing the underlying Resource object itself.


Properties

PropertyReturnsDescription
contentTypeStringThe file's content type. Null for folders.
hashStringThe file's content hash. Null for folders.
hrefStringThe resource's href, relative to the website it is in.
iscollectionbooleanWhether this resource is a folder (collection) rather than a file.
nameStringThe resource's name, ie the last path segment.
titleStringThe resource's display title.

Methods

getName()

Returns: String

The resource's name, ie the last path segment.

getHref()

Returns: String

The resource's href, relative to the website it is in.

getTitle()

Returns: String

The resource's display title.

getIscollection()

Returns: boolean

Whether this resource is a folder (collection) rather than a file.

getContentType()

Returns: String

The file's content type. Null for folders.

getHash()

Returns: String

The file's content hash. Null for folders.

To get full access to the Kademi Hub existing customers can login here, or new customers can register here.