Main Page   Modules   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

FindAllVisitor< N, V > Class Template Reference

A visitor class for searching a node graph. More...

#include <Composite.h>

List of all members.

Public Types

typedef std::vector< simdata::Ref<
N > > 
NodeList

Public Methods

virtual bool match (N &node)=0
 The search condition.

void apply (N &node)
 Search for and accumulate matching nodes.

NodeList getNodes () const
 Get all nodes that match the search condition.


Detailed Description

template<class N, class V>
class FindAllVisitor< N, V >

A visitor class for searching a node graph.

This visitor is similar to FindVisitor, but retrieves all nodes that match the condition.


Member Typedef Documentation

template<class N, class V>
typedef std::vector< simdata::Ref<N> > FindAllVisitor< N, V >::NodeList
 


Member Function Documentation

template<class N, class V>
void FindAllVisitor< N, V >::apply N &    node [inline]
 

Search for and accumulate matching nodes.

Don't call this directly; use node->accept(visitor);

template<class N, class V>
NodeList FindAllVisitor< N, V >::getNodes   const [inline]
 

Get all nodes that match the search condition.

template<class N, class V>
virtual bool FindAllVisitor< N, V >::match N &    node [pure virtual]
 

The search condition.

Implement this condition in derived classes to deterimine which nodes are found.


The documentation for this class was generated from the following file:
SimData version pre-0.4.0. For more information on SimData, visit the SimData Homepage.

Generated on Tue Oct 14 12:06:40 2003, using Doxygen 1.2.18.

[SF.net]