CollectionData
A piece of data belonging to a collection
- CollectionData
- .id :
string
- .instanceId :
string
- .value :
DataType
- .shallowValue :
DataType
- .set(value) ⇒
this
- .patch(value) ⇒
this
- .delete() ⇒
this
- .clean() ⇒
this
- .id :
.id : string
The internal id of the state with an instance prefix
.instanceId : string
The internal id of the state with an instance prefix
.value : DataType
Get the value of the data instance
.shallowValue : DataType
Get the shallow value of the data instance (no foreign key values injected)
.set(value) ⇒ this
Set the value of the data instance
Returns: this
The data instance
Param | Type | Description |
---|---|---|
value | DataType | The value to set |
.patch(value) ⇒ this
Patch the current value of the state
Returns: this
The data instance
Param | Type | Description |
---|---|---|
value | DataType | A value of the state to merge with the current value |
.delete() ⇒ this
Delete the data instance
Returns: this
The data instance
.clean() ⇒ this
Clean this data instance (remove all watchers & remove the state from the instance)
Returns: this
The data instance