`sig
val output : unit BatIO.output ref
val prefix : string ref
type flag = [ `Custom of unit -> string | `Date | `Filepos | `Time ]
val flags : flag list ref
val log : ?fp:string -> string -> unit
val logf : ?fp:string -> ('a, unit BatIO.output, unit) format -> 'a
val fatal : ?fp:string -> string -> 'a
val fatalf : ?fp:string -> ('a, unit BatIO.output, unit) format -> 'a
module type Config =
sig
type t
val out : t BatIO.output
val prefix : string
val flags : flag list
end
module Make :
functor (S : Config) ->
sig
val log : ?fp:string -> string -> unit
val logf : ?fp:string -> ('a, S.t BatIO.output, unit) format -> 'a
val fatal : ?fp:string -> string -> 'a
val fatalf : ?fp:string -> ('a, S.t BatIO.output, unit) format -> 'a
end
val make_logger :
'a BatIO.output ->
string ->
[< `Custom of unit -> string | `Date | `Filepos | `Time ] list ->
< fatal : ?fp:string -> string -> 'b;
fatalf : ?fp:string ->
('c, 'a BatIO.output, unit, unit, unit, 'd) format6 -> 'c;
log : ?fp:string -> string -> unit;
logf : ?fp:string -> ('e, 'a BatIO.output, unit) format -> 'e >
type easy_lev =
[ `always | `debug | `error | `fatal | `info | `trace | `warn ]
module Easy :
sig
val level : easy_lev ref
val output : unit BatIO.output ref
val log : ?fp:string -> easy_lev -> string -> unit
val logf :
?fp:string -> easy_lev -> ('a, unit BatIO.output, unit) format -> 'a
end
module type Level_sig =
sig
type t
val to_string : t -> string
val default_level : t
val compare : t -> t -> int
end
module Make_lev :
functor (L : Level_sig) ->
functor (S : Config) ->
sig
val level : L.t ref
val output : S.t BatIO.output ref
val log : ?fp:string -> L.t -> string -> unit
val logf :
?fp:string -> L.t -> ('a, S.t BatIO.output, unit) format -> 'a
end
end`