ExampleArrayble

Type
Class
Namespace
craft\test\mockclasses\arrayable
Inherits
craft\test\mockclasses\arrayable\ExampleArrayble
Implements
yii\base\Arrayable
Uses traits
yii\base\ArrayableTrait
Since
3.2.0

Class ExampleArrayble

View source

# Public Properties

# exampleArrayableParam

Type
string

View source

# extraField

Type
string

View source

# Public Methods

Method Description
extraFields()
fields() Returns the list of fields that should be returned by default by toArray() when no specific fields are specified.
toArray() Converts the model into an array.

# extraFields()

View source

Returns

array

# Protected Methods

Method Description
extractFieldsFor() Extract nested fields from a fields collection for a given root field Nested fields are separated with dots (.). e.g: "item.id" The previous example would extract "id".
extractRootFields() Extracts the root field names from nested fields.
resolveFields() Determines which fields can be returned by toArray().