Abstract base class for algorithms that traverse an entire tree of channel objects. More...
#include <Channels/ChannelVisitor.H>
Public Member Functions | |
virtual | ~ChannelVisitor () |
Virtual destructor for safe base class destruction. | |
virtual void | visitChannelBase (ChannelBase &chan)=0 |
Visit the given ChannelBase node. | |
virtual void | visitSingleChannel (SingleChannel &chan)=0 |
Visit the given SingleChannel node. | |
virtual void | visitComplexChannel (ComplexChannel &chan)=0 |
Visit the given ComplexChannel node. |
Abstract base class for algorithms that traverse an entire tree of channel objects.
This is a straightforward implementation of the "Visitor" design pattern; see http://en.wikipedia.org/wiki/Visitor_pattern for details
Definition at line 49 of file ChannelVisitor.H.
ChannelVisitor::~ChannelVisitor | ( | ) | [virtual] |
Virtual destructor for safe base class destruction.
Definition at line 44 of file ChannelVisitor.C.
virtual void ChannelVisitor::visitChannelBase | ( | ChannelBase & | chan | ) | [pure virtual] |
Visit the given ChannelBase node.
Implemented in ChannelVisitorInstallFacet< CFS, CFC >, FeatureBiaser, WeightFinder, GuidedSearchBiaser, JetFiller, JetSpecFiller, OptimalGainsFinder, BayesianBiaser, and MaskBiaser.
Referenced by ChannelBase::accept(), and SpectralResidualChannel::accept().
virtual void ChannelVisitor::visitComplexChannel | ( | ComplexChannel & | chan | ) | [pure virtual] |
Visit the given ComplexChannel node.
NOTE: ComplexChannel does NOT provide the iteration over its subchannels; instead, each ChannelVisitor subclass must iterate over ComplexChannel's subchannels, calling subChan(i)->accept(*this) for each one. Although this requires slightly more code for each ChannelVisitor subclass, it is also much more flexible since it lets the visitor be aware of the hierarchical structres of the various channels that it visits.
Implemented in ChannelVisitorInstallFacet< CFS, CFC >, FeatureBiaser, WeightFinder, GuidedSearchBiaser, JetFiller, JetSpecFiller, OptimalGainsFinder, BayesianBiaser, and MaskBiaser.
Referenced by ComplexChannel::accept().
virtual void ChannelVisitor::visitSingleChannel | ( | SingleChannel & | chan | ) | [pure virtual] |
Visit the given SingleChannel node.
Implemented in ChannelVisitorInstallFacet< CFS, CFC >, FeatureBiaser, WeightFinder, GuidedSearchBiaser, JetFiller, JetSpecFiller, OptimalGainsFinder, BayesianBiaser, and MaskBiaser.
Referenced by SingleChannel::accept().