Entity
Defined in: src/types/entity.ts:36
An entity as the node returns it, decoded: the fields a query selected, with its attributes as a
map keyed by name. Which fields are populated is decided by the selection, so each may be
undefined.
Queries do not return these: select(), query() and getEntity() lay each one out as a flat
row — the selected entity fields and attributes side by side, typed by the selection and, through
a schema, by its columns.
Implements
Section titled “Implements”Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new Entity(
fields):Entity
Defined in: src/types/entity.ts:47
Parameters
Section titled “Parameters”fields
Section titled “fields”EntityFields = {}
Returns
Section titled “Returns”Entity
Properties
Section titled “Properties”attributes
Section titled “attributes”attributes:
Readonly<Record<string,ArkivValue>> |undefined
Defined in: src/types/entity.ts:45
Attribute names, types and values.
Implementation of
Section titled “Implementation of”EntityFields.attributes
attributeSchema
Section titled “attributeSchema”attributeSchema:
Readonly<Record<string, {indexed:boolean|undefined;type:"bool"|"bytes"|"key"|"i32"|"u64"|"u256"|"dec"|"str"|"addr"; }>> |undefined
Defined in: src/types/entity.ts:44
Attribute names, types and indexing, with no values.
Implementation of
Section titled “Implementation of”EntityFields.attributeSchema
createdAt
Section titled “createdAt”createdAt:
bigint|undefined
Defined in: src/types/entity.ts:40
Block the entity was created at.
Implementation of
Section titled “Implementation of”EntityFields.createdAt
creationFlags
Section titled “creationFlags”creationFlags:
ResolvedCreationFlags|undefined
Defined in: src/types/entity.ts:43
The immutable properties the entity was created with.
Implementation of
Section titled “Implementation of”EntityFields.creationFlags
creator
Section titled “creator”creator:
`0x${string}`|undefined
Defined in: src/types/entity.ts:39
Implementation of
Section titled “Implementation of”EntityFields.creator
expiresAt
Section titled “expiresAt”expiresAt:
bigint|undefined
Defined in: src/types/entity.ts:42
Block the entity expires at.
Implementation of
Section titled “Implementation of”EntityFields.expiresAt
key:
`0x${string}`|undefined
Defined in: src/types/entity.ts:37
Implementation of
Section titled “Implementation of”EntityFields.key
owner:
`0x${string}`|undefined
Defined in: src/types/entity.ts:38
Implementation of
Section titled “Implementation of”EntityFields.owner
updatedAt
Section titled “updatedAt”updatedAt:
bigint|undefined
Defined in: src/types/entity.ts:41
Block the entity was last patched at.
Implementation of
Section titled “Implementation of”EntityFields.updatedAt