NAME
CTK::Log - CTK Logging methods
VERSION
Version 2.60
SYNOPSIS
$c = new CTK (
loglevel => 'info', # or '1'
logfile => CTK::catfile($LOGDIR,'foo.log'),
logseparator => " ", # as default
);
$c->log( INFO => " ... Blah-Blah-Blah ... " );
$c->log_except(); # 9 exception
$c->log_fatal(); # 8 fatal
$c->log_emerg(); # 7 system is unusable
$c->log_alert(); # 6 action must be taken immediately
$c->log_crit(); # 5 critical conditions
$c->log_error(); # 4 error conditions
$c->log_warning(); # 3 warning conditions
$c->log_notice(); # 2 normal but significant condition
$c->log_info(); # 1 informational
$c->log_debug(); # 0 debug-level messages (default)
DESCRIPTION
All of methods are returned by log-records
# Log File defined in constructor
$c = new CTK (
loglevel => 'info', # or '1'
logfile => CTK::catfile($LOGDIR,'foo.log'),
logseparator => " ", # as default
);
# Log File defined after constructor
$c->logfile(catfile($c->logdir(),
dformat($cmddata{logfile}, {
COMMAND => $command,
PREFIX => $c->prefix(),
SUFFIX => $c->suffix(),
EXT => 'log',
DEFAULT => LOGFILE,
}
)
)
);
log
$c->log( INFO => " ... Blah-Blah-Blah ... " );
Logging with info level (1). Same as log_info
log_debug, logdebug, logdebugging
$c->log_debug();
Level 0: debug-level messages (default)
log_info, info, loginf, loginfo, loginformation
$c->log_info();
Level 1: informational
log_notice, notice, lognote, lognotice
$c->log_notice();
Level 2: normal but significant condition
log_warning, warning, logwarn, logwarning
$c->log_warning();
Level 3: warning conditions
log_error, error, logerror
$c->log_error();
Level 4: error conditions
log_crit, crit, logcrit, logcritical
$c->log_crit();
Level 5: critical conditions
log_alert, alert, logalert
$c->log_alert();
Level 6: action must be taken immediately
log_emerg, emerg, logemerg, logemergency
$c->log_emerg();
Level 7: system is unusable
log_fatal, fatal, logfatal
$c->log_fatal();
Level 8: fatal
log_except, except, logexcept, logexception
$c->log_except();
Level 9: exception
AUTHOR
Sergey Lepenkov (Serz Minus) http://www.serzik.com <minus@mail333.com>
COPYRIGHT
Copyright (C) 1998-2017 D&D Corporation. All Rights Reserved
LICENSE
This program is free software; you can redistribute it and/or modify it under the same terms and conditions as Perl itself.
This program is distributed under the GNU LGPL v3 (GNU Lesser General Public License version 3).
See LICENSE
file