|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.ObjectLBJ2.infer.Constraint
LBJ2.infer.FirstOrderConstraint
LBJ2.infer.Quantifier
LBJ2.infer.ExistentialQuantifier
public class ExistentialQuantifier
An existential quantifier states that the constraint must hold for at least one object from the collection.
| Field Summary |
|---|
| Fields inherited from class LBJ2.infer.Quantifier |
|---|
collection, constraint, enclosingQuantificationSettings, quantificationVariable, replacer |
| Constructor Summary | |
|---|---|
ExistentialQuantifier(java.lang.String q,
java.util.Collection col,
FirstOrderConstraint con)
Initializing constructor. |
|
ExistentialQuantifier(java.lang.String q,
java.util.Collection col,
FirstOrderConstraint con,
QuantifierArgumentReplacer qar)
This constructor specifies a variable setter for when this quantifier is itself quantified. |
|
| Method Summary | |
|---|---|
boolean |
equals(java.lang.Object o)
Two ExistentialQuantifiers are equivalent when their
children are equivalent. |
boolean |
evaluate()
Determines whether the constraint is satisfied. |
int |
hashCode()
The hash code of a ExistentialQuantifier is the sum of the
hash codes of its children plus one. |
PropositionalConstraint |
propositionalize()
Transforms this first order constraint into a propositional constraint. |
void |
runVisit(Inference infer)
Calls the appropriate visit(·) method of the given
Inference for this Constraint, as per the
visitor pattern. |
void |
setQuantificationVariables(java.util.Vector o)
This method sets the given quantification variables to the given object references and evaluates the expressions involving those variables in this constraint's children. |
| Methods inherited from class LBJ2.infer.Quantifier |
|---|
consolidateVariables, getChildren, initialize |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ExistentialQuantifier(java.lang.String q,
java.util.Collection col,
FirstOrderConstraint con)
q - The name of the quantification variable.col - The collection of objects to iterate over.con - The constraint being quantified.
public ExistentialQuantifier(java.lang.String q,
java.util.Collection col,
FirstOrderConstraint con,
QuantifierArgumentReplacer qar)
q - The name of the quantification variable.col - The collection of objects to iterate over.con - The constraint being quantified.qar - The variable setter.| Method Detail |
|---|
public boolean evaluate()
evaluate in class Constraintpublic void setQuantificationVariables(java.util.Vector o)
setQuantificationVariables in class FirstOrderConstrainto - The new object references for the enclosing quantification
variables, in order of nesting.public PropositionalConstraint propositionalize()
propositionalize in class FirstOrderConstraintpublic int hashCode()
ExistentialQuantifier is the sum of the
hash codes of its children plus one.
hashCode in class QuantifierExistentialQuantifier.public boolean equals(java.lang.Object o)
ExistentialQuantifiers are equivalent when their
children are equivalent.
equals in class Quantifiertrue iff the argument is an equivalent
ExistentialQuantifier.public void runVisit(Inference infer)
visit(·) method of the given
Inference for this Constraint, as per the
visitor pattern.
runVisit in class Constraintinfer - The inference visiting this constraint.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||