KEltTerm¶
-
class KEltTerm : public KTerm¶
This class represent an expression of type Tab[I] where Tab is an array of integer value and I is the indexing variable
Example :
KProblem p(...); KIntVar X(...); KIntVar I(...); KIntArray valuesArray(...); KEltTerm eltTerm(valuesArray, I); // posting the constraint X can take its values indexed by the I variable in the valuesArray p.post(X == eltTerm); // equivalent to p.post(X == valuesArray[I]);
- See
- Since
2016.1
Public Functions
-
KEltTerm()¶
Default Constructor.
-
KEltTerm(const KIntArray &lValues, const KIntVar &indexVar)¶
Main constructor : implements the expression lValues[indexVar].
-
KEltTerm(const KIntArray &lValues, const KUnTerm &indexUnTerm)¶
implements the expression lValues[I+c]
-
KEltTerm(void *ptr, const KIntVar &indexVar)¶
Main constructor : implements the expression lValues[indexVar].
-
void *getUserPointer() const¶
return the user pointer