WhatFailureGroupHandler
extends GroupHandler
in package
Forwards records to multiple handlers suppressing failures of each handler and continuing through to give every handler a chance to succeed.
Tags
Table of Contents
Properties
- $bubble : bool
- $handlers : array<string|int, HandlerInterface>
- $processors : array<string|int, callable>
Methods
- __construct() : mixed
- __destruct() : mixed
- __sleep() : mixed
- close() : void
- Closes the handler.
- handle() : bool
- Handles a record.
- handleBatch() : void
- Handles a set of records at once.
- isHandling() : bool
- Checks whether the given record will be handled by this handler.
- popProcessor() : callable
- pushProcessor() : HandlerInterface
- reset() : void
- setFormatter() : HandlerInterface
- processRecord() : LogRecord
- resetProcessors() : void
Properties
$bubble
protected
bool
$bubble
$handlers
protected
array<string|int, HandlerInterface>
$handlers
$processors
protected
array<string|int, callable>
$processors
= []
Tags
Methods
__construct()
public
__construct(array<string|int, HandlerInterface> $handlers[, bool $bubble = true ]) : mixed
Parameters
- $handlers : array<string|int, HandlerInterface>
-
Array of Handlers.
- $bubble : bool = true
-
Whether the messages that are handled can bubble up the stack or not
Tags
__destruct()
public
__destruct() : mixed
__sleep()
public
__sleep() : mixed
close()
Closes the handler.
public
close() : void
handle()
Handles a record.
public
handle(LogRecord $record) : bool
Parameters
- $record : LogRecord
-
The record to handle
Tags
Return values
bool —true means that this handler handled the record, and that bubbling is not permitted. false means the record was either not processed or that this handler allows bubbling.
handleBatch()
Handles a set of records at once.
public
handleBatch(array<string|int, mixed> $records) : void
Parameters
- $records : array<string|int, mixed>
-
The records to handle
Tags
isHandling()
Checks whether the given record will be handled by this handler.
public
isHandling(LogRecord $record) : bool
Parameters
- $record : LogRecord
-
Partial log record having only a level initialized
Tags
Return values
boolpopProcessor()
public
popProcessor() : callable
Tags
Return values
callablepushProcessor()
public
pushProcessor(callable $callback) : HandlerInterface
Parameters
- $callback : callable
Tags
Return values
HandlerInterfacereset()
public
reset() : void
setFormatter()
public
setFormatter(FormatterInterface $formatter) : HandlerInterface
Parameters
- $formatter : FormatterInterface
Tags
Return values
HandlerInterfaceprocessRecord()
protected
processRecord(LogRecord $record) : LogRecord
Parameters
- $record : LogRecord
Return values
LogRecordresetProcessors()
protected
resetProcessors() : void