package pplumbing

  1. Overview
  2. Docs

Module Log.LogsSource

Interface in the style of Logs.

These call the functions of the same name from Logs. They are direct translation, where the only difference is that the format is a pp value instead.

For example, the following Logs style logging:

  let hello ?src () = Logs.info ?src (fun m -> m "Hello %s!" "World")

Can be written with Log.Logs as:

  let hello ?src () =
    Log.Logs.info ?src (fun m -> m [ Pp.textf "Hello %s!" "World" ])
  ;;
Sourcetype msgf = ?header:string -> ?tags:Logs.Tag.set -> Pp_tty.t list -> unit
Sourcetype log = (msgf -> unit) -> unit
Sourceval msg : ?src:src -> level -> log
Sourceval app : ?src:src -> log
Sourceval err : ?src:src -> log
Sourceval warn : ?src:src -> log
Sourceval info : ?src:src -> log
Sourceval debug : ?src:src -> log
OCaml

Innovation. Community. Security.