Class AdornedPredicateSym
java.lang.Object
edu.harvard.seas.pl.abcdatalog.engine.topdown.AdornedPredicateSym
An adorned predicate symbol. Each argument of any atom formed from this predicate symbol will be
marked as bound or free in accordance with the predicate's adornment.
-
Constructor Summary
ConstructorDescriptionAdornedPredicateSym
(PredicateSym p, List<Boolean> adornment) Constructs an adorned predicate symbol from a predicate symbol and an adornment. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Returns the adornment for this predicate symbol.int
getArity()
int
getBound()
Returns the number of arguments bound in the adornment of this predicate symbol.getSym()
Creates a new predicate symbol that has the same symbol and arity as this one, but no adornment.int
hashCode()
toString()
-
Constructor Details
-
AdornedPredicateSym
Constructs an adorned predicate symbol from a predicate symbol and an adornment.- Parameters:
p
- predicate symboladornment
- adornment
-
-
Method Details
-
getSym
-
getArity
public int getArity() -
getUnadorned
Creates a new predicate symbol that has the same symbol and arity as this one, but no adornment.- Returns:
- the unadorned predicate symbol
-
getAdornment
Returns the adornment for this predicate symbol.- Returns:
- the adornment
-
getBound
public int getBound()Returns the number of arguments bound in the adornment of this predicate symbol.- Returns:
- the number of bound arguments
-
toString
-
hashCode
public int hashCode() -
equals
-