1 | <?php |
||
20 | class PriorityMiddleware implements PriorityMiddlewareInterface{ |
||
21 | |||
22 | /** |
||
23 | * @var \Psr\Http\Server\MiddlewareInterface |
||
24 | */ |
||
25 | protected $middleware; |
||
26 | |||
27 | /** |
||
28 | * @var int |
||
29 | */ |
||
30 | protected $priority; |
||
31 | |||
32 | /** |
||
33 | * PriorityMiddleware constructor. |
||
34 | * |
||
35 | * @param \Psr\Http\Server\MiddlewareInterface $middleware |
||
36 | * @param int|null $priority |
||
37 | */ |
||
38 | public function __construct(MiddlewareInterface $middleware, int $priority = null){ |
||
42 | |||
43 | /** |
||
44 | * @inheritDoc |
||
45 | */ |
||
46 | public function process(ServerRequestInterface $request, RequestHandlerInterface $handler):ResponseInterface{ |
||
49 | |||
50 | /** |
||
51 | * @inheritDoc |
||
52 | */ |
||
53 | public function getPriority():int{ |
||
56 | |||
57 | } |
||
58 |