| 53 | */ |
| 54 | template<class Info, class Offset, PropCond pc> |
| 55 | class Base : public Propagator { |
| 56 | protected: |
| 57 | /// Number of views (actually twice as many for both x and y) |
| 58 | int n; |
| 59 | /// Total number of not assigned views (not known to be assigned) |
| 60 | int n_na; |
| 61 | /// Offset transformation for x variables |
| 62 | Offset ox; |
| 63 | /// Offset transformation for y variables |
| 64 | Offset oy; |
| 65 | /// View and information for both \a x and \a y |
| 66 | Info* xy; |
| 67 | /// Constructor for cloning \a p |
| 68 | Base(Space& home, Base<Info,Offset,pc>& p); |
| 69 | /// Constructor for posting |
| 70 | Base(Home home, int n, Info* xy, Offset& ox, Offset& oy); |
| 71 | public: |
| 72 | /// Propagation cost (defined as low quadratic) |
| 73 | virtual PropCost cost(const Space& home, const ModEventDelta& med) const; |
| 74 | /// Schedule function |
| 75 | virtual void reschedule(Space& home); |
| 76 | /// Delete propagator and return its size |
| 77 | virtual size_t dispose(Space& home); |
| 78 | }; |
| 79 | |
| 80 | |
| 81 | /** |