Moving OrderPairTable to the resolver + hide translation complexity in OrderPair...
[satune.git] / src / Backend / orderpair.h
index aad68ff8315a15c2d6b21d0ed7edd30e2947b643..f65064819da76d111fc87d1eb9862971c7e7fe86 100644 (file)
 
 class OrderPair {
 public:
-       OrderPair(uint64_t first, uint64_t second, Edge constraint);
+       OrderPair(uint64_t first, uint64_t second, Edge constraint = E_NULL);
        OrderPair();
+       virtual ~OrderPair();
+       virtual Edge getConstraint();
+       virtual bool getConstraintValue(CSolver* solver);
+       //for the cases that we swap first and second ... For total order is straight forward.
+       // but for partial order it has some complexity which should be hidden ... -HG
+       virtual Edge getNegatedConstraint();
+       virtual bool getNegatedConstraintValue(CSolver* solver);
        uint64_t first;
        uint64_t second;
-       Edge constraint;
        CMEMALLOC;
+protected:
+       Edge constraint;
 };
 
 #endif/* ORDERPAIR_H */