1 | <?php |
||
12 | class FilterUtils |
||
13 | { |
||
14 | /** |
||
15 | * Returns a list of filters instances, order by priority (higher priority first). |
||
16 | * Note: a filter is an annotation that is also a middleware. |
||
17 | * |
||
18 | * The middleware must have a __invoke method with signature: |
||
19 | * |
||
20 | * __invoke(ServerRequestInterface $request, $next, ContainerInterface $container) |
||
21 | * |
||
22 | * @param ReflectionMethod $refMethod the reference method extended object. |
||
23 | * @param object $controller the controller the annotation was in. |
||
24 | * @param AnnotationReader $reader |
||
25 | * |
||
26 | * @return array Array of filter instances sorted by priority. |
||
27 | */ |
||
28 | public static function getFilters(ReflectionMethod $refMethod, $controller, AnnotationReader $reader) : array |
||
65 | } |
||
66 |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.