1 | <?php |
||
23 | class AnnotationReader implements ReaderInterface |
||
24 | { |
||
25 | /** |
||
26 | * @var string |
||
27 | */ |
||
28 | const READER_NAME = 'annotation'; |
||
29 | |||
30 | /** |
||
31 | * @var DoctrineAnnotationsReaderInterface |
||
32 | */ |
||
33 | protected $reader; |
||
34 | |||
35 | /** |
||
36 | * Имя класса адаптера для чтения анотаций |
||
37 | * |
||
38 | * @var string |
||
39 | */ |
||
40 | protected $doctrineAnnotationReaderClassName = DoctrineAnnotationReader::class; |
||
41 | |||
42 | /** |
||
43 | * Кеш загруженных метаданных |
||
44 | * |
||
45 | * @var MetadataInterface[] |
||
46 | */ |
||
47 | protected $classAnnotations = []; |
||
48 | |||
49 | /** |
||
50 | * |
||
51 | * @throws Exception\AnnotationReaderException |
||
52 | */ |
||
53 | public function __construct() |
||
57 | |||
58 | /** |
||
59 | * Иницилазия |
||
60 | * |
||
61 | * @return void |
||
62 | * @throws Exception\AnnotationReaderException |
||
63 | */ |
||
64 | protected function init() |
||
74 | |||
75 | /** |
||
76 | * Получение метаданных для сервиса, по имени класса сервиса и вызываемому методу |
||
77 | * |
||
78 | * @param string $serviceClassName |
||
79 | * @param string $serviceMethod |
||
80 | * |
||
81 | * @return MetadataInterface |
||
82 | * |
||
83 | * @throws Exception\AnnotationReaderException |
||
84 | * |
||
85 | * @throws \OldTown\Workflow\ZF2\Service\Metadata\Reader\Exception\InvalidDoctrineAnnotationsReaderException |
||
86 | * @throws \OldTown\Workflow\ZF2\Service\Metadata\Storage\Exception\InvalidArgumentMapException |
||
87 | * @throws Exception\InvalidMetadataException |
||
88 | * @throws \OldTown\Workflow\ZF2\Service\Metadata\Storage\Exception\InvalidResultMapException |
||
89 | */ |
||
90 | public function loadMetadataForClassService($serviceClassName, $serviceMethod) |
||
137 | |||
138 | /** |
||
139 | * @return DoctrineAnnotationsReaderInterface |
||
140 | * |
||
141 | * @throws Exception\InvalidDoctrineAnnotationsReaderException |
||
142 | */ |
||
143 | public function getReader() |
||
164 | |||
165 | /** |
||
166 | * @param DoctrineAnnotationsReaderInterface $reader |
||
167 | * |
||
168 | * @return $this |
||
169 | */ |
||
170 | public function setReader(DoctrineAnnotationsReaderInterface $reader) |
||
176 | |||
177 | /** |
||
178 | * Имя класса адаптера для чтения анотаций |
||
179 | * |
||
180 | * @return string |
||
181 | */ |
||
182 | public function getDoctrineAnnotationReaderClassName() |
||
186 | |||
187 | /** |
||
188 | * Устанавливает имя класса адаптера для чтения анотаций |
||
189 | * |
||
190 | * @param string $doctrineAnnotationReaderClassName |
||
191 | * |
||
192 | * @return $this |
||
193 | */ |
||
194 | public function setDoctrineAnnotationReaderClassName($doctrineAnnotationReaderClassName) |
||
200 | } |
||
201 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: