package easy_logging
Module to log messages. Aimed at being both powerful and easy to use
Install
Dune Dependency
Authors
Maintainers
Sources
v0.5
md5=12fb8044e96ea1ace1cc465c766cde7e
sha512=17ab30169c54a13f3aff8605bd1acaffb911c6882fa3a0c7ad6c14b2dcbd3c08b0f2568fb0ec500ae6e741be926a49fb73954d2ccfedcd274463ffed20149b02
doc/easy_logging/Easy_logging/Handlers/index.html
Module Easy_logging.Handlers
Source
Default implementation of a Handlers module.
This is the Handlers
module. It provides simple yet adaptable handlers implementation.
Type definitions
Source
type t = {
mutable fmt : log_formatter;
mutable level : Easy_logging__.Easy_logging_types.level;
mutable filters : filter list;
output : out_channel;
}
type of a handler
A handler is made of:
- a formatter that transforms a log item into a string.
- a level used to filter out items.
- an array of possible additional custom filters.
- an
out_channel
, where log strings are outputed by the functionPervasives.output_string
.
Formatting functions
Auxiliary functions.
Human readable log messages, with level depending colors.
Handlers creation helpers
Used for quick handler creation, e.g.
Cli handler: outputs colored messages to stdout
let h = Handlers.make (Cli Debug)
File handler : outputs messages to a given file
let h = Handlers.make (File ("filename", Debug))
Handlers setup
Sets the level of a handler.
Sets the formatter of a handler.
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>
On This Page