module Cf_journal:sig
..end
Diagnostic event journaling.
This module implements a lightweight foundation for diagnostic event journaling, similar to the core Java classes in the Log4j project from the Apache Foundation.
The core interface is functorial, and is intended for extensibility. An
additional interface is provided for simplicity of use in the common case
of journaling diagnostic messages to Pervasives.out_channel
objects, e.g
stdout
and stderr
.
The type of the module produced the Create(P: Cf_ordered.Total_T)
functor defined below.
module type T =sig
..end
module Create:
A functor that produces a module of type T
that defines extensible
diagnostic event journaling with messages prioritized by codes in the total
order defined by the module P
.
module Basic:sig
..end
A module defining basic diagnostic event journaling with a simple set of priority levels associated to integer priority codes.
class[[> Basic.level ]]
basic_prioritizer :object
..end
The basic prioritizer class, defining the priority codes and message tags
for all of the basic priority levels: `Invalid
, `Fail
, `Error
,
`Warn
, `Info
and `Debug
.
class[[> Basic.level ] #Basic.event]
basic_channel_archiver :Stdlib.out_channel ->
object
..end
The basic channel archiver.
class virtual[[> Basic.level ] #Basic.event
basic_agent :
#Basic.archiver]([> Basic.level ] as 'a) #basic_prioritizer -> 'a -> ('a #Basic.event #Basic.archiver as 'b) list ->
object
..end
The basic journaling agent.
typet =
Basic.level Basic.event Basic.archiver
basic_agent
The type of the most basic agent, used for stdout
and stderr
below.
val stdout : t
A basic agent, initially set with a limit of `Notice
, and with with one
basic archiver for the Pervasives.stdout
channel.
val stderr : t
A basic agent, initially set with a limit of `Notice
, and with with one
basic archiver for the Pervasives.stderr
channel.