LateBindingLogger
in package
implements
LoggerInterface
Table of Contents
Interfaces
Properties
- $factory : Closure
- $logger : LoggerInterface|null
Methods
- __construct() : mixed
- emit() : void
- This method should only be used when implementing a `log appender`
- isEnabled() : bool
- Determine if the logger is enabled. Logs bridge API authors SHOULD call this method each time they are about to generate a LogRecord, to avoid performing computationally expensive work.
Properties
$factory read-only
private
Closure
$factory
$logger
private
LoggerInterface|null
$logger
= null
Methods
__construct()
public
__construct(callable(): LoggerInterface $factory) : mixed
Parameters
- $factory : callable(): LoggerInterface
emit()
This method should only be used when implementing a `log appender`
public
emit(LogRecord $logRecord) : void
Parameters
- $logRecord : LogRecord
isEnabled()
Determine if the logger is enabled. Logs bridge API authors SHOULD call this method each time they are about to generate a LogRecord, to avoid performing computationally expensive work.
public
isEnabled() : bool