1 | <?php |
||
10 | abstract class Mapper implements MapperInterface { |
||
11 | |||
12 | /** |
||
13 | * @const integer |
||
14 | */ |
||
15 | const MEMORY_ANNOTATION_ADAPTER = 1; |
||
16 | |||
17 | /** |
||
18 | * @const integer |
||
19 | */ |
||
20 | const FILES_ANNOTATION_ADAPTER = 2; |
||
21 | |||
22 | /** |
||
23 | * @const integer |
||
24 | */ |
||
25 | const APC_ANNOTATION_ADAPTER = 3; |
||
26 | |||
27 | /** |
||
28 | * @const integer |
||
29 | */ |
||
30 | const X_CACHE_ANNOTATION_ADAPTER = 4; |
||
31 | |||
32 | /** |
||
33 | * @var string |
||
34 | */ |
||
35 | private $outputClass; |
||
36 | |||
37 | /** |
||
38 | * @var object |
||
39 | */ |
||
40 | private $outputObject; |
||
41 | |||
42 | /** |
||
43 | * @var integer |
||
44 | */ |
||
45 | private $annotationAdapterType; |
||
46 | |||
47 | /** |
||
48 | * @var Transforms |
||
49 | */ |
||
50 | private $transforms; |
||
51 | |||
52 | /** |
||
53 | * @var boolean |
||
54 | */ |
||
55 | private $validation; |
||
56 | |||
57 | /** |
||
58 | * @var array |
||
59 | */ |
||
60 | private $skipAttributes; |
||
61 | |||
62 | /** |
||
63 | * @return string |
||
64 | */ |
||
65 | 47 | public function getOutputClass() { |
|
68 | |||
69 | /** |
||
70 | * @param string $class |
||
71 | * @return $this |
||
72 | */ |
||
73 | 50 | protected function setOutputClassInternal($class) { |
|
79 | |||
80 | /** |
||
81 | * @return object |
||
82 | */ |
||
83 | 47 | public function getOutputObject() { |
|
86 | |||
87 | /** |
||
88 | * @param object $object |
||
89 | * @return $this |
||
90 | */ |
||
91 | 15 | protected function setOutputObjectInternal($object) { |
|
97 | |||
98 | /** |
||
99 | * @return integer |
||
100 | */ |
||
101 | 50 | public function getAnnotationAdapterType() { |
|
104 | |||
105 | /** |
||
106 | * @param integer $adapter |
||
107 | * @return $this |
||
108 | */ |
||
109 | 50 | public function setAnnotationAdapterType($adapter) { |
|
114 | |||
115 | /** |
||
116 | * @return Transforms |
||
117 | */ |
||
118 | 47 | public function getTransforms() { |
|
121 | |||
122 | /** |
||
123 | * @param Transforms|null $transforms |
||
124 | * @return $this |
||
125 | */ |
||
126 | 36 | public function setTransforms(Transforms $transforms = null) { |
|
131 | |||
132 | /** |
||
133 | * @return boolean |
||
134 | */ |
||
135 | 47 | public function hasValidation() { |
|
138 | |||
139 | /** |
||
140 | * @return $this |
||
141 | */ |
||
142 | 12 | public function disableValidation() { |
|
147 | |||
148 | /** |
||
149 | * @return $this |
||
150 | */ |
||
151 | public function enableValidation() { |
||
156 | |||
157 | /** |
||
158 | * @param boolean $validation |
||
159 | * @return $this |
||
160 | */ |
||
161 | 47 | public function setValidation($validation) { |
|
166 | |||
167 | /** |
||
168 | * @param array $attributes |
||
169 | * @return $this |
||
170 | */ |
||
171 | 47 | public function setSkipAttributes(array $attributes = []) { |
|
176 | |||
177 | /** |
||
178 | * @return array |
||
179 | */ |
||
180 | 47 | public function getSkipAttributes() { |
|
183 | |||
184 | /** |
||
185 | * @param string|object $outputClassOrObject |
||
186 | * @param integer $adapter |
||
187 | */ |
||
188 | 50 | public function __construct($outputClassOrObject, $adapter = self::MEMORY_ANNOTATION_ADAPTER) { |
|
194 | |||
195 | /** |
||
196 | * @param string|object $outputClassOrObject |
||
197 | * @return $this |
||
198 | */ |
||
199 | 50 | private function setOutputClassOrObject($outputClassOrObject) { |
|
208 | |||
209 | } |