class Handler (View source)

Methods

void
__construct( ResponsePreparerInterface $responsePreparer, ExceptionDisplayerInterface $plainDisplayer, ExceptionDisplayerInterface $debugDisplayer, bool $debug = true)

Create a new error handler instance.

void
register( string $environment)

Register the exception / error handlers for the application.

handleError( int $level, string $message, string $file = '', int $line, array $context = array())

Handle a PHP error for the application.

Response
handleException( Exception $exception)

Handle an exception for the application.

void
handleUncaughtException( Exception $exception)

Handle an uncaught exception.

void
handleShutdown()

Handle the PHP shutdown event.

void
handleConsole( Exception $exception)

Handle a console exception.

void
error( Closure $callback)

Register an application error handler.

void
pushError( Closure $callback)

Register an application error handler at the bottom of the stack.

bool
runningInConsole()

Determine if we are running in the console.

void
setDebug( bool $debug)

Set the debug level for the handler.

Details

at line line 63
void __construct( ResponsePreparerInterface $responsePreparer, ExceptionDisplayerInterface $plainDisplayer, ExceptionDisplayerInterface $debugDisplayer, bool $debug = true)

Create a new error handler instance.

Parameters

ResponsePreparerInterface $responsePreparer
ExceptionDisplayerInterface $plainDisplayer
ExceptionDisplayerInterface $debugDisplayer
bool $debug

Return Value

void

at line line 80
void register( string $environment)

Register the exception / error handlers for the application.

Parameters

string $environment

Return Value

void

at line line 130
handleError( int $level, string $message, string $file = '', int $line, array $context = array())

Handle a PHP error for the application.

Parameters

int $level
string $message
string $file
int $line
array $context

Exceptions

ErrorException

at line line 144
Response handleException( Exception $exception)

Handle an exception for the application.

Parameters

Exception $exception

Return Value

Response

at line line 168
void handleUncaughtException( Exception $exception)

Handle an uncaught exception.

Parameters

Exception $exception

Return Value

void

at line line 178
void handleShutdown()

Handle the PHP shutdown event.

Return Value

void

at line line 212
void handleConsole( Exception $exception)

Handle a console exception.

Parameters

Exception $exception

Return Value

void

at line line 337
void error( Closure $callback)

Register an application error handler.

Parameters

Closure $callback

Return Value

void

at line line 348
void pushError( Closure $callback)

Register an application error handler at the bottom of the stack.

Parameters

Closure $callback

Return Value

void

at line line 369
bool runningInConsole()

Determine if we are running in the console.

Return Value

bool

at line line 380
void setDebug( bool $debug)

Set the debug level for the handler.

Parameters

bool $debug

Return Value

void