# Serialize

The Serialize component is in charge of handling variable serialize (opens new window).

# Serialize a variable

use Chevere\Components\Serialize\Serialize;

$serialize = new Serialize(var: $foo);

The toString method is used to access the serialized variable.

$serialize->toString();

# Deserialize a variable

The Deserialize component is in charge of handling unserialize (opens new window).

use Chevere\Components\Serialize\Deserialize;

$deserialize = new Deserialize(serialized: $bar);

# Access variable

The var method is used to access the deserialized variable.

$deserialize->var();

# Variable type

The type method is used to access the deserialized variable type.

$deserialize->type();
Last Updated: 7/22/2021, 11:12:42 PM