string
ion\serialize(mixed
$data, [ion\Serializer|array
|null
$serializer = NULL
])Serialize a PHP value as ION data.
Serializes supported PHP values with the optionally provided \ion\Serializer:
NULL
bool
int
float
string
reference
array
\Serializable
, and classes implementing magic and custom __serialize)mixed
$data#array
|null
$serializer# = NULL
string
, serialized ION data