1 | <?php declare(strict_types=1); |
||
21 | class MonologBuilder implements LoggerBuilderInterface |
||
22 | { |
||
23 | protected $loggerName = 'feed-io'; |
||
24 | |||
25 | protected $handlersConfig = [ |
||
26 | [ |
||
27 | 'class' => 'Monolog\Handler\StreamHandler', |
||
28 | 'params' => ['php://stdout', Logger::DEBUG], |
||
29 | ], |
||
30 | ]; |
||
31 | |||
32 | /** |
||
33 | * @param array $config |
||
34 | */ |
||
35 | 7 | public function __construct(array $config = []) |
|
41 | |||
42 | /** |
||
43 | * @inheritdoc |
||
44 | */ |
||
45 | 2 | public function getLogger() : LoggerInterface |
|
56 | |||
57 | /** |
||
58 | * @param string $class |
||
59 | * @param array $params |
||
60 | * @return \Monolog\Handler\HandlerInterface |
||
61 | */ |
||
62 | 4 | public function newHandler(string $class, array $params = []) : HandlerInterface |
|
72 | |||
73 | /** |
||
74 | * This method MUST return the name of the main class |
||
75 | * @return string |
||
76 | */ |
||
77 | 1 | public function getMainClassName() : string |
|
81 | |||
82 | /** |
||
83 | * This method MUST return the name of the package name |
||
84 | * @return string |
||
85 | */ |
||
86 | 1 | public function getPackageName() : string |
|
90 | } |
||
91 |