METHODS

Constructors

$obj->close
See close in Log::Report::Dispatcher.
$class->new( $type, $name, %options )

With syslog, people tend not to include the REASON of the message in the logs, because that is already used to determine the destination of the message.

Option Defined in Default

accept

Log::Report::Dispatcher

depend on mode

charset

'utf8'

facility

'user'

flags

'pid,nowait'

format

<unchanged>

format_reason

Log::Report::Dispatcher

'IGNORE'

identity

<basename $0>

include_domain

<false>

locale

Log::Report::Dispatcher

<system locale>

logsocket

undef

mode

Log::Report::Dispatcher

'NORMAL'

to_prio

[]

accept => REASONS
charset => CHARSET
Translate the text-strings into the specified charset, otherwise the sysadmin may get unreadable text.
facility => STRING
The possible values for this depend (a little) on the system. POSIX only defines user, and local0 upto local7.
flags => STRING
Any combination of flags as defined by Sys::Syslog, for instance pid, ndelay, and nowait.
format => CODE
[1.10] With a CODE reference you get your hands on the text before it gets sent to syslog. The three parameters are: the (translated) text, the related text domain object, and the message object. You may want to use context information from the latter.
format_reason => 'UPPERCASE'|'LOWERCASE'|'UCFIRST'|'IGNORE'|CODE
identity => STRING
include_domain => BOOLEAN
[1.00] Include the text-domain of the message in each logged message.
locale => LOCALE
logsocket => 'unix'|'inet'|'stream'|HASH
If specified, the log socket type will be initialized to this before openlog() is called. If not specified, the system default is used.
mode => 'NORMAL'|'VERBOSE'|'ASSERT'|'DEBUG'|0..3
to_prio => ARRAY-of-PAIRS
See reasonToPrio().

Accessors

$obj->format( [CODE] )

Returns the CODE ref which formats the syslog line.

$obj->isDisabled
See isDisabled in Log::Report::Dispatcher.
$obj->mode
See mode in Log::Report::Dispatcher.
$obj->name
See name in Log::Report::Dispatcher.
$obj->needs( [$reason] )
See needs in Log::Report::Dispatcher.
$obj->type
See type in Log::Report::Dispatcher.

Logging

$obj->collectLocation
$class->collectLocation
See collectLocation in Log::Report::Dispatcher.
$obj->collectStack( [$maxdepth] )
$class->collectStack( [$maxdepth] )
See collectStack in Log::Report::Dispatcher.
$obj->log( HASH-$of-%options, $reason, $message, $domain )
See log in Log::Report::Dispatcher.
$obj->reasonToPrio( $reason )

Returns a level which is understood by syslog(3), based on a translation table. This can be changed with new(to_prio).

$obj->stackTraceLine( %options )
$class->stackTraceLine( %options )
See stackTraceLine in Log::Report::Dispatcher.
$obj->translate( HASH-$of-%options, $reason, $message )
See translate in Log::Report::Dispatcher.