Copied!

Field

Field.php : 11
Extends ValueObject

Base SPI Value object.

All properties of SPI\ValueObject must be serializable for cache & NoSQL use.

Properties

public $fieldDefinitionId

Field.php : 25

Corresponding field definition.

public int $fieldDefinitionId

public $id

Field.php : 18

Field ID.

public int $id

public $languageCode

Field.php : 46

Language code of this Field.

public string $languageCode

public $type

Field.php : 32

Data type name.

public string $type

public $value

Field.php : 39

Value of the field.

public FieldValue $value

public $versionNo

Field.php : 53
public int|null $versionNo

Null if not created yet

Methods

public__clone()

Field.php : 62

Clone object properties.

public __clone() : mixed

Note: clone keyword performs shallow copy of an object. For properties being objects this means that a reference is copied instead of the actual object.

public__construct()

ValueObject.php : 30

Construct object optionally with a set of properties.

public __construct([array<string|int, mixed> $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> [] -

protectedgetProperties()

ValueObject.php : 50

Function where list of properties are returned.

protected getProperties([array<string|int, mixed> $dynamicProperties = [] ]) : array<string|int, mixed>

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>