package little_logger

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

Logging levels

type t =
  1. | Trace
  2. | Debug
  3. | Info
  4. | Warning
  5. | Error
  6. | Fatal
  7. | Unknown
  8. | Silent

Logging levels ordered from most messages printed to fewest. Or from lowest severity/priority to highest severity/priority.

If a message level is greater than or equal to the logging threshold, it will be printed.

E.g.,

  • Trace messages are only printed at log level threshold of Trace.
  • Info messages are printed at log level threshold of Info and below (Trace, Debug, and Info).
  • Error messages are printed at log level threshold of Error and below.

If the log level is set to Silent no messages will be printed (regardless of their level).

(Trace < Debug < Info < Warning < Error < Fatal < Unknown < Silent)

val of_string : string -> t option

of_string level attempts to create a t from its case-insensitive string representation (e.g., for creating from command line arguments).

val to_string : t -> string

to_string t converts the t to its string representation (e.g., for printing).

OCaml

Innovation. Community. Security.