$defaultData
$defaultData : array
Holds the default values of this configuration object.
A basic metadata container.
Abstract implementation of \Charcoal\Model\MetadataInterface.
This class also implements the ArrayAccess
, so properties can be accessed with []
.
The LoadableInterface
is also implemented, mostly through LoadableTrait
.
setDefaultData(array $defaultData) : \Charcoal\Model\MetadataInterface
Set the object's default values.
array | $defaultData | An associative array. |
Chainable
setProperties(array $properties) : \Charcoal\Model\MetadataInterface
Set the properties.
array | $properties | One or more properties. |
If parameter is not an array.
Chainable
setPropertyObject(string $propertyIdent, \Charcoal\Property\PropertyInterface $propertyObject) : \Charcoal\Model\MetadataInterface
Assign an instance of {@see PropertyInterface} to the given property.
string | $propertyIdent | The property indentifer. |
\Charcoal\Property\PropertyInterface | $propertyObject | The property, as an object. |
Chainable
setSources(array $sources) : \Charcoal\Model\ModelMetadata
array | $sources | The available sources for this model. |
Chainable
addSource(string $sourceIdent, mixed $source) : \Charcoal\Model\ModelMetadata
string | $sourceIdent | The source identifier. |
mixed | $source | The source data. |
Chainable
setDefaultSource(string $defaultSource) : \Charcoal\Model\ModelMetadata
string | $defaultSource | The default source identifier. |
If the argument is not a string.
Chainable