DeltaX::Trace - Perl module for writing log messages
_____ / \ _____ ______ ______ ___________ / \ / \\__ \ / ___// ___// __ \_ __ \ / Y \/ __ \_\___ \ \___ \\ ___/| | \/ \____|__ (____ /____ >____ >\___ >__| \/ \/ \/ \/ \/ project
use DeltaX::Trace; # exports only trace() and trace_set() use DeltaX::Trace qw/error warn info debug/; trace_set(trace_file=>'my_log_file.log'); trace('D', "This is", "message"); warn("This is warning");
Used to set tracing options (parameters are in key => value form):
File to write trace messages (default is /var/tmp/trace.log).
If set, error messages will be written to file (default is true).
If set, error messages will be written to stderr (default is false).
If set, warning messages will be written to file (default is true).
If set, warning messages will be written to stderr (default is false).
If set, info messages will be written to file (default is true).
If set, info messages will be written to stderr (default is false).
If set, debug messages will be written to file (default is true).
If set, debug messages will be written to stderr (default is false).
Is set, process ID will be attached to every message.
Is set, stack will be printed: 1 with ERROR's 2 with E and W 3 with E, W and I 4 with E, W, I and D
0 stack won't be printed.
This function actually creates and writes a message. First argument is a type of a message (E, W, I, D), other parameters are joined together into one line (with spaces).
Works as trace('E', ...).
Works as trace('W', ...).
Works as trace('I', ...).
Works as trace('D', ...).
Function for masser.fcgi - this value is printed instead of file name (if set).
Returns stack (as an array) - based on Carp::Heavy code.
To install DeltaX::Page, copy and paste the appropriate command in to your terminal.
cpanm
cpanm DeltaX::Page
CPAN shell
perl -MCPAN -e shell install DeltaX::Page
For more information on module installation, please visit the detailed CPAN module installation guide.