class NaughtyRecursiveLogger
Same name in other branches
- 9 core/tests/Drupal/Tests/Core/Logger/LoggerChannelTest.php \Drupal\Tests\Core\Logger\NaughtyRecursiveLogger
- 8.9.x core/tests/Drupal/Tests/Core/Logger/LoggerChannelTest.php \Drupal\Tests\Core\Logger\NaughtyRecursiveLogger
- 11.x core/tests/Drupal/Tests/Core/Logger/LoggerChannelTest.php \Drupal\Tests\Core\Logger\NaughtyRecursiveLogger
Hierarchy
- class \Drupal\Tests\Core\Logger\NaughtyRecursiveLogger implements \Psr\Log\LoggerInterface uses \Psr\Log\LoggerTrait
Expanded class hierarchy of NaughtyRecursiveLogger
File
-
core/
tests/ Drupal/ Tests/ Core/ Logger/ LoggerChannelTest.php, line 188
Namespace
Drupal\Tests\Core\LoggerView source
class NaughtyRecursiveLogger implements LoggerInterface {
use LoggerTrait;
protected $channel;
protected $message;
public function __construct(LoggerChannel $channel) {
$this->channel = $channel;
}
public function log($level, string|\Stringable $message, array $context = []) : void {
$this->channel
->log(rand(0, 7), $message, $context);
}
}
Members
Title Sort descending | Modifiers | Object type | Summary |
---|---|---|---|
NaughtyRecursiveLogger::$channel | protected | property | |
NaughtyRecursiveLogger::$message | protected | property | |
NaughtyRecursiveLogger::log | public | function | |
NaughtyRecursiveLogger::__construct | public | function |
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.