package acgtk

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type program = {
  1. rules : Rule.Rules.t;
  2. pred_table : Predicate.PredIdTable.table;
  3. const_table : ConstGen.Table.table;
  4. i_preds : Predicate.PredIds.t;
  5. rule_id_gen : UtilsLib.IdGenerator.IntIdGen.t;
  6. head_to_rules : Rule.Rules.t Predicate.PredIdMap.t;
  7. e_pred_to_rules : Rule.Rules.t Predicate.PredIdMap.t;
}
type modifier = {
  1. modified_rules : Rule.Rules.t;
  2. new_pred_table : Predicate.PredIdTable.table;
  3. new_const_table : ConstGen.Table.table;
  4. new_i_preds : Predicate.PredIds.t;
  5. new_e_preds : Predicate.PredIds.t;
  6. new_rule_id_gen : UtilsLib.IdGenerator.IntIdGen.t;
}
val make_program : Proto_Program.t -> program
val extend : program -> Proto_Program.t -> program
val is_in_idb : Predicate.predicate -> program -> bool

is_in_idb pred prog returns true if the predicate pred is an intensional predicate for the program prog

val is_head : Predicate.predicate -> Rule.rule -> bool

is_head pred rule returns true if the predicate pred matches with the head of the rule rule

val match_rules : Predicate.predicate -> program -> Rule.Rules.t

match_rules pred prog returns the set of rules of program prog whose heads match with pred

val get_rule_by_id : program -> int -> Rule.Rules.elt

get_rule_by_id program id Get the rule matching the id

val pp : ?with_position:bool -> ?with_id:bool -> Stdlib.Format.formatter -> program -> unit
OCaml

Innovation. Community. Security.