class PhpException

Class PhpException

Methods

static 
toString($e, $getTrace = true, $catcher = null)

No description

static string
toHtml($e, $getTrace = true, $catcher = null, $clearHtml = false)

Converts an exception into a simple string.

static array
toArray(Exception|Throwable $e, bool $getTrace = true, null|string $catcher = null)

Converts an exception into a simple array.

static string
toJson(Exception|Throwable $e, bool $getTrace = true, null|string $catcher = null)

Converts an exception into a json string.

Details

at line 21
static toString($e, $getTrace = true, $catcher = null)

Parameters

$e
$getTrace
$catcher

See also

PhpException::toHtml {@inheritdoc}

at line 34
static string toHtml($e, $getTrace = true, $catcher = null, $clearHtml = false)

Converts an exception into a simple string.

Parameters

$e
$getTrace
$catcher
$clearHtml

Return Value

string the string representation of the exception.

at line 61
static array toArray(Exception|Throwable $e, bool $getTrace = true, null|string $catcher = null)

Converts an exception into a simple array.

Parameters

Exception|Throwable $e the exception being converted
bool $getTrace
null|string $catcher

Return Value

array

at line 88
static string toJson(Exception|Throwable $e, bool $getTrace = true, null|string $catcher = null)

Converts an exception into a json string.

Parameters

Exception|Throwable $e the exception being converted
bool $getTrace
null|string $catcher

Return Value

string the string representation of the exception.