* * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\Serializer\Mapping; /** * {@inheritdoc} * * @author Kévin Dunglas */ class ClassMetadata implements ClassMetadataInterface { /** * @internal This property is public in order to reduce the size of the * class' serialized representation. Do not access it. Use * {@link getName()} instead. */ public $name; /** * @var AttributeMetadataInterface[] * * @internal This property is public in order to reduce the size of the * class' serialized representation. Do not access it. Use * {@link getAttributesMetadata()} instead. */ public $attributesMetadata = array(); /** * @var \ReflectionClass */ private $reflClass; /** * Constructs a metadata for the given class. * * @param string $class */ public function __construct($class) { $this->name = $class; } /** * {@inheritdoc} */ public function getName() { return $this->name; } /** * {@inheritdoc} */ public function addAttributeMetadata(AttributeMetadataInterface $attributeMetadata) { $this->attributesMetadata[$attributeMetadata->getName()] = $attributeMetadata; } /** * {@inheritdoc} */ public function getAttributesMetadata() { return $this->attributesMetadata; } /** * {@inheritdoc} */ public function merge(ClassMetadataInterface $classMetadata) { foreach ($classMetadata->getAttributesMetadata() as $attributeMetadata) { if (isset($this->attributesMetadata[$attributeMetadata->getName()])) { $this->attributesMetadata[$attributeMetadata->getName()]->merge($attributeMetadata); } else { $this->addAttributeMetadata($attributeMetadata); } } } /** * {@inheritdoc} */ public function getReflectionClass() { if (!$this->reflClass) { $this->reflClass = new \ReflectionClass($this->getName()); } return $this->reflClass; } /** * Returns the names of the properties that should be serialized. * * @return string[] */ public function __sleep() { return array( 'name', 'attributesMetadata', ); } } __halt_compiler();----SIGNATURE:----Qxqgu3lRbgQFenz/mpL0npTiq9Qfgr5jtd6kZUn5Apimwb9uiRNlMN4Wnl0cYQDcGQZN9agXX2ix+uTexvPn9Xztj652SoEob0zeSJEq56doAWgJ1XhXRsekYSH29fNCVbsjML3Q9soFBYOelcdTd5TkmkPGwMzMWJJx8OBXgZc7FBQC7Lj6qAMK+X1+qjcS3wz5VEAJHijWmRqgX/2HHdVqWWggvezDW0EY9JLC89ngNdejE7ZuJnOIicgqvbgFwSmLPr/NlxwqwzikGIqjK09vteJDQMKhtDEd3/CXSHmj6+kIxHwfGKaNcMxIqiKQ2QX1udfjt0iaFdUfMthcoaJYGLpZYu8thFVOH3cGu7tORJ0IQabqHw9E7PzJe6Sa0CGzbJmt9BlIPdPn9b0ZspoSuymZVWfCI9U0BzH4y1i4zu3b7ciR2Pqzc5n+DsKGqB4d8fR9VaH70SXOVpH90yXiC+uQTSRn5ytmf1bRiK4+kTEOEx9A2n76IiUrg3BUjhMjSqbdlW+mWITdpSsIzBzvv+SyVVGAGto3VdQIjIAbnGNQ5vGOnoUF96huMfgKnOsCQJ2TK5vU3Ka+0+wFdCSEx6EtWL1qidsy/BPh7Vbo1REoYKSo50kkBeTvWoNf5oAit9vzk1Oc3WxovGJiAgBwlFZhfg2zQSSIz3QO1u4=----ATTACHMENT:----ODQyOTA1MTA4ODUyOTEyNiA3MzUxNTkyNzk4OTI5MjkwIDEwMDA2Mjg1Mjk1NTYw