Module InferModules__LogEntry

Log entry data model, global log entry store and functions to manipulate it. Direct access to the store is not exposed.

type count_entry_data = {
value : int;
}
type time_entry_data = {
duration_ms : int;
}
type entry_data =
| Count of count_entry_data
| Time of time_entry_data
type t = {
label : string;
created_at_ts : int;
data : entry_data;
}

created_at_ts is a unix timestamp (in seconds)

val mk_count : label:string -> value:int -> t
val mk_time : label:string -> duration_ms:int -> t
val global_log_get : unit -> t list
val global_log_erase : unit -> unit
val global_log_add : t -> unit