Embedded Multicore Building Blocks V1.0.0
|
Select process template. More...
#include <network.h>
Public Types | |
typedef embb::base::Function< void, bool, Type, Type, Type & > | FunctionType |
Function type to use when processing tokens. More... | |
typedef Inputs< bool, Type, Type > | InputsType |
Input port type list. More... | |
typedef Outputs< Type > | OutputsType |
Output port type list. More... | |
Public Member Functions | |
Select (Network &network) | |
Constructs a Select process. More... | |
Select (Network &network, embb::mtapi::ExecutionPolicy const &policy) | |
Constructs a Select process. More... | |
virtual bool | HasInputs () const |
InputsType & | GetInputs () |
template<int Index> | |
InputsType::Types< Index >::Result & | GetInput () |
virtual bool | HasOutputs () const |
OutputsType & | GetOutputs () |
template<int Index> | |
OutputsType::Types< Index >::Result & | GetOutput () |
template<typename T > | |
void | operator>> (T &target) |
Connects output port 0 to input port 0 of target . More... | |
Select process template.
A select has 3 inputs and 1 output. Input port 0 is of type boolean and selects which of input port 1 or 2 (of type Type
) is sent to output port 0 (of type Type
). If input port 0 is set to true the value of input port 1 is selected, otherwise the value of input port 2 is taken. Tokens are processed as soon as all inputs for that token are complete.
Type | The type of input port 1 and 2 and output port 0. |
typedef embb::base::Function<void, bool, Type, Type, Type &> embb::dataflow::Network::Select< Type >::FunctionType |
Function type to use when processing tokens.
typedef Inputs<bool, Type, Type> embb::dataflow::Network::Select< Type >::InputsType |
Input port type list.
typedef Outputs<Type> embb::dataflow::Network::Select< Type >::OutputsType |
Output port type list.
|
explicit |
Constructs a Select process.
network | The network this node is going to be part of. |
embb::dataflow::Network::Select< Type >::Select | ( | Network & | network, |
embb::mtapi::ExecutionPolicy const & | policy | ||
) |
Constructs a Select process.
network | The network this node is going to be part of. |
policy | The execution policy of the process. |
|
virtual |
true
. InputsType& embb::dataflow::Network::Select< Type >::GetInputs | ( | ) |
InputsType::Types<Index>::Result& embb::dataflow::Network::Select< Type >::GetInput | ( | ) |
|
virtual |
true
. OutputsType& embb::dataflow::Network::Select< Type >::GetOutputs | ( | ) |
OutputsType::Types<Index>::Result& embb::dataflow::Network::Select< Type >::GetOutput | ( | ) |
void embb::dataflow::Network::Select< Type >::operator>> | ( | T & | target | ) |
Connects output port 0 to input port 0 of target
.
target | Process to connect to. |
T | Type of target process. |