PHP Class Phprest\ErrorHandler\Handler\Log

Inheritance: implements League\BooBoo\Handler\HandlerInterface
Show file Open project: phprest/phprest Class Usage Examples

Protected Properties

Property Type Description
$logger Psr\Log\LoggerInterface | null

Public Methods

Method Description
__construct ( Psr\Log\LoggerInterface $logger = null )
handle ( Exception $exception )
setLogger ( Psr\Log\LoggerInterface $logger )

Protected Methods

Method Description
buildLogMessage ( Exception $exception ) : string
handleErrorException ( ErrorException $exception ) : boolean

Method Details

__construct() public method

public __construct ( Psr\Log\LoggerInterface $logger = null )
$logger Psr\Log\LoggerInterface

buildLogMessage() protected method

protected buildLogMessage ( Exception $exception ) : string
$exception Exception
return string

handle() public method

public handle ( Exception $exception )
$exception Exception

handleErrorException() protected method

protected handleErrorException ( ErrorException $exception ) : boolean
$exception ErrorException
return boolean

setLogger() public method

public setLogger ( Psr\Log\LoggerInterface $logger )
$logger Psr\Log\LoggerInterface

Property Details

$logger protected property

protected LoggerInterface,Psr\Log|null $logger
return Psr\Log\LoggerInterface | null