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

Method getIndex

gecode/gist/node.hpp:226–236  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

224 }
225
226 forceinline int
227 Node::getIndex(const NodeAllocator& na) const {
228 if (parent==-1)
229 return 0;
230 Node* p = na[parent];
231 for (int i=p->getNumberOfChildren(); i--;)
232 if (p->getChild(na,i) == this)
233 return p->getChild(i);
234 GECODE_NEVER;
235 return -1;
236 }
237
238}}
239

Callers 1

acquireSpaceMethod · 0.80

Calls 2

getNumberOfChildrenMethod · 0.80
getChildMethod · 0.45

Tested by

no test coverage detected