Class BottomUpEngineFrame<E extends EvalManager>

java.lang.Object
edu.harvard.seas.pl.abcdatalog.engine.bottomup.BottomUpEngineFrame<E>
All Implemented Interfaces:
DatalogEngine
Direct Known Subclasses:
BottomUpEngineFrameWithProvenance, ConcurrentBottomUpEngine, ConcurrentChunkedBottomUpEngine, ConcurrentStratifiedNegationBottomUpEngine

public class BottomUpEngineFrame<E extends EvalManager> extends Object implements DatalogEngine
A framework for a bottom-up Datalog engine.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected final E
    The evaluation manager for this engine.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructs a bottom-up engine with the provided evaluation manager.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    init(Set<Clause> program)
    Initializes engine with a Datalog program, including EDB facts.
    Returns all facts that 1) can be derived from the rules and initial facts that were used to initialize this engine and 2) unify with the query.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface edu.harvard.seas.pl.abcdatalog.engine.DatalogEngine

    query
  • Field Details

    • manager

      protected final E extends EvalManager manager
      The evaluation manager for this engine.
  • Constructor Details

    • BottomUpEngineFrame

      public BottomUpEngineFrame(E manager)
      Constructs a bottom-up engine with the provided evaluation manager.
      Parameters:
      manager - the manager
  • Method Details

    • init

      public void init(Set<Clause> program) throws DatalogValidationException
      Description copied from interface: DatalogEngine
      Initializes engine with a Datalog program, including EDB facts. The set that is passed into this method should include rules for deriving new facts as well as the initial facts, which can be encoded as clauses with empty bodies.
      Specified by:
      init in interface DatalogEngine
      Parameters:
      program - program to evaluate
      Throws:
      DatalogValidationException
      DatalogValidationException - if the given program is invalid
    • query

      public Set<PositiveAtom> query(PositiveAtom q)
      Description copied from interface: DatalogEngine
      Returns all facts that 1) can be derived from the rules and initial facts that were used to initialize this engine and 2) unify with the query.
      Specified by:
      query in interface DatalogEngine
      Parameters:
      q - the query
      Returns:
      facts