View on
MetaCPAN
Bruno Tavares > Seshat-1.1 > Seshat

Download:
Seshat-1.1.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Module Version: 1.1   Source  

NAME ^

Seshat - Perl Extension for writing modules

"Seshat, her who writes..."

SYNOPSIS ^

  use Seshat;
  
  my $lh = Seshat->new($log_filename[, PARAM => VALUE [, ...]]);

  $res = $lh->write($string,$nl_bool);

DESCRIPTION ^

  Seshat is a module designed to handle more than one log, and log files shared by two or more processes.
  It is a concurrency safe system, and implements extra information about the script that is writing the log.

METHODS ^

$lh = Seshat->new($log_filename [, PARAM => VALUE [, ...]])

Creates a new object that uses th $log_filename as the log file

Parameter description:

DATE_FORMAT => $string

  Defines the format of the date that is written to the log file

        Types:

        %a -> short day 
        %A -> long day 
        %b -> short month
        %B -> long month
        %d -> month day
        %g -> last 2 dig of year
        %G -> year
        %c -> long date
        %D -> short date
        %F -> short date (inverted)
        %H -> hour
        %M -> minutes
        %S -> seconds
        
        ex: "%a %b %G - %H:%M:%S" 
             Tue Oct 2000 - 13:59:41

LOG_LEVEL => [0..5]

  Defines the amount of information about the caller script that is written to the log file
$res = $lh->write($string,$nl_bool);

Writes the $string to the log file , and terminates the line or not ($nl_bool)

TODO ^

Sugestions accepted

AUTHOR ^

Bruno Tavares (bat@isp.novis.pt)

SEE ALSO ^

perl(1), Seshat::Parallel(1)

syntax highlighting: