\Horde_Exception_Pear

Horde exception class that converts PEAR errors to exceptions.

Summary

Methods
Properties
Constants
getLogLevel()
setLogLevel()
__construct()
catchError()
$details
$logged
No constants found
No protected methods found
$_logLevel
$_class
N/A
_getPearTrace()
No private properties found
N/A

Properties

$details

$details : string

Error details that should not be part of the main exception message, e.g. any additional debugging information.

Type

string

$logged

$logged : boolean

Has this exception been logged?

Type

boolean

$_logLevel

$_logLevel : integer

The log level to use. A Horde_Log constant.

Type

integer

$_class

$_class : string

The class name for generated exceptions.

Type

string

Methods

getLogLevel()

getLogLevel() : integer

Get the log level.

Returns

integer —

The Horde_Log constant for the log level.

setLogLevel()

setLogLevel(mixed  $level) 

Sets the log level.

Parameters

mixed $level

The log level.

__construct()

__construct(\PEAR_Error  $error) 

Exception constructor.

Parameters

\PEAR_Error $error

The PEAR error.

catchError()

catchError(mixed  $result) : mixed

Exception handling.

Parameters

mixed $result

The result to be checked for a PEAR_Error.

Throws

\Horde_Exception_Pear

In case the result was a PEAR_Error.

Returns

mixed —

Returns the original result if it was no PEAR_Error.

_getPearTrace()

_getPearTrace(\PEAR_Error  $error) : string

Return a trace for the PEAR error.

Parameters

\PEAR_Error $error

The PEAR error.

Returns

string —

The backtrace as a string.