1 | <?php |
||
12 | class AnnotationDefinitionProvider implements DefinitionProviderInterface |
||
13 | { |
||
14 | /** |
||
15 | * Registered annotation processors |
||
16 | * |
||
17 | * @var AnnotationProcessorInterface[] |
||
18 | */ |
||
19 | private $processors = []; |
||
20 | |||
21 | /** |
||
22 | * Cache of created definitions |
||
23 | * |
||
24 | * @var array |
||
25 | */ |
||
26 | private $definitionCache = []; |
||
27 | |||
28 | /** |
||
29 | * Register annotation processor |
||
30 | * |
||
31 | * @param AnnotationProcessorInterface $processor |
||
32 | */ |
||
33 | public function registerProcessor(AnnotationProcessorInterface $processor) |
||
37 | |||
38 | /** |
||
39 | * {@inheritdoc} |
||
40 | */ |
||
41 | public function getDefinition(string $class): Definition |
||
51 | 1 | ||
52 | 1 | /** |
|
53 | 1 | * Create definition for given class |
|
54 | * |
||
55 | 1 | * @param \ReflectionClass $reflection |
|
56 | * @return Definition |
||
57 | 18 | */ |
|
58 | protected function createDefinition(\ReflectionClass $reflection): Definition |
||
80 | } |