Documentation

FallbackGroupHandler extends GroupHandler
in package

Forwards records to at most one handler

If a handler fails, the exception is suppressed and the record is forwarded to the next handler.

As soon as one handler handles a record successfully, the handling stops there.

Tags
phpstan-import-type

Record from \Monolog\Logger

Table of Contents

$bubble  : bool
$handlers  : array<string|int, HandlerInterface>
$processors  : array<string|int, callable>
__construct()  : mixed
__destruct()  : mixed
__sleep()  : mixed
close()  : void
Closes the handler.
handle()  : bool
{@inheritDoc}
handleBatch()  : void
Handles a set of records at once.
isHandling()  : bool
{@inheritDoc}
popProcessor()  : callable
{@inheritDoc}
pushProcessor()  : HandlerInterface
{@inheritDoc}
reset()  : void
setFormatter()  : HandlerInterface
{@inheritDoc}
processRecord()  : array<string|int, mixed>
Processes a record.
resetProcessors()  : void

Properties

$processors

protected array<string|int, callable> $processors = []
Tags
phpstan-var

array<ProcessorInterface|callable(Record): Record>

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

Return values
mixed

__destruct()

public __destruct() : mixed
Return values
mixed

__sleep()

public __sleep() : mixed
Return values
mixed

close()

Closes the handler.

public close() : void
Return values
void

handle()

{@inheritDoc}

public handle(array<string|int, mixed> $record) : bool
Parameters
$record : array<string|int, mixed>
Return values
bool

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 (an array of record arrays)

Return values
void

isHandling()

{@inheritDoc}

public isHandling(array<string|int, mixed> $record) : bool
Parameters
$record : array<string|int, mixed>
Return values
bool

processRecord()

Processes a record.

protected processRecord(array<string|int, mixed> $record) : array<string|int, mixed>
Parameters
$record : array<string|int, mixed>
Tags
phpstan-param

Record $record

phpstan-return

Record

Return values
array<string|int, mixed>

Search results