Total Complexity | 2 |
Total Lines | 34 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
14 | abstract class AbstractHandler extends AbstractLogger |
||
15 | { |
||
16 | /** @var array */ |
||
17 | protected const LEVELS = [ |
||
18 | Level::EMERGENCY => 0, |
||
19 | Level::ALERT => 1, |
||
20 | Level::CRITICAL => 2, |
||
21 | Level::ERROR => 3, |
||
22 | Level::WARNING => 4, |
||
23 | Level::NOTICE => 5, |
||
24 | Level::INFO => 6, |
||
25 | Level::DEBUG => 7 |
||
26 | ]; |
||
27 | |||
28 | /** @var string */ |
||
29 | protected string $minimumLevel; |
||
30 | |||
31 | /** |
||
32 | * AbstractHandler constructor. |
||
33 | * |
||
34 | * @param string $minimumLevel |
||
35 | */ |
||
36 | public function __construct(string $minimumLevel = Level::DEBUG) |
||
39 | } |
||
40 | |||
41 | /** |
||
42 | * @param string $level |
||
43 | * @return bool |
||
44 | */ |
||
45 | protected function canNotify(string $level): bool |
||
50 |