This object handles a log of everything which happens in a
processing script. The log is in a convenient HTML format
and includes an index to major processing steps and to
The much simpler Util::NoLog class will output
to stdout and stderr, for times when a log object has not
yet been created.
The error, entry, milestone, and text (but not yet file)
methods now call XML::Dumper::quote_xml_chars, which was
already called by writeEvent, to quote the four HTML-special
characters &, <, >, and ", in their input message or text,
to avoid interfering with the real HTML tags. (A useful
extension might be to include a flag argument to indicate
that the message is HTML, so that eg. colors can be used.)
Note that the constructor creates new log files, so
only one Log object should be used throughout a given processing
- new(filename_object, jobpar_object)
Create a new set of HTML log pages and write their headers.
If there are exsiting files with the same name, rename then by
appending ".old" to their names. This is sometimes useful when debugging.
Make an entry in the job log.
Mark a major event in the job log and index.
- error(control, message)
Signal an error.
Dump the contents of a file to the log.
Dump the contents of a string to the log.
The string will be enclosed in <PRE> tags, so this
is most appropriate for multi-line text.
Object destructor method.
Close up the logs.