PHP Класс Devise\Pages\Collections\CollectionFields
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
Показать файл
Открыть проект
Открытые методы
Метод |
Описание |
|
__construct ( array $fields ) |
Create a new collection fields object
from an array of fields |
|
__get ( string $name ) : FieldValue |
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) |
|
Защищенные методы
Метод |
Описание |
|
hydrate ( Field $fields ) : void |
Loop over the array of fields and
assign each field's key as the key
that we will use to access that field's
values on this collection fields object. |
|
Описание методов
__construct()
публичный метод
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)
public __get ( string $name ) : FieldValue |
$name |
string |
|
Результат |
Devise\Pages\Fields\FieldValue |
|
hydrate()
защищенный метод
Loop over the array of fields and
assign each field's key as the key
that we will use to access that field's
values on this collection fields object.