1 | <?php |
||
32 | class SyslogHandler extends HandlerAbstract |
||
33 | { |
||
34 | /** |
||
35 | * syslog facility |
||
36 | * |
||
37 | * @var int |
||
38 | * @access protected |
||
39 | */ |
||
40 | protected $facility; |
||
41 | |||
42 | /** |
||
43 | * syslog options |
||
44 | * |
||
45 | * @var int |
||
46 | * @access protected |
||
47 | */ |
||
48 | protected $logopts; |
||
49 | |||
50 | /** |
||
51 | * syslog priorities |
||
52 | * |
||
53 | * @var array |
||
54 | * @access protected |
||
55 | */ |
||
56 | protected $priorities = [ |
||
57 | LogLevel::DEBUG => LOG_DEBUG, |
||
58 | LogLevel::INFO => LOG_INFO, |
||
59 | LogLevel::NOTICE => LOG_NOTICE, |
||
60 | LogLevel::WARNING => LOG_WARNING, |
||
61 | LogLevel::ERROR => LOG_ERR, |
||
62 | LogLevel::CRITICAL => LOG_CRIT, |
||
63 | LogLevel::ALERT => LOG_ALERT, |
||
64 | LogLevel::EMERGENCY => LOG_EMERG, |
||
65 | ]; |
||
66 | |||
67 | /** |
||
68 | * @param int $facility |
||
69 | * @param int $logOpts |
||
70 | * @param string $level |
||
71 | * @param FormatterInterface $formatter |
||
72 | * @param bool $stopPropagation |
||
73 | * @access public |
||
74 | */ |
||
75 | public function __construct( |
||
86 | |||
87 | /** |
||
88 | * {@inheritDoc} |
||
89 | */ |
||
90 | protected function write(LogEntryInterface $logEntry) |
||
107 | |||
108 | /** |
||
109 | * {@inheritDoc} |
||
110 | */ |
||
111 | protected function close() |
||
115 | } |
||
116 |