SerializesAndRestoresModelIdentifiers
trait SerializesAndRestoresModelIdentifiers
Methods
mixed
getSerializedPropertyValue(mixed $value, bool $withRelations = true)
Get the property value prepared for serialization.
mixed
getRestoredPropertyValue(mixed $value)
Get the restored property value after deserialization.
getQueryForModelRestoration(Model $model, array|int|string $ids)
Get the query for model restoration.
Details
at line 20
protected mixed
getSerializedPropertyValue(mixed $value, bool $withRelations = true)
Get the property value prepared for serialization.
at line 54
protected mixed
getRestoredPropertyValue(mixed $value)
Get the restored property value after deserialization.
at line 68
protected Collection
restoreCollection(ModelIdentifier $value)
Restore a queueable collection instance.
at line 109
Model
restoreModel(ModelIdentifier $value)
Restore the model from the model identifier instance.