You are here

public function Stdout::__construct in log_stdout 8

Same name and namespace in other branches
  1. 8.2 src/Logger/Stdout.php \Drupal\log_stdout\Logger\Stdout::__construct()

Constructs a Stdout object.

Parameters

\Drupal\Core\Config\ConfigFactoryInterface $config_factory: The configuration factory object.

\Drupal\Core\Logger\LogMessageParserInterface $parser: The parser to use when extracting message variables.

File

src/Logger/Stdout.php, line 39

Class

Stdout
This class allows logging to stdout and stderr.

Namespace

Drupal\log_stdout\Logger

Code

public function __construct(ConfigFactoryInterface $config_factory, LogMessageParserInterface $parser) {
  $this->config = $config_factory
    ->get('log_stdout.settings');
  $this->parser = $parser;
}