36 template<
class Info,
class Offset, PropCond pc>
41 for (
int i=0; i<2*
n; i++)
42 xy[i].view.subscribe(home,*
this,pc);
45 template<
class Info,
class Offset, PropCond pc>
49 xy(home.alloc<Info>(2*
n)) {
52 for (
int i=0; i<2*
n; i++)
53 xy[i].update(home,p.
xy[i]);
56 template<
class Info,
class Offset, PropCond pc>
62 template<
class Info,
class Offset, PropCond pc>
65 for (
int i=0; i<2*
n; i++)
66 xy[i].view.reschedule(home,*
this,pc);
69 template<
class Info,
class Offset, PropCond pc>
72 for (
int i=0; i<2*
n; i++)
73 xy[i].view.cancel(home,*
this,pc);
virtual size_t dispose(Space &home)
Delete actor and return its size.
Home class for posting propagators
Base(Space &home, Base< Info, Offset, pc > &p)
Constructor for cloning p.
Offset oy
Offset transformation for y variables.
int n
Number of views (actually twice as many for both x and y)
Offset ox
Offset transformation for x variables.
int n_na
Total number of not assigned views (not known to be assigned)
virtual size_t dispose(Space &home)
Delete propagator and return its size.
virtual PropCost cost(const Space &home, const ModEventDelta &med) const
Propagation cost (defined as low quadratic)
Info * xy
View and information for both x and y.
virtual void reschedule(Space &home)
Schedule function.
Converter with fixed offset.
static PropCost quadratic(PropCost::Mod m, unsigned int n)
Quadratic complexity for modifier m and size measure n.
Propagator(Home home)
Constructor for posting.
int ModEventDelta
Modification event deltas.
Gecode toplevel namespace