-
Notifications
You must be signed in to change notification settings - Fork 0
/
libxml.mli
61 lines (46 loc) · 2.06 KB
/
libxml.mli
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
(******************************************************************************
Rainbow, a termination proof certification tool
See the COPYRIGHTS and LICENSE files.
- Frederic Blanqui, 2006-05-31
XML parsing and generation
******************************************************************************)
open Xml;;
type tag = string;;
(*****************************************************************************)
(* xml parsing and writing *)
(*****************************************************************************)
val xml_version : string;;
val output_xml : out_channel -> xml -> unit;;
val parse_xml : in_channel -> xml;;
(*****************************************************************************)
(* xml generation *)
(*****************************************************************************)
val elt : string -> Xml.xml list -> Xml.xml
val pc : string -> Xml.xml
val pc_int : int -> Xml.xml
val pc_int64 : int64 -> Xml.xml
val elt_int : string -> int -> Xml.xml
(*****************************************************************************)
(* xml matching *)
(*****************************************************************************)
val height : xml -> int;;
val get_pc : Xml.xml -> string
val string : Xml.xml -> string
val boolean : xml -> bool;;
(* Old code *)
val get_int : Xml.xml -> int
val get_nonNegativeInteger : Xml.xml -> int
val get_positiveInteger : Xml.xml -> int
val integer : Xml.xml -> int
val nonNegativeInteger : Xml.xml -> int
val positiveInteger : Xml.xml -> int
(*****************************************************************************)
(* xml parsing *)
(*****************************************************************************)
val get_first_son : string -> (Xml.xml -> 'a) -> Xml.xml -> 'a
val get_sons : string -> (Xml.xml list -> 'a) -> Xml.xml -> 'a
val try_parse : ('a -> 'b) -> 'a -> 'b option
val parse_list : ('a -> 'b) -> 'a list -> 'b list * 'a list
val parse_first_elt : ('a -> 'b) -> 'a list -> 'b * 'a list
val parse_option : ('a -> 'b) -> 'a list -> 'b option * 'a list
val check_emptyness : Xml.xml list -> unit