Collection of carriers, a singleton. More...
#include <yarp/os/Carriers.h>
Public Member Functions | |
virtual | ~Carriers () |
Destructor. More... | |
void | clear () |
Remove all carriers. More... | |
Static Public Member Functions | |
static Carrier * | chooseCarrier (const std::string &name) |
Select a carrier by name. More... | |
static Carrier * | getCarrierTemplate (const std::string &name) |
Get template for carrier. More... | |
static Carrier * | chooseCarrier (const Bytes &bytes) |
Select a carrier by 8-byte header. More... | |
static Face * | listen (const Contact &address) |
Create a "proto-carrier" interface object that waits for incoming connections prior to a carrier being selected via handshaking. More... | |
static OutputProtocol * | connect (const Contact &address) |
Initiate a connection to an address. More... | |
static bool | addCarrierPrototype (Carrier *carrier) |
Add a new connection type. More... | |
static Carriers & | getInstance () |
static Bottle | listCarriers () |
Collection of carriers, a singleton.
This is the starting point for creating connections between ports.
Definition at line 32 of file Carriers.h.
|
virtual |
Destructor.
Definition at line 221 of file Carriers.cpp.
|
static |
Add a new connection type.
carrier | a prototype of the desired connection type. The YARP library will be responsible for destroying it on shutdown. |
Definition at line 306 of file Carriers.cpp.
Select a carrier by 8-byte header.
bytes | the 8-byte header describing the desired carrier. |
Definition at line 247 of file Carriers.cpp.
|
static |
Select a carrier by name.
name | the name of the desired carrier. |
Definition at line 236 of file Carriers.cpp.
void Carriers::clear | ( | ) |
Remove all carriers.
Definition at line 227 of file Carriers.cpp.
|
static |
Initiate a connection to an address.
address | the address (including desired carrier type) to connect to. |
Definition at line 285 of file Carriers.cpp.
|
static |
Get template for carrier.
Definition at line 241 of file Carriers.cpp.
|
static |
Definition at line 319 of file Carriers.cpp.
|
static |
Definition at line 326 of file Carriers.cpp.
Create a "proto-carrier" interface object that waits for incoming connections prior to a carrier being selected via handshaking.
Currently, this is always a tcp server socket. There is no reason why it couldn't be any kind of stream, and this would be the method to change if you want to do something imaginative here.
address | the address (including initial carrier type) to listen to. |
Definition at line 253 of file Carriers.cpp.