PHP Class Cascade\Config\Loader\ClassLoader\HandlerLoader

See also: ClassLoader
Author: Raphael Antonmattei ([email protected])
Inheritance: extends Cascade\Config\Loader\ClassLoader
ファイルを表示 Open project: theorchard/monolog-cascade Class Usage Examples

Public Methods

Method Description
__construct ( array &$handlerOptions, array $formatters = [], array $processors = [], array $handlers = [] ) Constructor
initExtraOptionsHandlers ( ) Loads the closures as option handlers. Add handlers to this function if you want to support additional custom options.

Private Methods

Method Description
populateFormatters ( array &$handlerOptions, array $formatters ) Replace the formatter name in the option array with the corresponding object from the formatter array passed in if it exists.
populateHandlers ( array &$handlerOptions, array $handlers ) Replace the handler or handlers in the option array with the corresponding callable(s) from the array of loaded and callable handlers, if they exist.
populateProcessors ( array &$handlerOptions, array $processors ) Replace the processors in the option array with the corresponding callable from the array of loaded and callable processors, if it exists.

Method Details

__construct() public method

Constructor
See also: ClassLoader::__construct
See also: Monolog\Handler classes for handler options
public __construct ( array &$handlerOptions, array $formatters = [], array $processors = [], array $handlers = [] )
$handlerOptions array Handler options
$formatters array Array of formatter to pick from
$processors array Array of processors to pick from
$handlers array Array of handlers to pick from

initExtraOptionsHandlers() public static method

The syntax is the following: array( '\Full\Absolute\Namespace\ClassName' => array( 'myOption' => Closure ), ... ) You can use the '*' wildcard if you want to set up an option for all Handler classes
public static initExtraOptionsHandlers ( )