Module Mtt


module Mtt: sig  end

type symbol = int 
type state = int 
type rhs = (symbol, state) RightHandSide.rhs 

type action =
| Undefined
| Det of rhs
| Non_det of rhs list
type rule = symbol -> action 
type rule_set = (state, rule) Hashtbl.t 

type ('a, 'b, 'c) mtt = {
   mutable q : 'a SymbolTable.symbol_table;
   mutable sigma : 'b SymbolTable.symbol_table;
   mutable delta : 'c SymbolTable.symbol_table;
   mutable init : symbol;
   mutable rules : rule_set;
}
val empty : ('a -> 'a -> bool) * ('a -> string) ->
('b -> 'b -> bool) * ('b -> string) ->
('c -> 'c -> bool) * ('c -> string) -> ('a, 'b, 'c) mtt
val add_state : ('a, 'b, 'c) mtt -> 'a -> unit
val add_sigma : ('a, 'b, 'c) mtt -> 'b -> unit
val add_delta : ('a, 'b, 'c) mtt -> 'c -> unit
val add_rule : ('a, 'b, 'c) mtt -> state -> symbol -> rhs -> unit
val get_action : ('a, 'b, 'c) mtt -> state -> symbol -> action
val ord_of_state : ('a, 'b, 'c) mtt -> 'a -> state
val ord_of_sigma : ('a, 'b, 'c) mtt -> 'b -> symbol
val ord_of_delta : ('a, 'b, 'c) mtt -> 'c -> symbol
val state_of_ord : ('a, 'b, 'c) mtt -> state -> 'a
val sigma_of_ord : ('a, 'b, 'c) mtt -> symbol -> 'b
val delta_of_ord : ('a, 'b, 'c) mtt -> symbol -> 'c
val get_init : ('a, 'b, 'c) mtt -> state
val set_init : ('a, 'b, 'c) mtt -> state -> unit
val state_to_string : ('a, 'b, 'c) mtt -> 'a -> string
val sigma_to_string : ('a, 'b, 'c) mtt -> 'b -> string
val delta_to_string : ('a, 'b, 'c) mtt -> 'c -> string
val print_states : ('a, 'b, 'c) mtt -> unit
val print_sigma : ('a, 'b, 'c) mtt -> unit
val print_delta : ('a, 'b, 'c) mtt -> unit