Generated on Sat Feb 7 2015 02:01:43 for Gecode by doxygen 1.8.9.1
Gecode::Gist::Node Class Reference

Base class for nodes of the search tree. More...

#include <node.hh>

Public Types

typedef NodeAllocatorBase< VisualNodeNodeAllocator
 

Public Member Functions

 Node (int p, bool failed=false)
 Construct node with parent p. More...
 
int getParent (void) const
 Return the parent. More...
 
VisualNodegetParent (const NodeAllocator &na) const
 Return the parent. More...
 
VisualNodegetChild (const NodeAllocator &na, int n) const
 Return child no n. More...
 
int getIndex (const NodeAllocator &na) const
 Return index of this node. More...
 
bool isRoot (void) const
 Check if this node is the root of a tree. More...
 
void setNumberOfChildren (unsigned int n, NodeAllocator &na)
 Set the number of children to n and initialize children. More...
 
unsigned int getNumberOfChildren (void) const
 Return the number of children. More...
 

Protected Member Functions

bool isUndetermined (void) const
 Return whether this node is undetermined. More...
 
int getChild (int n) const
 Return index of child no n. More...
 

Detailed Description

Base class for nodes of the search tree.

Definition at line 110 of file node.hh.

Member Typedef Documentation

Constructor & Destructor Documentation

Gecode::Gist::Node::Node ( int  p,
bool  failed = false 
)
inline

Construct node with parent p.

Definition at line 179 of file node.hpp.

Member Function Documentation

bool Gecode::Gist::Node::isUndetermined ( void  ) const
inlineprotected

Return whether this node is undetermined.

Definition at line 196 of file node.hpp.

int Gecode::Gist::Node::getChild ( int  n) const
inlineprotected

Return index of child no n.

Definition at line 199 of file node.hpp.

int Gecode::Gist::Node::getParent ( void  ) const
inline

Return the parent.

Definition at line 186 of file node.hpp.

VisualNode * Gecode::Gist::Node::getParent ( const NodeAllocator na) const
inline

Return the parent.

Definition at line 191 of file node.hpp.

VisualNode * Gecode::Gist::Node::getChild ( const NodeAllocator na,
int  n 
) const
inline

Return child no n.

Definition at line 210 of file node.hpp.

int Gecode::Gist::Node::getIndex ( const NodeAllocator na) const
inline

Return index of this node.

Definition at line 228 of file node.hpp.

bool Gecode::Gist::Node::isRoot ( void  ) const
inline

Check if this node is the root of a tree.

Definition at line 215 of file node.hpp.

void Gecode::Gist::Node::setNumberOfChildren ( unsigned int  n,
NodeAllocator na 
)

Set the number of children to n and initialize children.

Definition at line 46 of file node.cpp.

unsigned int Gecode::Gist::Node::getNumberOfChildren ( void  ) const
inline

Return the number of children.

Definition at line 218 of file node.hpp.


The documentation for this class was generated from the following files: