CallerInfoProcessor
in package
implements
RecordProcessor
Read onlyYes
FinalYes
Tags
Table of Contents
Interfaces
Methods
- __construct() : mixed
- onlyFor() : self
- Restrict the processor to the given levels. Equivalent to `new CallerInfoProcessor([Level::Debug, Level::Error])`.
- process() : Record
Methods
__construct()
public
__construct([array<int, Level>|null $levels = null ]) : mixed
Parameters
- $levels : array<int, Level>|null = null
-
null = run on every record. Pass a list to only walk the backtrace for matching levels — useful when you want call-site info on debug/error/critical but want to skip the debug_backtrace() cost on high-volume info-level messages.
onlyFor()
Restrict the processor to the given levels. Equivalent to `new CallerInfoProcessor([Level::Debug, Level::Error])`.
public
static onlyFor(Level ...$levels) : self
Parameters
- $levels : Level
Return values
selfprocess()
public
process(Record $record) : Record
Parameters
- $record : Record