Inheritance diagram for csp::common::ExtSyncId< DATA_TYPE >:
Just to be clear: both the barrier sync and the channel output are part of the extended action, and happen in the order: sync, write.
This can be useful when you want to have an invisible process connecting two channels, but only allow data to proceed along a channel when a barrier sync occurs, or to look at it from another perspective, to only allow a barrier to sync when data passes along the channel.
For reasons similar to the BarrierSyncer process, you will probably want to give this process a pre-enrolled end of the barrier.
To use this process, you will need to include <cppcsp/common/basic.h>
Public Member Functions
|ExtSyncId (const Chanin< DATA_TYPE > &_in, const Chanout< DATA_TYPE > &_out, const Mobile< BarrierEnd > &_end)|
|Constructs the ExtSyncId process. |
Protected Member Functions
|You must implement this function to provide the code for your process. |
|csp::common::ExtSyncId< DATA_TYPE >::ExtSyncId||(||const Chanin< DATA_TYPE > &||_in,|
|const Chanout< DATA_TYPE > &||_out,|
|const Mobile< BarrierEnd > &||_end|
Constructs the ExtSyncId process.
|_in||The input channel|
|_out||The output channel|
|_end||The barrier end|
|void csp::common::ExtSyncId< DATA_TYPE >::run||(||)||
You must implement this function to provide the code for your process.
When the run method finishes, the process will terminate.
You should not let an uncaught exception cause the end of this function. If it derives from std::exception, it will be caught (although this behaviour should not be relied upon) but otherwise undefined behaviour will result.