private function Instantiator::getSerializationFormat in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/doctrine/instantiator/src/Doctrine/Instantiator/Instantiator.php \Doctrine\Instantiator\Instantiator::getSerializationFormat()
Verifies if the given PHP version implements the `Serializable` interface serialization with an incompatible serialization format. If that's the case, use serialization marker "C" instead of "O".
@link http://news.php.net/php.internals/74654
Parameters
ReflectionClass $reflectionClass:
Return value
string the serialization format marker, either self::SERIALIZATION_FORMAT_USE_UNSERIALIZER or self::SERIALIZATION_FORMAT_AVOID_UNSERIALIZER
1 call to Instantiator::getSerializationFormat()
- Instantiator::buildFactory in vendor/
doctrine/ instantiator/ src/ Doctrine/ Instantiator/ Instantiator.php - Builds a {invoking its constructor.
File
- vendor/
doctrine/ instantiator/ src/ Doctrine/ Instantiator/ Instantiator.php, line 236
Class
- Instantiator
- @author Marco Pivetta <ocramius@gmail.com>
Namespace
Doctrine\InstantiatorCode
private function getSerializationFormat(ReflectionClass $reflectionClass) {
if ($this
->isPhpVersionWithBrokenSerializationFormat() && $reflectionClass
->implementsInterface('Serializable')) {
return self::SERIALIZATION_FORMAT_USE_UNSERIALIZER;
}
return self::SERIALIZATION_FORMAT_AVOID_UNSERIALIZER;
}