Version 1
[yaffs-website] / vendor / symfony / validator / PropertyMetadataInterface.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\Validator;
13
14 /**
15  * A container for validation metadata of a property.
16  *
17  * What exactly you define as "property" is up to you. The validator expects
18  * implementations of {@link MetadataInterface} that contain constraints and
19  * optionally a list of named properties that also have constraints (and may
20  * have further sub properties). Such properties are mapped by implementations
21  * of this interface.
22  *
23  * @author Bernhard Schussek <bschussek@gmail.com>
24  *
25  * @see MetadataInterface
26  * @deprecated since version 2.5, to be removed in 3.0.
27  *             Use {@link Mapping\PropertyMetadataInterface} instead.
28  */
29 interface PropertyMetadataInterface extends MetadataInterface
30 {
31     /**
32      * Returns the name of the property.
33      *
34      * @return string The property name
35      */
36     public function getPropertyName();
37
38     /**
39      * Extracts the value of the property from the given container.
40      *
41      * @param mixed $containingValue The container to extract the property value from
42      *
43      * @return mixed The value of the property
44      */
45     public function getPropertyValue($containingValue);
46 }