Log

This document is auto-generated for Owl’s APIs. #12 entries have been extracted. timestamp: 2018-04-16 13:12:54

Github: {Signature} {Implementation}

Type definition

type level = DEBUG | INFO | WARN | ERROR | FATAL

Type definition of log levels, priority is from low to high. Using set_level function to set global logging level to high one can mask the output from low level loggging.

Configuration functions

val set_level : level -> unit

This function sets the global logging level. Low level logging will be omitted.

source code

val set_output : out_channel -> unit

This function sets the channel for the logging output. The default one is the standard output.

source code

val set_color : bool -> unit

set_color true turns on the colour; set_color false turns it off.

source code

Log functions

val debug : ('a, out_channel, unit) format -> 'a

This function outputs log at DEBUG level.

source code

val info : ('a, out_channel, unit) format -> 'a

This function outputs log at INFO level.

source code

val warn : ('a, out_channel, unit) format -> 'a

This function outputs log at WARN level.

source code

val error : ('a, out_channel, unit) format -> 'a

This function outputs log at ERROR level.

source code

val fatal : ('a, out_channel, unit) format -> 'a

This function outputs log at FATAL level.

source code