public static function PhpSerialize::encode in Service Container 7.2
Same name and namespace in other branches
- 7 lib/Drupal/Component/Serialization/PhpSerialize.php \Drupal\Component\Serialization\PhpSerialize::encode()
Encodes data into the serialization format.
Parameters
mixed $data: The data to encode.
Return value
string The encoded data.
Overrides SerializationInterface::encode
File
- lib/
Drupal/ Component/ Serialization/ PhpSerialize.php, line 18 - Contains \Drupal\Component\Serialization\PhpSerialize.
Class
- PhpSerialize
- Default serialization for serialized PHP.
Namespace
Drupal\Component\SerializationCode
public static function encode($data) {
return serialize($data);
}