MCPcopy Create free account
hub / github.com/Gecode/gecode / processLubChange

Method processLubChange

gecode/set/var-imp/set.cpp:67–87  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

65 }
66
67 ModEvent
68 SetVarImp::processLubChange(Space& home, SetDelta& d) {
69 ModEvent me = ME_SET_LUB;
70 if (cardMax() > lub.size()) {
71 lub.card(lub.size());
72 if (cardMin() > cardMax()) {
73 glb.become(home, lub);
74 glb.card(glb.size());
75 lub.card(glb.size());
76 return fail(home);
77 }
78 me = ME_SET_CLUB;
79 }
80 if (cardMax() == lub.size() && cardMin() == cardMax()) {
81 glb.become(home, lub);
82 me = ME_SET_VAL;
83 assert(d.glbMin() == 1);
84 assert(d.glbMax() == 0);
85 }
86 return notify(home, me, d);
87 }
88
89 ModEvent
90 SetVarImp::processGlbChange(Space& home, SetDelta& d) {

Callers

nothing calls this directly

Calls 5

becomeMethod · 0.80
sizeMethod · 0.45
cardMethod · 0.45
glbMinMethod · 0.45
glbMaxMethod · 0.45

Tested by

no test coverage detected