Inheritance diagram for csp::ChannelFactory< DATA_TYPE >:
This is the templated base class for channel factories. It contains methods to get one-to-one, one-to-any, any-to-one and any-to-any channel ends from the factory. The channel is guaranteed to last until the factory is destroyed.
This guarantee means that a ChannelFactory can end up using up a lot of memory if channels are continually re-allocated, because none of these channels will be destroyed until the factory is destroyed. Be mindful of this if you allocate channels inside a loop, or otherwise repeatedly reallocate them.
Public Member Functions | |
virtual void | any2Any (Chanin< DATA_TYPE > *in, Chanout< DATA_TYPE > *out, bool canPoisonIn=true, bool canPoisonOut=true)=0 |
Gets an any-to-any channel from the factory. | |
virtual std::pair< Chanin< DATA_TYPE >, Chanout< DATA_TYPE > > | any2AnyPair (bool canPoisonIn=true, bool canPoisonOut=true) |
Gets an any-to-any channel from the factory. | |
virtual void | any2One (AltChanin< DATA_TYPE > *in, Chanout< DATA_TYPE > *out, bool canPoisonIn=true, bool canPoisonOut=true)=0 |
Gets an any-to-one channel from the factory. | |
virtual std::pair< AltChanin< DATA_TYPE >, Chanout< DATA_TYPE > > | any2OnePair (bool canPoisonIn=true, bool canPoisonOut=true) |
Gets an any-to-one channel from the factory. | |
virtual void | one2Any (Chanin< DATA_TYPE > *in, Chanout< DATA_TYPE > *out, bool canPoisonIn=true, bool canPoisonOut=true)=0 |
Gets a one-to-any channel from the factory. | |
virtual std::pair< Chanin< DATA_TYPE >, Chanout< DATA_TYPE > > | one2AnyPair (bool canPoisonIn=true, bool canPoisonOut=true) |
Gets a one-to-any channel from the factory. | |
virtual void | one2One (AltChanin< DATA_TYPE > *in, Chanout< DATA_TYPE > *out, bool canPoisonIn=true, bool canPoisonOut=true)=0 |
Gets a one-to-one channel from the factory. | |
virtual std::pair< AltChanin< DATA_TYPE >, Chanout< DATA_TYPE > > | one2OnePair (bool canPoisonIn=true, bool canPoisonOut=true) |
Gets a one-to-one channel from the factory. |
virtual void csp::ChannelFactory< DATA_TYPE >::one2One | ( | AltChanin< DATA_TYPE > * | in, | |
Chanout< DATA_TYPE > * | out, | |||
bool | canPoisonIn = true , |
|||
bool | canPoisonOut = true | |||
) | [pure virtual] |
Gets a one-to-one channel from the factory.
in | A pointer to an AltChanin object that will become the input end of the requested channel. | |
out | A pointer to a Chanout object that will become the output end of the requested channel. | |
canPoisonIn | Flag to designate whether the input end should be poisonable | |
canPoisonOut | Flag to designate whether the output end should be poisonable |
Implemented in csp::StandardChannelFactory< DATA_TYPE >, and csp::BufferedChannelFactory< DATA_TYPE >.
virtual void csp::ChannelFactory< DATA_TYPE >::one2Any | ( | Chanin< DATA_TYPE > * | in, | |
Chanout< DATA_TYPE > * | out, | |||
bool | canPoisonIn = true , |
|||
bool | canPoisonOut = true | |||
) | [pure virtual] |
Gets a one-to-any channel from the factory.
in | A pointer to a Chanin object that will become the input end of the requested channel. | |
out | A pointer to a Chanout object that will become the output end of the requested channel. | |
canPoisonIn | Flag to designate whether the input end should be poisonable | |
canPoisonOut | Flag to designate whether the output end should be poisonable |
Implemented in csp::StandardChannelFactory< DATA_TYPE >, and csp::BufferedChannelFactory< DATA_TYPE >.
virtual void csp::ChannelFactory< DATA_TYPE >::any2One | ( | AltChanin< DATA_TYPE > * | in, | |
Chanout< DATA_TYPE > * | out, | |||
bool | canPoisonIn = true , |
|||
bool | canPoisonOut = true | |||
) | [pure virtual] |
Gets an any-to-one channel from the factory.
in | A pointer to an AltChanin object that will become the input end of the requested channel. | |
out | A pointer to a Chanout object that will become the output end of the requested channel. | |
canPoisonIn | Flag to designate whether the input end should be poisonable | |
canPoisonOut | Flag to designate whether the output end should be poisonable |
Implemented in csp::StandardChannelFactory< DATA_TYPE >, and csp::BufferedChannelFactory< DATA_TYPE >.
virtual void csp::ChannelFactory< DATA_TYPE >::any2Any | ( | Chanin< DATA_TYPE > * | in, | |
Chanout< DATA_TYPE > * | out, | |||
bool | canPoisonIn = true , |
|||
bool | canPoisonOut = true | |||
) | [pure virtual] |
Gets an any-to-any channel from the factory.
in | A pointer to a Chanin object that will become the input end of the requested channel. | |
out | A pointer to a Chanout object that will become the output end of the requested channel. | |
canPoisonIn | Flag to designate whether the input end should be poisonable | |
canPoisonOut | Flag to designate whether the output end should be poisonable |
Implemented in csp::StandardChannelFactory< DATA_TYPE >, and csp::BufferedChannelFactory< DATA_TYPE >.
virtual std::pair< AltChanin<DATA_TYPE> , Chanout<DATA_TYPE> > csp::ChannelFactory< DATA_TYPE >::one2OnePair | ( | bool | canPoisonIn = true , |
|
bool | canPoisonOut = true | |||
) | [inline, virtual] |
Gets a one-to-one channel from the factory.
canPoisonIn | Flag to designate whether the input end should be poisonable | |
canPoisonOut | Flag to designate whether the output end should be poisonable |
virtual std::pair< Chanin<DATA_TYPE> , Chanout<DATA_TYPE> > csp::ChannelFactory< DATA_TYPE >::one2AnyPair | ( | bool | canPoisonIn = true , |
|
bool | canPoisonOut = true | |||
) | [inline, virtual] |
Gets a one-to-any channel from the factory.
canPoisonIn | Flag to designate whether the input end should be poisonable | |
canPoisonOut | Flag to designate whether the output end should be poisonable |
virtual std::pair< AltChanin<DATA_TYPE> , Chanout<DATA_TYPE> > csp::ChannelFactory< DATA_TYPE >::any2OnePair | ( | bool | canPoisonIn = true , |
|
bool | canPoisonOut = true | |||
) | [inline, virtual] |
Gets an any-to-one channel from the factory.
canPoisonIn | Flag to designate whether the input end should be poisonable | |
canPoisonOut | Flag to designate whether the output end should be poisonable |
virtual std::pair< Chanin<DATA_TYPE> , Chanout<DATA_TYPE> > csp::ChannelFactory< DATA_TYPE >::any2AnyPair | ( | bool | canPoisonIn = true , |
|
bool | canPoisonOut = true | |||
) | [inline, virtual] |
Gets an any-to-any channel from the factory.
canPoisonIn | Flag to designate whether the input end should be poisonable | |
canPoisonOut | Flag to designate whether the output end should be poisonable |