X-Git-Url: http://git.nguyen.vg/gitweb/?p=tatoo.git;a=blobdiff_plain;f=src%2Fata.mli;h=00070d4c3d287cc5b3b07d0929fa36a307fa836c;hp=6b4c02a110ace04876802f329c3fead8d0da26de;hb=aade6d9ba2e2b65e021de8a1c3a2d3874aa5742e;hpb=88375a854dab33de2193a7da5be652ae50f2ca64 diff --git a/src/ata.mli b/src/ata.mli index 6b4c02a..00070d4 100644 --- a/src/ata.mli +++ b/src/ata.mli @@ -68,7 +68,10 @@ module Formula : end (** Modules representing the Boolean formulae used in transitions *) -module Transition : Hcons.S with type data = State.t * QNameSet.t * Formula.t +module Transition : sig + include Hcons.S with type data = State.t * QNameSet.t * Formula.t + val print : Format.formatter -> t -> unit +end (** A [Transition.t] is a hashconsed triple of the state, the set of labels and the formula *) @@ -82,6 +85,9 @@ end type t (** 2-way Selecting Alternating Tree Automata *) +val uid : t -> Uid.t +(** return the internal unique ID of the automaton *) + val get_states : t -> StateSet.t (** return the set of states of the automaton *) @@ -92,11 +98,16 @@ val get_selecting_states : t -> StateSet.t (** return the set of selecting states of the automaton *) val get_trans : t -> QNameSet.elt -> StateSet.t -> TransList.t -(** [get_trans auto l q] return the list of transitions taken by [auto] +(** [get_trans auto l q] returns the list of transitions taken by [auto] for label [l] in state [q]. Takes time proportional to the number of transitions in the automaton. *) +val get_form : t -> QNameSet.elt -> State.t -> Formula.t +(** [get_form auto l q] returns a single formula for label [l] in state [q]. + Takes time proportional to the number of transitions in the automaton. + *) + val print : Format.formatter -> t -> unit (** Pretty printing of the automaton *) @@ -110,6 +121,31 @@ val concat : t -> t -> t nodes [N], [a'' N = a' (a N)]. *) +val merge : t -> t -> t +(** [merge a a'] creates a new automaton [a''] that evaluates both [a] and [a''] + in parallel +*) + +val union : t -> t -> t +(** [union a a'] creates a new automaton [a''] that selects node + selected by either [a] or [a'] +*) + +val inter : t -> t -> t +(** [inter a a'] creates a new automaton [a''] that selects node + selected by both [a] and [a'] +*) + +val neg : t -> t +(** [neg a] creates a new automaton [a'] that selects the nodes not + selected by [a] +*) + +val diff : t -> t -> t +(** [diff a a'] creates a new automaton [a''] that select nodes selected + by [a] but not selected by [a'] +*) + module Builder : sig type auto = t