delete CCSOLVER(solver);
}
+void resetCCSolver(void *solver) {
+ CCSOLVER(solver)->resetSolver();
+}
+
void *createSet(void *solver,unsigned int type, long *elements, unsigned int num) {
return CCSOLVER(solver)->createSet((VarType) type, (uint64_t *)elements, (uint) num);
}
return CCSOLVER(solver)->getBooleanVar((VarType) type).getRaw();
}
+void *getBooleanTrue(void *solver) {
+ return CCSOLVER(solver)->getBooleanTrue().getRaw();
+}
+
+void *getBooleanFalse(void *solver) {
+ return CCSOLVER(solver)->getBooleanFalse().getRaw();
+}
+
void *createFunctionOperator(void *solver,unsigned int op, void *range,unsigned int overflowbehavior) {
return CCSOLVER(solver)->createFunctionOperator((ArithOp) op, (Set *)range, (OverFlowBehavior) overflowbehavior);
}
return CCSOLVER(solver)->applyPredicate((Predicate *)predicate, (Element **)inputs, (uint) numInputs).getRaw();
}
-void *applyLogicalOperation(void *solver,unsigned int op, void *array, unsigned int asize) {
- return CCSOLVER(solver)->applyLogicalOperation((LogicOp) op, (BooleanEdge *)array, (uint) asize).getRaw();
+void *applyLogicalOperation(void *solver,unsigned int op, void **array, unsigned int asize) {
+ BooleanEdge constr [asize];
+ for(uint i=0; i< asize; i++){
+ constr[i] = BooleanEdge((Boolean*)array[i]);
+ }
+ return CCSOLVER(solver)->applyLogicalOperation((LogicOp) op, constr, (uint) asize).getRaw();
+}
+
+void *applyExactlyOneConstraint(void *solver, void **array, unsigned int asize) {
+ BooleanEdge constr [asize];
+ for(uint i=0; i< asize; i++){
+ constr[i] = BooleanEdge((Boolean*)array[i]);
+ }
+ return CCSOLVER(solver)->applyExactlyOneConstraint( constr, (uint) asize).getRaw();
}
void *applyLogicalOperationTwo(void *solver,unsigned int op, void *arg1, void *arg2) {
CCSOLVER(solver)->addConstraint(BooleanEdge((Boolean *) constraint));
}
+void printConstraint(void *solver,void *constraint) {
+ CCSOLVER(solver)->printConstraint(BooleanEdge((Boolean *) constraint));
+}
+
void *createOrder(void *solver,unsigned int type, void *set) {
return CCSOLVER(solver)->createOrder((OrderType) type, (Set *)set);
}
}
-
void serialize(void *solver) {
CCSOLVER(solver)->serialize();
}
CCSOLVER(solver)->mustHaveValue( (Element *) element);
}
-void setInterpreter(void *solver, unsigned int type){
+void setInterpreter(void *solver, unsigned int type) {
CCSOLVER(solver)->setInterpreter((InterpreterType)type);
}
void *clone(void *solver) {
return CCSOLVER(solver)->clone();
-}
\ No newline at end of file
+}