Documentation

ExceptionHandler extends AbstractHandler
in package

Debug exception handler class

Tags
category

Pop

author

Nick Sagona, III dev@noladev.com

copyright

Copyright (c) 2009-2026 NOLA Interactive, LLC.

license

https://www.popphp.org/license New BSD License

version
3.0.0

Table of Contents

Properties

$data  : array<string|int, mixed>
Data
$elapsed  : float|null
Elapsed time
$end  : float|null
End time
$logger  : Logger|null
Logger object
$loggingParams  : array<string|int, mixed>
Logging params
$name  : string|null
Name of handler
$start  : float|null
Start time
$verbose  : bool
Verbose flag

Methods

__construct()  : mixed
Constructor
addException()  : ExceptionHandler
Add exception
getData()  : array<string|int, mixed>
Get data
getElapsed()  : float|null
Get elapsed
getEnd()  : float|null
Get end
getExceptions()  : array<string|int, mixed>
Get exceptions
getLogger()  : Logger|null
Get logger
getLoggingParams()  : array<string|int, mixed>
Get logging params
getName()  : string|null
Get name
getStart()  : float|null
Get start
hasData()  : bool
Has data
hasElapsed()  : bool
Has elapsed
hasEnd()  : bool
Has end
hasExceptions()  : bool
Determine if the handler has exceptions
hasLogger()  : bool
Has logger
hasLoggingParams()  : bool
Has logging parameters
hasName()  : bool
Has name
hasStart()  : bool
Has start
isVerbose()  : bool
Is verbose
log()  : void
Trigger handler logging
prepare()  : array<string|int, mixed>
Prepare handler data for storage
prepareMessage()  : string
Prepare handler message
setData()  : AbstractHandler
Set data
setElapsed()  : AbstractHandler
Set elapsed
setEnd()  : AbstractHandler
Set end
setLogger()  : AbstractHandler
Set logger
setLoggingParams()  : AbstractHandler
Set logger
setName()  : AbstractHandler
Set name
setStart()  : AbstractHandler
Set start
setVerbose()  : ExceptionHandler
Set verbose
start()  : AbstractHandler
Start
stop()  : AbstractHandler
Stop

Properties

$loggingParams

Logging params

protected array<string|int, mixed> $loggingParams = []

Methods

__construct()

Constructor

public __construct([bool $verbose = false ][, string|null $name = null ][, Logger|null $logger = null ][, array<string|int, mixed> $loggingParams = [] ]) : mixed

Instantiate a handler object

Parameters
$verbose : bool = false
$name : string|null = null
$logger : Logger|null = null
$loggingParams : array<string|int, mixed> = []

getData()

Get data

public getData() : array<string|int, mixed>
Return values
array<string|int, mixed>

getElapsed()

Get elapsed

public getElapsed() : float|null
Return values
float|null

getEnd()

Get end

public getEnd() : float|null
Return values
float|null

getExceptions()

Get exceptions

public getExceptions() : array<string|int, mixed>
Return values
array<string|int, mixed>

getLoggingParams()

Get logging params

public getLoggingParams() : array<string|int, mixed>
Return values
array<string|int, mixed>

getName()

Get name

public getName() : string|null
Return values
string|null

getStart()

Get start

public getStart() : float|null
Return values
float|null

hasElapsed()

Has elapsed

public hasElapsed() : bool
Return values
bool

hasExceptions()

Determine if the handler has exceptions

public hasExceptions() : bool
Return values
bool

hasLogger()

Has logger

public hasLogger() : bool
Return values
bool

hasLoggingParams()

Has logging parameters

public hasLoggingParams() : bool
Return values
bool

prepare()

Prepare handler data for storage

public prepare() : array<string|int, mixed>
Return values
array<string|int, mixed>

prepareMessage()

Prepare handler message

public prepareMessage([array<string|int, mixed>|null $context = null ]) : string
Parameters
$context : array<string|int, mixed>|null = null
Return values
string

        
On this page

Search results