Fluxus::Tree Class Reference

#include <Tree.h>

Inheritance diagram for Fluxus::Tree:

Inheritance graph
[legend]
Collaboration diagram for Fluxus::Tree:

Collaboration graph
[legend]

Public Member Functions

 Tree ()
virtual ~Tree ()
virtual int AddNode (int ParentID, Node *)
 Adds a node onto a parent node (0 is the root).
virtual NodeFindNode (int ID) const
 Finds a node in the tree from its ID.
virtual void RemoveNode (Node *node)
 Frees a node - and all it's children too.
virtual void Clear ()
 Clear the tree.
virtual void Dump (int Depth=0, Node *node=NULL) const
 Print out the tree for debugging.
bool IsDecendedFrom (Node *Parent, Node *Child) const
 Is the child attached to the parent?

Protected Member Functions

void RemoveNodeWalk (Node *node)

Protected Attributes

map< int, Node * > m_NodeMap
Nodem_Root
int m_CurrentID

Detailed Description

A tree of nodes. This is the base class for the scene graph, Just a basic tree structure

Definition at line 48 of file Tree.h.


Constructor & Destructor Documentation

Tree::Tree (  ) 

Definition at line 38 of file Tree.cpp.

Tree::~Tree (  )  [virtual]

Definition at line 44 of file Tree.cpp.


Member Function Documentation

int Tree::AddNode ( int  ParentID,
Node  
) [virtual]

Adds a node onto a parent node (0 is the root).

Definition at line 49 of file Tree.cpp.

Node * Tree::FindNode ( int  ID  )  const [virtual]

Finds a node in the tree from its ID.

Definition at line 76 of file Tree.cpp.

void Tree::RemoveNode ( Node node  )  [virtual]

Frees a node - and all it's children too.

Definition at line 87 of file Tree.cpp.

virtual void Fluxus::Tree::Clear (  )  [inline, virtual]

Clear the tree.

Reimplemented in Fluxus::SceneGraph.

Definition at line 64 of file Tree.h.

void Tree::Dump ( int  Depth = 0,
Node node = NULL 
) const [virtual]

Print out the tree for debugging.

Definition at line 141 of file Tree.cpp.

bool Tree::IsDecendedFrom ( Node Parent,
Node Child 
) const

Is the child attached to the parent?

Definition at line 125 of file Tree.cpp.

void Tree::RemoveNodeWalk ( Node node  )  [protected]

Definition at line 107 of file Tree.cpp.


Field Documentation

map<int,Node*> Fluxus::Tree::m_NodeMap [protected]

Definition at line 75 of file Tree.h.

Node* Fluxus::Tree::m_Root [protected]

Definition at line 76 of file Tree.h.

int Fluxus::Tree::m_CurrentID [protected]

Definition at line 77 of file Tree.h.


The documentation for this class was generated from the following files:
Generated on Tue Sep 4 23:22:46 2007 for The Fluxus Renderer (libfluxus) by  doxygen 1.5.1