Zend\Serializer\Serializer::serialize
Generates a storable representation of a value using the default adapter.
Optionally different adapter could be provided as second argument
Signature
public function serialize(mixed
$value,
[string|Adapter
$adapter = null,
[Traversable|null
$adapterOptions = null]] )
Parameters
$value
— mixed$adapter
— object
$adapterOptions
— object- Adapter constructor options
only used to create adapter instance
Returns
- string