COPASI API  4.16.103
Public Member Functions | Public Attributes | List of all members
CNodeContextIterator< Node, Context >::CStackElement Class Reference

Public Member Functions

 CStackElement ()
 
 CStackElement (const CStackElement &src)
 
 CStackElement (Node *pNode, Context *pParentContext=NULL)
 
 ~CStackElement ()
 

Public Attributes

size_t mChildCount
 
Context mContext
 
size_t mNextChildIndex
 
Node * mpNode
 
Context * mpParentContext
 

Detailed Description

template<class Node, class Context>
class CNodeContextIterator< Node, Context >::CStackElement

Internal class handling the traversal of the tree. For each nested level in the tree an element is pushed onto the stack

Definition at line 47 of file CNodeIterator.h.

Constructor & Destructor Documentation

template<class Node, class Context>
CNodeContextIterator< Node, Context >::CStackElement::CStackElement ( )
inline

Default Constructor

Definition at line 53 of file CNodeIterator.h.

template<class Node, class Context>
CNodeContextIterator< Node, Context >::CStackElement::CStackElement ( const CStackElement src)
inline

Copy constructor

Parameters
constCStackElement & src

Definition at line 65 of file CNodeIterator.h.

65  :
66  mpNode(src.mpNode),
67  mChildCount(src.mChildCount),
68  mNextChildIndex(src.mNextChildIndex),
69  mContext(src.mContext),
70  mpParentContext(src.mpParentContext)
71  {}
template<class Node, class Context>
CNodeContextIterator< Node, Context >::CStackElement::CStackElement ( Node *  pNode,
Context *  pParentContext = NULL 
)
inline

Constructor

Parameters
Node* pNode
Context* pParentContext (default: NULL)

Definition at line 78 of file CNodeIterator.h.

References CNodeContextIterator< Node, Context >::CStackElement::mChildCount.

78  :
79  mpNode(pNode),
80  mChildCount(0),
81  mNextChildIndex(0),
82  mContext(),
83  mpParentContext(pParentContext)
84  {
85  if (pNode != NULL)
86  {
87  mChildCount = pNode->getNumChildren();
88  }
89  }
template<class Node, class Context>
CNodeContextIterator< Node, Context >::CStackElement::~CStackElement ( )
inline

Destructor

Definition at line 94 of file CNodeIterator.h.

94 {}

Member Data Documentation

template<class Node, class Context>
size_t CNodeContextIterator< Node, Context >::CStackElement::mChildCount

The number of children of the current node

Definition at line 104 of file CNodeIterator.h.

Referenced by CNodeContextIterator< Node, Context >::CStackElement::CStackElement().

template<class Node, class Context>
Context CNodeContextIterator< Node, Context >::CStackElement::mContext

The context of the current node.

Definition at line 114 of file CNodeIterator.h.

template<class Node, class Context>
size_t CNodeContextIterator< Node, Context >::CStackElement::mNextChildIndex

The index of the next child to be processed

Definition at line 109 of file CNodeIterator.h.

template<class Node, class Context>
Node* CNodeContextIterator< Node, Context >::CStackElement::mpNode

Pointer to the node of the tree represented by the stack element

Definition at line 99 of file CNodeIterator.h.

template<class Node, class Context>
Context* CNodeContextIterator< Node, Context >::CStackElement::mpParentContext

The pointer to the parent node's context.

Definition at line 119 of file CNodeIterator.h.


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