58 foreach ($records as $record) {
77 if (!is_callable($callback)) {
78 throw new \InvalidArgumentException(
'Processors must be valid callables (callback or object with an __invoke method), '.var_export($callback,
true).
' given');
80 array_unshift($this->processors, $callback);
90 if (!$this->processors) {
91 throw new \LogicException(
'You tried to pop from an empty processor stack.');
94 return array_shift($this->processors);
112 if (!$this->formatter) {
180 foreach ($this->processors as $processor) {
Base Handler class providing the Handler structure.
const DEBUG
Detailed debug information.
close()
Closes the handler.
Handler or Processor implementing this interface will be reset when Logger::reset() is called...
handle(array $record)
Handles a record.
setFormatter(FormatterInterface $formatter)
{Sets the formatter.self}
static toMonologLevel($level)
Converts PSR-3 levels to Monolog ones if necessary.
getDefaultFormatter()
Gets the default formatter.
getLevel()
Gets minimum logging level at which this handler will be triggered.
handleBatch(array $records)
{Handles a set of records at once.The records to handle (an array of record arrays)} ...
__construct($level=Logger::DEBUG, $bubble=true)
setBubble($bubble)
Sets the bubbling behavior.
getFormatter()
{Gets the formatter.FormatterInterface}
isHandling(array $record)
{Checks whether the given record will be handled by this handler.This is mostly done for performance ...
popProcessor()
{Removes the processor on top of the stack and returns it.callable}
setLevel($level)
Sets minimum logging level at which this handler will be triggered.
Interface that all Monolog Handlers must implement.
pushProcessor($callback)
{Adds a processor in the stack.self}
getBubble()
Gets the bubbling behavior.