public class Atomic extends Predicate
expressions, maxOperandsfactory, type| Constructor and Description |
|---|
Atomic()
Creates a default Atomic predicate.
|
Atomic(boolean value)
Creates an Atomic predicate standing for a boolean constant value.
|
Atomic(Parameter parameter)
Creates an Atomic predicate by wrapping a Parameter.
|
| Modifier and Type | Method and Description |
|---|---|
Atomic |
addExpression(Expression expression)
Adds an expression as an operand to this Assignment expression.
|
java.lang.Boolean |
evaluate()
Evaluates this Atomic predicate.
|
boolean |
isFalseConstant()
Returns true if this Atomic predicate wraps the boolean Constant false.
|
boolean |
isTrueConstant()
Returns true if this Atomic predicate wraps the boolean Constant true.
|
protected void |
nameCheck()
Checks the name of an Atomic predicate and sets the number of
operands.
|
Predicate |
negate()
Negates this Atomic predicate.
|
protected void |
rebindFalse()
Rebinds this Atomic predicate so that it yields false.
|
protected void |
rebindTrue()
Rebinds this Atomic predicate so that it yields true.
|
boolean |
subsumes(Predicate other)
Tests whether this Atomic predicate subsumes the other Predicate.
|
java.lang.String |
toString()
Converts this Atomic predicate to a printable string.
|
protected void |
typeCheck()
Checks the type of this Atomic predicate.
|
isConsistent, normalise, rebind, rebind, refine, setType, subsumesAllDisjunctsOf, subsumesOneConjunctOf, subsumesPropositionassign, equals, getExpressions, getType, hashCode, isAssignable, isBound, operand, resolve, setName, unbindgetName, isBottom, isOrderedsafeEquals, safeHashCode, semanticErrorpublic Atomic()
public Atomic(Parameter parameter)
parameter - the parameter to wrap.public Atomic(boolean value)
value - the constant true or false.protected void nameCheck()
throws SemanticError
nameCheck in class FunctionSemanticError - if the name is illegal.protected void typeCheck()
throws SemanticError
typeCheck in class FunctionSemanticError - if a type inconsistency is detected.public Atomic addExpression(Expression expression)
addExpression in class Functionexpression - the operand expression.public Predicate negate()
public boolean isTrueConstant()
public boolean isFalseConstant()
isFalseConstant in class Predicatepublic java.lang.Boolean evaluate()
public boolean subsumes(Predicate other)
protected void rebindTrue()
rebindTrue in class Predicateprotected void rebindFalse()
rebindFalse in class Predicate