Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website] / vendor / symfony / serializer / Mapping / ClassMetadataInterface.php
1 <?php
2
3 /*
4  * This file is part of the Symfony package.
5  *
6  * (c) Fabien Potencier <fabien@symfony.com>
7  *
8  * For the full copyright and license information, please view the LICENSE
9  * file that was distributed with this source code.
10  */
11
12 namespace Symfony\Component\Serializer\Mapping;
13
14 /**
15  * Stores metadata needed for serializing and deserializing objects of specific class.
16  *
17  * Primarily, the metadata stores the set of attributes to serialize or deserialize.
18  *
19  * There may only exist one metadata for each attribute according to its name.
20  *
21  * @internal
22  *
23  * @author Kévin Dunglas <dunglas@gmail.com>
24  */
25 interface ClassMetadataInterface
26 {
27     /**
28      * Returns the name of the backing PHP class.
29      *
30      * @return string The name of the backing class
31      */
32     public function getName();
33
34     /**
35      * Adds an {@link AttributeMetadataInterface}.
36      */
37     public function addAttributeMetadata(AttributeMetadataInterface $attributeMetadata);
38
39     /**
40      * Gets the list of {@link AttributeMetadataInterface}.
41      *
42      * @return AttributeMetadataInterface[]
43      */
44     public function getAttributesMetadata();
45
46     /**
47      * Merges a {@link ClassMetadataInterface} in the current one.
48      */
49     public function merge(ClassMetadataInterface $classMetadata);
50
51     /**
52      * Returns a {@link \ReflectionClass} instance for this class.
53      *
54      * @return \ReflectionClass
55      */
56     public function getReflectionClass();
57 }