class CollectionToArrayTransformer implements DataTransformerInterface

Methods

mixed
transform(Collection $collection)

Transforms a collection into an array.

mixed
reverseTransform(mixed $array)

Transforms choice keys into entities.

Details

at line line 33
mixed transform(Collection $collection)

Transforms a collection into an array.

Parameters

Collection $collection A collection of entities

Return Value

mixed The value in the transformed representation

Exceptions

TransformationFailedException

at line line 59
mixed reverseTransform(mixed $array)

Transforms choice keys into entities.

Parameters

mixed $array An array of entities

Return Value

mixed The value in the original representation