Base SPI Value object.
All properties of SPI\ValueObject must be serializable for cache & NoSQL use.
Properties¶
$data¶
Mixed field data.
|
|
Either a scalar (primitive), null or an array (map) of scalar values.
Note: For the legacy storage engine we will need adaptors to map them to the existing database fields, like data_int, data_float, data_text.
$externalData¶
Mixed external field data.
|
|
Data which is not stored in the field but at an external place. This data is processed by the field type storage interface method storeFieldData, if used by the FieldType, otherwise null.
Either a primitive, an array (map) or an object If object it must be serializable, for instance DOMDocument is not valid object.
$sortKey¶
A value which can be used for sorting.
|
|
Note: For the "old" storage engine we will need adaptors to map them to the existing database fields, like sort_key_int, sort_key_string
Methods¶
__construct() ¶
Construct object optionally with a set of properties.
|
|
Readonly properties values must be set using $properties as they are not writable anymore after object has been created.
Parameters
Name | Type | Default value | Description |
---|---|---|---|
$properties | array<string|int, mixed> | [] | - |
getProperties() ¶
Function where list of properties are returned.
|
|
Used by attributes(), override to add dynamic properties
Parameters
Name | Type | Default value | Description |
---|---|---|---|
$dynamicProperties | array<string|int, mixed> | [] |
Additional dynamic properties exposed on the object |
Return values
array<string|int, mixed>