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