X-Git-Url: http://git.nguyen.vg/gitweb/?p=tatoo.git;a=blobdiff_plain;f=src%2Ftree%2Fsig.ml;h=aba591706a6c487969d93e02bbd1d83a3428c2f0;hp=f9bd0b75caea9544e86b24472623edbdb79b0839;hb=3f530996e51732a419f226bd0ed94f9ca94cd1a7;hpb=3ec88447d6f39b141a1174086bc0845f5c86b15b diff --git a/src/tree/sig.ml b/src/tree/sig.ml index f9bd0b7..aba5917 100644 --- a/src/tree/sig.ml +++ b/src/tree/sig.ml @@ -14,10 +14,11 @@ (***********************************************************************) (* - Time-stamp: + Time-stamp: *) (** Implementation of documents as binary trees *) + module type S = sig type node @@ -45,7 +46,6 @@ sig val print_xml : out_channel -> t -> node -> unit (** Outputs the tree as an XML document on the given output_channel *) - val root : t -> node (** Returns the root of the tree *) @@ -75,6 +75,9 @@ sig QName.text, QName.cdata_section or QName.comment *) + val kind : t -> node -> Common.NodeKind.t + (** Returns the kind of the given node *) + val preorder : t -> node -> int (** Returns the position of a node in pre-order in the tree. The root has preorder 0. [nil] has pre-order [-1].