public abstract class LinearLiteral extends Literal
Constructor and Description |
---|
LinearLiteral(LinearSum linearSum,
java.lang.String cmp)
Constructs a new comparison literal of given linear expression.
|
Modifier and Type | Method and Description |
---|---|
int |
ceilDiv(int b,
int a) |
boolean |
equals(java.lang.Object obj) |
int |
floorDiv(int b,
int a) |
java.lang.String |
getCmp() |
LinearSum |
getLinearExpression()
Returns the linear expression of the comparison literal.
|
java.util.Set<IntegerVariable> |
getVariables() |
int |
hashCode() |
java.lang.String |
toString()
Returns the string representation of the comparison literal.
|
getBound, getCode, isSatisfied, isSimple, isUnsatisfiable, isValid, neg, propagate
public LinearLiteral(LinearSum linearSum, java.lang.String cmp)
linearSum
- the linear expressionpublic java.util.Set<IntegerVariable> getVariables()
getVariables
in class Literal
public int floorDiv(int b, int a)
public int ceilDiv(int b, int a)
public LinearSum getLinearExpression()
public java.lang.String getCmp()
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object