Class ConcurrentFactTrie
java.lang.Object
edu.harvard.seas.pl.abcdatalog.util.datastructures.ConcurrentFactTrie
A trie that holds a set of facts (i.e., ground atoms).
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
add
(PositiveAtom fact) Adds a fact to this trie and returns whether the trie has changed.boolean
Adds an atom a to this trie.void
clear()
Clears this trie.
-
Constructor Details
-
ConcurrentFactTrie
public ConcurrentFactTrie()
-
-
Method Details
-
add
Adds an atom a to this trie. The atom must be ground once the substitution s has been applied. This method returns whether the trie has changed.- Parameters:
a
- the atoms
- the substitution- Returns:
- whether the set has changed
-
add
Adds a fact to this trie and returns whether the trie has changed.- Parameters:
fact
- the fact- Returns:
- whether the trie has changed
-
clear
public void clear()Clears this trie.
-