RTXI 2.4 The Real-Time eXperiment Interface Documentation |
#include <io.h>
Public Member Functions | |
void | foreachBlock (void(*callback)(Block *, void *), void *param) |
void | foreachConnection (void(*callback)(Block *, size_t, Block *, size_t, void *), void *param) |
void | connect (IO::Block *outputBlock, size_t outputChannel, IO::Block *inputBlock, size_t inputChannel) |
void | disconnect (IO::Block *outputBlock, size_t outputChannel, IO::Block *inputBlock, size_t inputChannel) |
bool | connected (IO::Block *outputBlock, size_t outputChannel, IO::Block *inputBlock, size_t inputChannel) |
Public Member Functions inherited from Settings::Object | |
Object (void) | |
virtual | ~Object (void) |
ID | getID (void) const |
State | save (void) const |
void | load (const State &) |
void | deferred (const State &) |
Static Public Member Functions | |
static Connector * | getInstance (void) |
Friends | |
class | Block |
Additional Inherited Members | |
Public Types inherited from Settings::Object | |
typedef unsigned long | ID |
Static Public Attributes inherited from Settings::Object | |
const static ID | INVALID = 0 |
Protected Member Functions inherited from Settings::Object | |
virtual void | doLoad (const State &) |
virtual void | doDeferred (const State &) |
virtual void | doSave (State &) const |
Acts as a central meeting point between Blocks. Provides interfaces for finding and connecting blocks.
void IO::Connector::connect | ( | IO::Block * | outputBlock, |
size_t | outputChannel, | ||
IO::Block * | inputBlock, | ||
size_t | inputChannel | ||
) |
Create a connection between the two specified Blocks.
outputBlock | The source of the data. |
outputChannel | The source channel of the data. |
inputBlock | The destination of the data. |
inputChannel | The destination channel of the data. |
bool IO::Connector::connected | ( | IO::Block * | outputBlock, |
size_t | outputChannel, | ||
IO::Block * | inputBlock, | ||
size_t | inputChannel | ||
) |
Determine whether two channels are connected or not.
outputBlock | The source of the data. |
outputChannel | THe source channel of the data. |
inputBlock | The destination of the data. |
inputChannel | The destination channel of the data. |
Definition at line 312 of file io.cpp.
void IO::Connector::disconnect | ( | IO::Block * | outputBlock, |
size_t | outputChannel, | ||
IO::Block * | inputBlock, | ||
size_t | inputChannel | ||
) |
Break a connection between the two specified Blocks.
outputBlock | The source of the data. |
outputChannel | The source channel of the data. |
inputBlock | The destination of the data. |
inputChannel | The destination channel of the data. |
void IO::Connector::foreachBlock | ( | void(*)(Block *, void *) | callback, |
void * | param | ||
) |
void IO::Connector::foreachConnection | ( | void(*)(Block *, size_t, Block *, size_t, void *) | callback, |
void * | param | ||
) |
Loop through each Connection and execute callback. The callback takes 5 parameters: The source block The source output. The destination block. The destination input. The last parameter to foreachConnection.
callback | The callback function. |
param | A parameter to the callback function. |
| static |