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

Method post

test/int/no-overlap.cpp:78–86  ·  view source on GitHub ↗

Post constraint on \a xy

Source from the content-addressed store, hash-verified

76 }
77 /// Post constraint on \a xy
78 virtual void post(Gecode::Space& home, Gecode::IntVarArray& xy) {
79 using namespace Gecode;
80 int n = xy.size() / 2;
81 IntVarArgs x(n), y(n);
82 for (int i=0; i<n; i++) {
83 x[i]=xy[2*i+0]; y[i]=xy[2*i+1];
84 }
85 nooverlap(home, x, w, y, h);
86 }
87 };
88 /// %Test for no-overlap with optional rectangles
89 class IntOpt2 : public Test {

Callers

nothing calls this directly

Calls 2

nooverlapFunction · 0.85
sizeMethod · 0.45

Tested by

no test coverage detected