ImmediateResponseException extends Exception

Exception that has to be handled immediately in order to stop current execution and provide the current response. This exception is used as alternative to previous die() or exit().

Note this exception is only caught by Application classes, throwing it will bypass all outer middlewares. It should not be thrown by controllers, those should usually throw a PropagateResponseException instead, allowing outer middlewares to further process the response.

Internal

Table of Contents

Methods

__construct()  : mixed
getResponse()  : Response

Methods

__construct()

public __construct(ResponseInterface $response[, int $code = 0 ]) : mixed
Parameters
$response : ResponseInterface
$code : int = 0

        
On this page

Search results