CallableRequestHandler
in package
implements
RequestHandlerInterface
Adapts a plain callable into a RequestHandlerInterface. Internal - used by Pipeline to build each link of the chain; not part of the API a middleware author interacts with directly.
Tags
Table of Contents
Interfaces
- RequestHandlerInterface
- Client middleware request handler interface - what a MiddlewareInterface's $handler argument is; calling $handler->handle($request) continues the chain
Properties
- $callable : callable
- The wrapped callable
Methods
- __construct() : mixed
- Constructor
- handle() : ResponseInterface
- Handle the request by delegating to the wrapped callable
Properties
$callable
The wrapped callable
protected
callable
$callable
Methods
__construct()
Constructor
public
__construct(callable $callable) : mixed
Parameters
- $callable : callable
handle()
Handle the request by delegating to the wrapped callable
public
handle(RequestInterface $request) : ResponseInterface
Parameters
- $request : RequestInterface