trait SerializableObjectTrait

Methods

array
jsonSerialize()

No description

void
onSerialize()

Optional: Called before serialization (e.g. to remember/convert an unserializable prop)

void
onUnserialize()

Optional: Called after unserialize (e.g. load from db / recover or connect resource)

array|null
serializePropertiesInclude()

Optional: Override this method and specify the properties to include during serialize null = All Properties will be serialized (default) [] = No Properties will be serialized ['id'] = $this->id will be serialized

static object
unserializeObject(SerializedObjectHelper $SerializedObjectHelper)

No description

static object
unserializeObjectFromJSON(string $json)

No description

Details

at line 16
array jsonSerialize()

No description

Return Value

array

Exceptions

ReflectionException

at line 219
void onSerialize()

Optional: Called before serialization (e.g. to remember/convert an unserializable prop)

Return Value

void

at line 225
void onUnserialize()

Optional: Called after unserialize (e.g. load from db / recover or connect resource)

Return Value

void

at line 24
SerializedObjectHelper serializeObject()

No description

at line 212
protected array|null serializePropertiesInclude()

Optional: Override this method and specify the properties to include during serialize null = All Properties will be serialized (default) [] = No Properties will be serialized ['id'] = $this->id will be serialized

Return Value

array|null

at line 90
static object unserializeObject(SerializedObjectHelper $SerializedObjectHelper)

No description

Parameters

SerializedObjectHelper $SerializedObjectHelper

Return Value

object

Exceptions

ReflectionException

at line 121
static object unserializeObjectFromJSON(string $json)

No description

Parameters

string $json

Return Value

object

Exceptions

JsonException
ReflectionException