1 | <?php |
||
34 | class Prototype implements MiddlewareInterface, RequestHandlerInterface |
||
35 | { |
||
36 | /** |
||
37 | * @var \Psr\Http\Message\ResponseInterface |
||
38 | */ |
||
39 | private $prototype; |
||
40 | |||
41 | /** |
||
42 | * Creates a new Prototype middleware |
||
43 | * |
||
44 | * @param \Psr\Http\Message\ResponseInterface $prototype The response prototype |
||
45 | */ |
||
46 | 1 | public function __construct(ResponseInterface $prototype) |
|
50 | |||
51 | /** |
||
52 | * {@inheritDoc} |
||
53 | */ |
||
54 | 1 | public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface |
|
58 | |||
59 | /** |
||
60 | * {@inheritDoc} |
||
61 | */ |
||
62 | 1 | public function handle(ServerRequestInterface $request): ResponseInterface |
|
66 | } |
||
67 |