Public Types | Public Member Functions | List of all members
WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity > Class Template Referenceabstract

#include <IFanoutNode.h>

Inheritance diagram for WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >:
WireCell::IFanoutNodeBase WireCell::INode WireCell::IComponent< INode > WireCell::Interface

Public Types

typedef InputType input_type
 
typedef OutputType output_type
 
typedef std::shared_ptr< const InputType > input_pointer
 
typedef std::shared_ptr< const OutputType > output_pointer
 
typedef std::vector< output_pointeroutput_vector
 
- Public Types inherited from WireCell::IFanoutNodeBase
typedef std::shared_ptr< IFanoutNodeBasepointer
 
typedef std::vector< boost::any > any_vector
 
- Public Types inherited from WireCell::INode
enum  NodeCategory {
  unknown, sourceNode, sinkNode, functionNode,
  queuedoutNode, joinNode, splitNode, faninNode,
  fanoutNode, multioutNode, hydraNode
}
 
- Public Types inherited from WireCell::IComponent< INode >
typedef std::shared_ptr< INodepointer
 Access subclass facet by pointer. More...
 
typedef std::vector< pointervector
 Vector of shared pointers. More...
 
- Public Types inherited from WireCell::Interface
typedef std::shared_ptr< Interfacepointer
 

Public Member Functions

virtual ~IFanoutNode ()
 
virtual bool operator() (const boost::any &anyin, any_vector &anyv)
 The calling signature: More...
 
virtual bool operator() (const input_pointer &in, output_vector &outv)=0
 
virtual std::vector< std::stringinput_types ()
 
virtual std::vector< std::stringoutput_types ()
 
- Public Member Functions inherited from WireCell::IFanoutNodeBase
virtual ~IFanoutNodeBase ()
 
virtual NodeCategory category ()
 Return the behavior category type. More...
 
virtual int concurrency ()
 Fanout nodes can usually do their thing stateless. More...
 
- Public Member Functions inherited from WireCell::INode
virtual ~INode ()
 
virtual std::string signature ()=0
 
virtual void reset ()
 
- Public Member Functions inherited from WireCell::IComponent< INode >
virtual ~IComponent ()
 
- Public Member Functions inherited from WireCell::Interface
virtual ~Interface ()
 

Detailed Description

template<typename InputType, typename OutputType, int FanoutMultiplicity = 3>
class WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >

Definition at line 38 of file IFanoutNode.h.

Member Typedef Documentation

template<typename InputType, typename OutputType, int FanoutMultiplicity = 3>
typedef std::shared_ptr<const InputType> WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >::input_pointer

Definition at line 43 of file IFanoutNode.h.

template<typename InputType, typename OutputType, int FanoutMultiplicity = 3>
typedef InputType WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >::input_type

Definition at line 41 of file IFanoutNode.h.

template<typename InputType, typename OutputType, int FanoutMultiplicity = 3>
typedef std::shared_ptr<const OutputType> WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >::output_pointer

Definition at line 44 of file IFanoutNode.h.

template<typename InputType, typename OutputType, int FanoutMultiplicity = 3>
typedef OutputType WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >::output_type

Definition at line 42 of file IFanoutNode.h.

template<typename InputType, typename OutputType, int FanoutMultiplicity = 3>
typedef std::vector<output_pointer> WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >::output_vector

Definition at line 45 of file IFanoutNode.h.

Constructor & Destructor Documentation

template<typename InputType, typename OutputType, int FanoutMultiplicity = 3>
virtual WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >::~IFanoutNode ( )
inlinevirtual

Definition at line 47 of file IFanoutNode.h.

47 {}

Member Function Documentation

template<typename InputType, typename OutputType, int FanoutMultiplicity = 3>
virtual std::vector<std::string> WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >::input_types ( )
inlinevirtual

Reimplemented from WireCell::INode.

Definition at line 66 of file IFanoutNode.h.

66  {
67  return std::vector<std::string>{typeid(input_type).name()};
68  }
static QCString name
Definition: declinfo.cpp:673
template<typename InputType, typename OutputType, int FanoutMultiplicity = 3>
virtual bool WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >::operator() ( const boost::any &  anyin,
any_vector anyout 
)
inlinevirtual

The calling signature:

Implements WireCell::IFanoutNodeBase.

Definition at line 49 of file IFanoutNode.h.

49  {
50  const input_pointer& in = boost::any_cast<const input_pointer&>(anyin);
51  output_vector outv;
52  bool ok = (*this)(in, outv);
53  if (!ok) return false;
54  const size_t mult = output_types().size(); // don't use FanoutMultiplicity
55  anyv.resize(mult);
56  for (size_t ind=0; ind<mult; ++ind) {
57  anyv[ind] = outv[ind];
58  }
59  return true;
60  }
virtual std::vector< std::string > output_types()
Definition: IFanoutNode.h:72
std::vector< output_pointer > output_vector
Definition: IFanoutNode.h:45
std::shared_ptr< const InputType > input_pointer
Definition: IFanoutNode.h:43
template<typename InputType, typename OutputType, int FanoutMultiplicity = 3>
virtual bool WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >::operator() ( const input_pointer in,
output_vector outv 
)
pure virtual
template<typename InputType, typename OutputType, int FanoutMultiplicity = 3>
virtual std::vector<std::string> WireCell::IFanoutNode< InputType, OutputType, FanoutMultiplicity >::output_types ( )
inlinevirtual

Reimplemented from WireCell::INode.

Reimplemented in WireCell::SigProc::ChannelSplitter, WireCell::IFrameFanout, WireCell::ISliceFanout, WireCell::IBlobSetFanout, WireCell::IDepoFanout, WireCell::IDepoSetFanout, WireCell::Gen::FrameFanout, WireCell::Gen::DepoSetFanout, WireCell::Img::SliceFanout, and WireCell::Gen::DepoFanout.

Definition at line 72 of file IFanoutNode.h.

72  {
73  std::vector<std::string> ret(FanoutMultiplicity, std::string(typeid(output_type).name()));
74  return ret;
75  }
static QCString name
Definition: declinfo.cpp:673
std::string string
Definition: nybbler.cc:12
OutputType output_type
Definition: IFanoutNode.h:42

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