sig
type date = {
year : int;
month : int;
day : int;
hour : int;
minute : int;
second : int;
zone : int;
week_day : int;
}
val since_epoch : Tdl.date -> float
val float_to_date : float -> Tdl.date
type state =
Done
| Suspended
| Priority_low
| Priority_normal
| Priority_high
val states : Tdl.state list
val string_of_state : Tdl.state -> string
type item = {
mutable item_title : string;
mutable item_date : Tdl.date;
mutable item_enddate : Tdl.date option;
mutable item_desc : string option;
mutable item_state : Tdl.state;
mutable item_id : int option;
}
type group = {
mutable group_title : string;
mutable group_items : Tdl.item list;
mutable group_groups : Tdl.group list;
mutable group_id : int option;
}
val item :
?id:int ->
title:string ->
state:Tdl.state ->
?date:Tdl.date -> ?enddate:Tdl.date -> ?desc:string -> unit -> Tdl.item
val group :
?id:int ->
?title:string ->
?items:Tdl.item list -> ?groups:Tdl.group list -> unit -> Tdl.group
val copy_item : Tdl.item -> Tdl.item
val copy_group : Tdl.group -> Tdl.group
val remove_item : Tdl.group -> Tdl.item -> unit
val remove_group : father:Tdl.group -> son:Tdl.group -> unit
val group_of_file : string -> Tdl.group
val group_of_string : string -> Tdl.group
val group_of_channel : Pervasives.in_channel -> Tdl.group
val print_group : ?encoding:string -> Format.formatter -> Tdl.group -> unit
val print_file : ?encoding:string -> string -> Tdl.group -> unit
val insert_group : ?path:string list -> Tdl.group -> Tdl.group -> unit
val merge_top_groups : Tdl.group -> Tdl.group -> Tdl.group
type filter =
Group of string
| Item of string
| Empty
| State of Tdl_types.state
| Desc of string
| Before of Tdl.date
| Or of Tdl.filter * Tdl.filter
| And of Tdl.filter * Tdl.filter
| Not of Tdl.filter
val filter_of_string : string -> Tdl.filter
val filter_of_channel : Pervasives.in_channel -> Tdl.filter
val filter_group : Tdl.filter -> Tdl.group -> Tdl.group
val split_by_day :
((int * int * int) * Tdl.group -> unit) -> Tdl.group -> unit
val compare_item_state : Tdl.item -> Tdl.item -> int
val sort_items_by_state : Tdl.item list -> Tdl.item list
end