CollectionFields
class CollectionFields
This classes purpose is to act as a container for fields on the collection level. A collection can have multiple fields, e.g.
myCollection->field1->someProperty myCollection->field2->someProperty
We hydrate all the fields on construction of this object. If a field is not found on this collection fields object then a generic FieldValue({}) is returned so that we don't run into NullPointerExceptions
Methods
Create a new collection fields object from an array of fields
This magic method is used whenever we attempt to access a field key that doesn't exist on this CollectionFields container so that we don't return null (in case that we are chaining things)
Details
at line 26
__construct(array $fields)
Create a new collection fields object from an array of fields
at line 58
FieldValue
__get(string $name)
This magic method is used whenever we attempt to access a field key that doesn't exist on this CollectionFields container so that we don't return null (in case that we are chaining things)