ReadTemplate
Defined in: runtime/template.ts:31
Template defines the metadata (property definition) for an item. This is the read-version that does not support any updates.
Extended by
Section titled “Extended by”Type Parameters
Section titled “Type Parameters”TReadItem
Section titled “TReadItem”TReadItem extends ReadItem = ReadItem
Properties
Section titled “Properties”definition
Section titled “definition”
readonlydefinition:TemplateDefinition
Defined in: runtime/template.ts:32
grants
Section titled “grants”
readonlygrants:TemplateGrantInstance[]
Defined in: runtime/template.ts:33
isExtensible
Section titled “isExtensible”
readonlyisExtensible:boolean
Defined in: runtime/template.ts:34
readonlyprn:string
Defined in: runtime/template.ts:35
properties
Section titled “properties”
readonlyproperties:Readonly<Record<string,PropertyDefinition>>
Defined in: runtime/template.ts:36
relations
Section titled “relations”
readonlyrelations:Record<string,RelationDefinition>
Defined in: runtime/template.ts:37
readonlyroles:Record<string,TemplateRoleInstance>
Defined in: runtime/template.ts:38
Methods
Section titled “Methods”getItem()
Section titled “getItem()”getItem(
id):Promise<TReadItem|undefined>
Defined in: runtime/template.ts:45
Returns the item of the given identifier if it is of the type of this template. If the item does not exist, there are insufficient permissions, or the template does not match; will result in undefined.
Parameters
Section titled “Parameters”string
Returns
Section titled “Returns”Promise<TReadItem | undefined>
isType()
Section titled “isType()”isType(
value):value is TReadItem
Defined in: runtime/template.ts:51
Returns true if the supplied item is of the type of this template.
Parameters
Section titled “Parameters”unknown
Returns
Section titled “Returns”value is TReadItem
selectItems()
Section titled “selectItems()”selectItems():
TemplateItemCursorSelector<TReadItem>
Defined in: runtime/template.ts:58
Returns an item selection builder that allows retrieving items that match this template. This will be all items, irrespective of parent-child hierarchy. See the ItemSelector documentation for more.
Returns
Section titled “Returns”TemplateItemCursorSelector<TReadItem>