|
YARP
Yet Another Robot Platform
|
|
Go to the documentation of this file.
10 #ifndef YARP_MPICARRIER_H
11 #define YARP_MPICARRIER_H
40 Carrier *
create()
const override = 0;
96 #endif // YARP_MPICARRIER_H
void close() override=0
Close the carrier.
virtual void createStream(bool sender)=0
bool sendIndex(yarp::os::ConnectionState &proto, yarp::os::SizedWriter &writer) override
bool write(yarp::os::ConnectionState &proto, yarp::os::SizedWriter &writer) override
Write a message.
bool checkHeader(const yarp::os::Bytes &header) override
Given the first 8 bytes received on a connection, decide if this is the right carrier type to use for...
virtual void write(OutputStream &os)
A starter class for implementing simple carriers.
bool respondToHeader(yarp::os::ConnectionState &proto) override
Respond to the header.
std::string getName() const override=0
Get the name of this connection type ("tcp", "mcast", "shmem", ...)
bool isConnectionless() const override
Check if this carrier is connectionless (like udp, mcast) or connection based (like tcp).
OutputStream & os()
Shorthand for getOutputStream()
void getHeader(yarp::os::Bytes &header) const override
Provide 8 bytes describing this connection sufficiently to allow the other side of a connection to se...
bool canEscape() const override
Check if carrier can encode administrative messages, as opposed to just user data.
bool expectIndex(yarp::os::ConnectionState &proto) override
Expect a message header, if there is one for this carrier.
bool supportReply() const override=0
This flag is used by YARP to determine whether the connection can carry RPC traffic,...
A simple abstraction for a block of bytes.
bool expectAck(yarp::os::ConnectionState &proto) override
Receive an acknowledgement, if expected for this carrier.
Abstract base carrier for managing port communication via MPI.
Carrier * create() const override=0
Factory method.
The basic state of a connection - route, streams in use, etc.
virtual bool isOk() const =0
Check if the stream is ok or in an error state.
bool sendHeader(yarp::os::ConnectionState &proto) override
Write a header appropriate to the carrier to the connection, followed by any carrier-specific data.
bool expectReplyToHeader(yarp::os::ConnectionState &proto) override
Process reply to header, if one is expected for this carrier.
Wrapper for MPI_Comm communicator.
Minimal requirements for an efficient Writer.
Abstract base class for port communication via MPI.
bool sendAck(yarp::os::ConnectionState &proto) override
Send an acknowledgement, if needed for this carrier.
bool expectSenderSpecifier(yarp::os::ConnectionState &proto) override
Expect the name of the sending port.