37 $this->socket =
new UdpSocket($host, $port ?: 514);
46 foreach ($lines as $line) {
47 $this->socket->write($line,
$header);
53 $this->socket->close();
62 return preg_split(
'/$\R?^/m',
$message);
72 return "<$priority>1 ";
const DEBUG
Detailed debug information.
makeCommonSyslogHeader($severity)
Make common syslog header (see rfc5424)
A Handler for logging to a remote syslogd server.
catch(Exception $e) $message
Create styles array
The data for the language used.
setSocket($socket)
Inject your own socket, mainly used for testing.
splitMessageIntoLines($message)
Common syslog functionality.
__construct($host, $port=514, $facility=LOG_USER, $level=Logger::DEBUG, $bubble=true)