summaryrefslogtreecommitdiff
path: root/src/vytree.mli
blob: c04087a0a3123732b7df3b03f8ab0f467c2fbf0a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
type 'a t

exception Empty_path
exception Duplicate_child
exception Nonexistent_path
exception Insert_error of string

type position = Before of string | After of string | Default

type node_type = Leaf_single | Leaf_multi | Tag | Other

val make : 'a -> string -> 'a t
val make_full : 'a -> string -> ('a t) list -> 'a t

val name_of_node : 'a t -> string
val data_of_node : 'a t -> 'a
val children_of_node : 'a t -> 'a t list

val insert : 'a t -> string list -> 'a list -> 'a t

val delete : 'a t -> string list -> 'a t

val update : 'a t -> string list -> 'a -> 'a t

val list_children : 'a t -> string list

val get : 'a t -> string list -> 'a t