package datalog

  1. Overview
  2. Docs

Module Default.QuerySource

Sourcetype set

mutable set of term lists

Sourceval ask : db -> ?neg:literal list -> int array -> literal list -> set

Given a list of variables, and a list of literals that contain those variables, return a set. Each element of the set is an instantiation of the variables such that all instantiated literals are facts of the db. neg is an optional list of literals that must be false for an instantiation to be an answer. This is lazy, and will only be evaluated upon calls to iter, to_list or other similar functions. The answers will be cached in the set and readily available thereafter.

Sourceval iter : set -> (term array -> unit) -> unit

Evaluate the set by iterating on it

Sourceval to_list : set -> term array list

Convert to a list

Sourceval cardinal : set -> int

Number of elements of the set

Sourceval pp_plan : Format.formatter -> set -> unit

Print query plan

OCaml

Innovation. Community. Security.