1 | <?php |
||
25 | class EngineFinder extends AbstractFinder |
||
26 | { |
||
27 | |||
28 | /** |
||
29 | * Find a result based on a specific criteria. |
||
30 | * |
||
31 | * @since 0.1.0 |
||
32 | * |
||
33 | * @param array $criteria Criteria to search for. |
||
34 | * |
||
35 | * @return EngineInterface Result of the search. |
||
1 ignored issue
–
show
|
|||
36 | */ |
||
37 | 17 | public function find(array $criteria) |
|
51 | |||
52 | /** |
||
53 | * Initialize the engines that can be iterated. |
||
54 | * |
||
55 | * @since 0.1.0 |
||
56 | * |
||
57 | */ |
||
58 | 17 | protected function initializeEngines() |
|
64 | |||
65 | /** |
||
66 | * Initialize a single engine by instantiating class name strings and calling closures. |
||
67 | * |
||
68 | * @since 0.1.0 |
||
69 | * |
||
70 | * @param mixed $engine Engine to instantiate. |
||
71 | * |
||
72 | * @return EngineInterface Instantiated engine. |
||
73 | * @throws FailedToInstantiateEngineException If the engine could not be instantiated. |
||
74 | */ |
||
75 | 17 | protected function initializeEngine($engine) |
|
96 | |||
97 | /** |
||
98 | * Get the config key for the Findables definitions. |
||
99 | * |
||
100 | * @since 0.1.0 |
||
101 | * |
||
102 | * @return string Config key use to define the Findables. |
||
103 | */ |
||
104 | 7 | protected function getFindablesConfigKey() |
|
108 | } |
||
109 |
This check compares the return type specified in the
@return
annotation of a function or method doc comment with the types returned by the function and raises an issue if they mismatch.