1 | <?php |
||
22 | class PropertyMetadata extends GenericMetadata implements PropertyMetadataInterface |
||
23 | { |
||
24 | /** |
||
25 | * @var string |
||
26 | * @internal |
||
27 | */ |
||
28 | public $propertyName; |
||
29 | |||
30 | /** |
||
31 | * @var string |
||
32 | * @internal |
||
33 | */ |
||
34 | public $setter; |
||
35 | |||
36 | /** |
||
37 | * @var string |
||
38 | * @internal |
||
39 | */ |
||
40 | public $dataPath; |
||
41 | |||
42 | /** |
||
43 | * @var string |
||
44 | * @internal |
||
45 | */ |
||
46 | public $dataType; |
||
47 | |||
48 | /** |
||
49 | * @var mixed |
||
50 | * @internal |
||
51 | */ |
||
52 | public $dataTypeParams; |
||
53 | |||
54 | /** |
||
55 | * @var string|null |
||
56 | * @internal |
||
57 | */ |
||
58 | public $converter; |
||
59 | |||
60 | /** |
||
61 | * Constructor |
||
62 | * |
||
63 | * @param string $property |
||
64 | * @param string $className |
||
65 | */ |
||
66 | 17 | public function __construct($property, $className) |
|
67 | { |
||
68 | 17 | parent::__construct($className); |
|
69 | |||
70 | 17 | $this->propertyName = $property; |
|
71 | 17 | } |
|
72 | |||
73 | /** |
||
74 | * @inheritdoc |
||
75 | */ |
||
76 | 15 | public function getPropertyName() |
|
80 | |||
81 | /** |
||
82 | * @inheritdoc |
||
83 | */ |
||
84 | 9 | public function getSetter() |
|
88 | |||
89 | /** |
||
90 | * Sets property setter |
||
91 | * |
||
92 | * @param string|null $setter |
||
93 | * @return $this |
||
94 | */ |
||
95 | 8 | public function setSetter($setter = null) { |
|
100 | |||
101 | /** |
||
102 | * @return string |
||
103 | */ |
||
104 | 8 | public function getDataPath() |
|
108 | |||
109 | /** |
||
110 | * @param string|null $dataPath |
||
111 | * @return $this |
||
112 | */ |
||
113 | 16 | public function setDataPath($dataPath = null) |
|
119 | |||
120 | /** |
||
121 | * Returns property data type |
||
122 | * |
||
123 | * @return string |
||
124 | */ |
||
125 | 15 | public function getDataType() |
|
129 | |||
130 | /** |
||
131 | * Sets property data type |
||
132 | * |
||
133 | * @param string $dataType |
||
134 | * @return $this |
||
135 | */ |
||
136 | 16 | public function setDataType($dataType) |
|
142 | |||
143 | /** |
||
144 | * Returns additional data type params |
||
145 | * |
||
146 | * @return mixed |
||
147 | */ |
||
148 | 15 | public function getDataTypeParams() |
|
152 | |||
153 | /** |
||
154 | * Sets additional data type params |
||
155 | * |
||
156 | * @param mixed $dataTypeParams |
||
157 | * @return $this |
||
158 | */ |
||
159 | 16 | public function setDataTypeParams($dataTypeParams = null) |
|
165 | |||
166 | /** |
||
167 | * @return string|null |
||
168 | */ |
||
169 | 7 | public function getConverter() |
|
173 | |||
174 | /** |
||
175 | * @param string|null $converter |
||
176 | * @return $this |
||
177 | */ |
||
178 | 16 | public function setConverter($converter) |
|
184 | } |
||
185 |