MediaWiki REL1_41
MediaWiki\Logger\ConsoleSpi Class Reference

ConsoleLogger service provider for MediaWiki\Logger\LoggerFactory. More...

Inherits MediaWiki\Logger\Spi.

Collaboration diagram for MediaWiki\Logger\ConsoleSpi:

Public Member Functions

 __construct (array $config=[])
 
 getLogger ( $channel)
 Get a logger instance.
Parameters
string$channelLogging channel
Returns
\Psr\Log\LoggerInterface Logger instance

 

Detailed Description

ConsoleLogger service provider for MediaWiki\Logger\LoggerFactory.

This is developed for use in maintenance/eval.php.

Access: internal
For use in MediaWiki core only
Since
1.30

Definition at line 16 of file ConsoleSpi.php.

Constructor & Destructor Documentation

◆ __construct()

MediaWiki\Logger\ConsoleSpi::__construct ( array $config = [])
Parameters
array$config
  • channels: (string[]) List of channels to log: channel name => minimum level. Omit to log everything.
  • forwardTo: (Spi) Forward all log messages to this SPI (regardless of whether ConsoleSpi logs them).

Definition at line 30 of file ConsoleSpi.php.

Member Function Documentation

◆ getLogger()

MediaWiki\Logger\ConsoleSpi::getLogger ( $channel)

Get a logger instance.

Parameters
string$channelLogging channel
Returns
\Psr\Log\LoggerInterface Logger instance

Implements MediaWiki\Logger\Spi.

Definition at line 36 of file ConsoleSpi.php.


The documentation for this class was generated from the following file: