trait TransformableData

Methods

array
transform(TransformationContextFactory|TransformationContext|null $transformationContext = null)

Transform the data object to an array.

array
all()

Get all visible properties without transforming their values.

array
toArray()

Get the data object as an array.

string
toJson(int $options = 0)

Convert the data object to its JSON representation.

array
jsonSerialize()

Get the data that should be serialized to JSON.

Details

at line 20
array transform(TransformationContextFactory|TransformationContext|null $transformationContext = null)

Transform the data object to an array.

Parameters

TransformationContextFactory|TransformationContext|null $transformationContext

Return Value

array

at line 38
array all()

Get all visible properties without transforming their values.

Return Value

array

at line 52
array toArray()

Get the data object as an array.

Return Value

array

at line 60
string toJson(int $options = 0)

Convert the data object to its JSON representation.

Parameters

int $options

Return Value

string

at line 70
array jsonSerialize()

Get the data that should be serialized to JSON.

Return Value

array