public function LoggerService::__construct in Purge 8.3
Construct \Drupal\purge\Logger\LoggerService.
Parameters
\Drupal\Core\Config\ConfigFactoryInterface $config_factory: The factory for configuration objects.
\Drupal\purge\Logger\LoggerChannelPartFactoryInterface $purge_logger_parts_factory: The channel part factory.
File
- src/
Logger/ LoggerService.php, line 88
Class
- LoggerService
- Provides logging services to purge and its submodules, via a single channel.
Namespace
Drupal\purge\LoggerCode
public function __construct(ConfigFactoryInterface $config_factory, LoggerChannelPartFactoryInterface $purge_logger_parts_factory) {
$this->configFactory = $config_factory;
$this->purgeLoggerPartsFactory = $purge_logger_parts_factory;
// Set configuration when CMI has it.
if (is_array($c = $config_factory
->get(self::CONFIG)
->get(self::CKEY))) {
$this->config = $c;
}
}