YARP  2.3.68+272-20170522.1+git50f0ae7
Yet Another Robot Platform
yarp::os::Carrier Class Referenceabstract

A base class for connection types (tcp, mcast, shmem, ...) which are called carriers in YARP. More...

#include <yarp/os/Carrier.h>

+ Inheritance diagram for yarp::os::Carrier:

Public Member Functions

virtual Carriercreate ()=0
 Factory method. More...
 
virtual bool checkHeader (const Bytes &header)=0
 Given the first 8 bytes received on a connection, decide if this is the right carrier type to use for the rest of the connection. More...
 
virtual void setParameters (const Bytes &header)=0
 Configure this carrier based on the first 8 bytes of the connection. More...
 
virtual void getHeader (const Bytes &header)=0
 Provide 8 bytes describing this connection sufficiently to allow the other side of a connection to select it. More...
 
virtual bool isConnectionless ()=0
 Check if this carrier is connectionless (like udp, mcast) or connection based (like tcp). More...
 
virtual bool isBroadcast ()
 Check if this carrier uses a broadcast mechanism. More...
 
virtual bool canAccept ()=0
 Check if reading is implemented for this carrier. More...
 
virtual bool canOffer ()=0
 Check if writing is implemented for this carrier. More...
 
virtual bool isTextMode ()=0
 Check if carrier is textual in nature. More...
 
virtual bool canEscape ()=0
 Check if carrier can encode administrative messages, as opposed to just user data. More...
 
virtual void handleEnvelope (const yarp::os::ConstString &envelope)
 Carriers that do not distinguish data from administrative headers (i.e. More...
 
virtual bool requireAck ()=0
 Check if carrier has flow control, requiring sent messages to be acknowledged by recipient. More...
 
virtual bool supportReply ()=0
 This flag is used by YARP to determine whether the connection can carry RPC traffic, that is, messages with replies. More...
 
virtual bool isLocal ()=0
 Check if carrier operates within a single process. More...
 
virtual bool isPush ()
 Check if carrier is "push" or "pull" style. More...
 
virtual bool prepareSend (ConnectionState &proto)=0
 Perform any initialization needed before writing on a connection. More...
 
virtual bool sendHeader (ConnectionState &proto)=0
 Write a header appropriate to the carrier to the connection, followed by any carrier-specific data. More...
 
virtual bool expectReplyToHeader (ConnectionState &proto)=0
 Process reply to header, if one is expected for this carrier. More...
 
virtual bool write (ConnectionState &proto, SizedWriter &writer)=0
 Write a message. More...
 
virtual bool reply (ConnectionState &proto, SizedWriter &writer)
 
virtual bool expectExtraHeader (ConnectionState &proto)=0
 Receive any carrier-specific header. More...
 
virtual bool respondToHeader (ConnectionState &proto)=0
 Respond to the header. More...
 
virtual bool expectIndex (ConnectionState &proto)=0
 Expect a message header, if there is one for this carrier. More...
 
virtual bool expectSenderSpecifier (ConnectionState &proto)=0
 Expect the name of the sending port. More...
 
virtual bool sendAck (ConnectionState &proto)=0
 Send an acknowledgement, if needed for this carrier. More...
 
virtual bool expectAck (ConnectionState &proto)=0
 Receive an acknowledgement, if expected for this carrier. More...
 
virtual bool isActive ()=0
 Check if carrier is alive and error free. More...
 
virtual void prepareDisconnect ()
 Do cleanup and preparation for the coming disconnect, if necessary. More...
 
virtual ConstString toString ()=0
 Get name of carrier. More...
 
virtual void close ()
 Close the carrier. More...
 
virtual ~Carrier ()
 Destructor. More...
 
virtual ConstString getBootstrapCarrierName ()
 Get the name of the carrier that should be used prior to handshaking, if a port is registered with this carrier as its default carrier. More...
 
virtual int connect (const Contact &src, const Contact &dest, const ContactStyle &style, int mode, bool reversed)
 Some carrier types may require special connection logic. More...
 
virtual bool modifiesIncomingData ()
 Check if this carrier modifies incoming data through the Carrier::modifyIncomingData method. More...
 
virtual ConnectionReadermodifyIncomingData (ConnectionReader &reader)
 Modify incoming payload data, if appropriate. More...
 
virtual bool acceptIncomingData (ConnectionReader &reader)
 Determine whether incoming data should be accepted. More...
 
virtual bool modifiesOutgoingData ()
 Check if this carrier modifies outgoing data through the Carrier::modifyOutgoingData method. More...
 
virtual PortWritermodifyOutgoingData (PortWriter &writer)
 Modify outgoing payload data, if appropriate. More...
 
virtual bool modifiesReply ()
 Check if this carrier modifies outgoing data through the Carrier::modifyReply method. More...
 
virtual PortReadermodifyReply (PortReader &reader)
 Modify reply payload data, if appropriate. More...
 
virtual bool acceptOutgoingData (PortWriter &writer)
 Determine whether outgoing data should be accepted. More...
 
virtual bool configure (ConnectionState &proto)
 Give carrier a shot at looking at how the connection is set up. More...
 
virtual bool configureFromProperty (yarp::os::Property &options)
 
virtual void setCarrierParams (const Property &params)
 Configure carrier from port administrative commands. More...
 
virtual void getCarrierParams (Property &params)
 Get carrier configuration and deliver it by port administrative commands. More...
 
- Public Member Functions inherited from yarp::os::Connection
virtual ~Connection ()
 Destructor. More...
 
virtual bool isValid ()
 Check if this object is really a connection, or just an empty placeholder. More...
 
virtual bool isBareMode ()
 Check if carrier excludes type information from payload. More...
 
virtual yarp::os::ConstString getName ()=0
 Get the name of this connection type ("tcp", "mcast", "shmem", ...) More...
 

Detailed Description

A base class for connection types (tcp, mcast, shmem, ...) which are called carriers in YARP.

The methods prepareSend, sendHeader, expectReplyToHeader, sendIndex, expectAck, and write are important on the originating side of a connection.

The methods expectExtraHeader, respondToHeader, expectIndex, expectSenderSpecifier, and sendAck are important on the receiving side of a connection.

To understand the protocol phases involved, see see Port and connection protocols.

Definition at line 45 of file Carrier.h.

Constructor & Destructor Documentation

◆ ~Carrier()

virtual yarp::os::Carrier::~Carrier ( )
inlinevirtual

Destructor.

Definition at line 321 of file Carrier.h.

Member Function Documentation

◆ acceptIncomingData()

virtual bool yarp::os::Carrier::acceptIncomingData ( ConnectionReader reader)
inlinevirtual

Determine whether incoming data should be accepted.

Parameters
readerfor incoming data.
Returns
true if data should be accepted, false if it should be discarded.

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, yarp::os::PriorityCarrier, and yarp::os::PortMonitor.

Definition at line 398 of file Carrier.h.

◆ acceptOutgoingData()

virtual bool yarp::os::Carrier::acceptOutgoingData ( PortWriter writer)
inlinevirtual

Determine whether outgoing data should be accepted.

Parameters
writerfor outgoing data.
Returns
true if data should be accepted, false if it should be discarded.

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, and yarp::os::PortMonitor.

Definition at line 453 of file Carrier.h.

◆ canAccept()

virtual bool yarp::os::Carrier::canAccept ( )
pure virtual

Check if reading is implemented for this carrier.

Returns
true if carrier can read messages

Implemented in ForwardingCarrier, yarp::os::TcpRosCarrier, yarp::os::XmlRpcCarrier, yarp::os::MjpegCarrier, yarp::os::AbstractCarrier, and HumanCarrier.

◆ canEscape()

virtual bool yarp::os::Carrier::canEscape ( )
pure virtual

Check if carrier can encode administrative messages, as opposed to just user data.

The word escape is used in the sense of escape character or escape sequence here.

Returns
true if carrier can encode administrative messages

Implements yarp::os::Connection.

Implemented in ForwardingCarrier, yarp::os::TcpRosCarrier, yarp::os::XmlRpcCarrier, yarp::os::impl::LocalCarrier, yarp::os::impl::NameserCarrier, yarp::os::MjpegCarrier, yarp::os::MpiCarrier, yarp::os::AbstractCarrier, and HumanCarrier.

◆ canOffer()

virtual bool yarp::os::Carrier::canOffer ( )
pure virtual

Check if writing is implemented for this carrier.

Returns
true if carrier can write messages

Implemented in ForwardingCarrier, yarp::os::TcpRosCarrier, yarp::os::XmlRpcCarrier, yarp::os::MjpegCarrier, yarp::os::AbstractCarrier, and HumanCarrier.

◆ checkHeader()

virtual bool yarp::os::Carrier::checkHeader ( const Bytes header)
pure virtual

Given the first 8 bytes received on a connection, decide if this is the right carrier type to use for the rest of the connection.

For example the "text" carrier looks for the 8-byte sequence "CONNECT ". See the YARP protocol documentation for all the sequences in use here. In general you are free to add your own.

Parameters
headera buffer holding the first 8 bytes received on the connection
Returns
true if this is the carrier to use.

Implemented in ForwardingCarrier, yarp::os::TcpRosCarrier, yarp::os::XmlRpcCarrier, yarp::os::impl::HttpCarrier, yarp::os::MjpegCarrier, yarp::os::impl::LocalCarrier, yarp::os::impl::NameserCarrier, HumanCarrier, yarp::os::MpiCarrier, yarp::os::impl::ShmemCarrier, yarp::os::impl::UdpCarrier, yarp::os::impl::TcpCarrier, yarp::os::impl::TextCarrier, yarp::os::AbstractCarrier, and yarp::os::ModifyingCarrier.

◆ close()

virtual void yarp::os::Carrier::close ( )
inlinevirtual

Close the carrier.

Reimplemented in ForwardingCarrier, yarp::os::BayerCarrier, yarp::os::MpiBcastCarrier, yarp::os::MpiCarrier, and yarp::os::MpiP2PCarrier.

Definition at line 315 of file Carrier.h.

◆ configure()

virtual bool yarp::os::Carrier::configure ( ConnectionState proto)
inlinevirtual

Give carrier a shot at looking at how the connection is set up.

Returns
true if the carrier was correctly configured.

Reimplemented in ForwardingCarrier, yarp::os::PriorityCarrier, and yarp::os::PortMonitor.

Definition at line 463 of file Carrier.h.

◆ configureFromProperty()

virtual bool yarp::os::Carrier::configureFromProperty ( yarp::os::Property options)
inlinevirtual

Reimplemented in ForwardingCarrier, yarp::os::PortMonitor, and yarp::os::ModifyingCarrier.

Definition at line 467 of file Carrier.h.

◆ connect()

virtual int yarp::os::Carrier::connect ( const Contact src,
const Contact dest,
const ContactStyle style,
int  mode,
bool  reversed 
)
inlinevirtual

Some carrier types may require special connection logic.

This can be implemented here. Normally this is not necessary.

Parameters
srcInitiator of the connection.
destDestination of the connection.
styleOptions for connection.
modeYARP_ENACT_CONNECT / YARP_ENACT_DISCONNECT / YARP_ENACT_EXISTS.
reversedtrue for pull connections, false for push connections.
Returns
-1 if no attempt made to connect, 0 on success, 1 on failure.

Reimplemented in ForwardingCarrier, and yarp::os::TcpRosCarrier.

Definition at line 354 of file Carrier.h.

◆ create()

◆ expectAck()

virtual bool yarp::os::Carrier::expectAck ( ConnectionState proto)
pure virtual

Receive an acknowledgement, if expected for this carrier.

Parameters
protothe protocol object, which tracks connection state
Returns
true on success, false on failure

Implemented in ForwardingCarrier, yarp::os::MjpegCarrier, yarp::os::XmlRpcCarrier, yarp::os::TcpRosCarrier, HumanCarrier, yarp::os::impl::HttpCarrier, yarp::os::MpiCarrier, yarp::os::impl::NameserCarrier, yarp::os::AbstractCarrier, and yarp::os::impl::TextCarrier.

◆ expectExtraHeader()

virtual bool yarp::os::Carrier::expectExtraHeader ( ConnectionState proto)
pure virtual

Receive any carrier-specific header.

Parameters
protothe protocol object, which tracks connection state
Returns
true on success, false on failure

Implemented in ForwardingCarrier, yarp::os::XmlRpcCarrier, yarp::os::MjpegCarrier, yarp::os::TcpRosCarrier, HumanCarrier, yarp::os::impl::LocalCarrier, yarp::os::AbstractCarrier, and yarp::os::impl::McastCarrier.

◆ expectIndex()

virtual bool yarp::os::Carrier::expectIndex ( ConnectionState proto)
pure virtual

Expect a message header, if there is one for this carrier.

Parameters
protothe protocol object, which tracks connection state
Returns
true on success, false on failure

Implemented in ForwardingCarrier, yarp::os::MjpegCarrier, yarp::os::XmlRpcCarrier, yarp::os::TcpRosCarrier, HumanCarrier, yarp::os::impl::HttpCarrier, yarp::os::impl::LocalCarrier, yarp::os::MpiCarrier, yarp::os::impl::NameserCarrier, yarp::os::AbstractCarrier, and yarp::os::impl::TextCarrier.

◆ expectReplyToHeader()

virtual bool yarp::os::Carrier::expectReplyToHeader ( ConnectionState proto)
pure virtual

◆ expectSenderSpecifier()

virtual bool yarp::os::Carrier::expectSenderSpecifier ( ConnectionState proto)
pure virtual

Expect the name of the sending port.

Parameters
protothe protocol object, which tracks connection state
Returns
true on success, false on failure

Implemented in ForwardingCarrier, yarp::os::XmlRpcCarrier, yarp::os::TcpRosCarrier, yarp::os::MjpegCarrier, yarp::os::impl::HttpCarrier, HumanCarrier, yarp::os::impl::NameserCarrier, yarp::os::MpiCarrier, yarp::os::AbstractCarrier, and yarp::os::impl::TextCarrier.

◆ getBootstrapCarrierName()

virtual ConstString yarp::os::Carrier::getBootstrapCarrierName ( )
inlinevirtual

Get the name of the carrier that should be used prior to handshaking, if a port is registered with this carrier as its default carrier.

Normally, this should be "tcp".

For carriers intended to interoperate with foreign ports not capable of initiating streams, the bootstrap carrier name should be left blank. YARP may use that fact to arrange for alternate methods of initiating a stream.

Returns
the name of the bootstrap carrier.

Reimplemented in ForwardingCarrier, yarp::os::MjpegCarrier, yarp::os::XmlRpcCarrier, and yarp::os::TcpRosCarrier.

Definition at line 338 of file Carrier.h.

◆ getCarrierParams()

virtual void yarp::os::Carrier::getCarrierParams ( Property params)
inlinevirtual

Get carrier configuration and deliver it by port administrative commands.

Parameters
paramsproperties

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, yarp::os::PriorityCarrier, yarp::os::PortMonitor, yarp::os::AbstractCarrier, and yarp::os::ModifyingCarrier.

Definition at line 484 of file Carrier.h.

◆ getHeader()

virtual void yarp::os::Carrier::getHeader ( const Bytes header)
pure virtual

◆ handleEnvelope()

virtual void yarp::os::Carrier::handleEnvelope ( const yarp::os::ConstString envelope)
inlinevirtual

Carriers that do not distinguish data from administrative headers (i.e.

canEscape returns false), can overload this method to handle the envelope inside the stream. On the receiving side, the InputStream will have to overload the yarp::os::InputStream::setReadEnvelopeCallback method, and execute the callback as soon as the envelope is ready.

Parameters
envelopethe envelope to transmit bundled with data.

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, and yarp::os::MjpegCarrier.

Definition at line 158 of file Carrier.h.

◆ isActive()

virtual bool yarp::os::Carrier::isActive ( )
pure virtual

◆ isBroadcast()

virtual bool yarp::os::Carrier::isBroadcast ( )
inlinevirtual

Check if this carrier uses a broadcast mechanism.

This flag is used to determine whether it is appropriate to send "kill" messages using a carrier or whether they should be sent "out-of-band"

Returns
true if carrier uses a broadcast mechanism.

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, yarp::os::impl::McastCarrier, and yarp::os::MpiBcastCarrier.

Definition at line 114 of file Carrier.h.

◆ isConnectionless()

virtual bool yarp::os::Carrier::isConnectionless ( )
pure virtual

Check if this carrier is connectionless (like udp, mcast) or connection based (like tcp).

This flag is used by YARP to determine whether the connection can carry RPC traffic, that is, messages with replies. Replies are not supported by YARP on connectionless carriers.

Returns
true if carrier is connectionless

Implements yarp::os::Connection.

Implemented in ForwardingCarrier, yarp::os::TcpRosCarrier, yarp::os::impl::LocalCarrier, yarp::os::XmlRpcCarrier, yarp::os::MjpegCarrier, yarp::os::MpiCarrier, yarp::os::impl::ShmemCarrier, yarp::os::impl::UdpCarrier, yarp::os::impl::TcpCarrier, yarp::os::AbstractCarrier, and HumanCarrier.

◆ isLocal()

virtual bool yarp::os::Carrier::isLocal ( )
pure virtual

Check if carrier operates within a single process.

In such a case, YARP connections may get completely reorganized in order to optimize them.

Returns
true if carrier will only operate within a single process

Implements yarp::os::Connection.

Implemented in ForwardingCarrier, yarp::os::TcpRosCarrier, yarp::os::XmlRpcCarrier, yarp::os::MjpegCarrier, yarp::os::impl::LocalCarrier, HumanCarrier, and yarp::os::AbstractCarrier.

◆ isPush()

virtual bool yarp::os::Carrier::isPush ( )
inlinevirtual

Check if carrier is "push" or "pull" style.

Push means that the side that initiates a connection is also the one that will sending of data or commands. All native YARP connections are like this. A "pull" style is equivalent to automatically sending a "reverse connection" port command at the start of the connection.

Returns
true if carrier is "push" style, false if "pull" style

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, yarp::os::TcpRosCarrier, and yarp::os::MjpegCarrier.

Definition at line 200 of file Carrier.h.

◆ isTextMode()

virtual bool yarp::os::Carrier::isTextMode ( )
pure virtual

◆ modifiesIncomingData()

virtual bool yarp::os::Carrier::modifiesIncomingData ( )
inlinevirtual

Check if this carrier modifies incoming data through the Carrier::modifyIncomingData method.

Returns
true if carrier wants Carrier::modifyIncomingData called.

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, and yarp::os::ModifyingCarrier.

Definition at line 369 of file Carrier.h.

◆ modifiesOutgoingData()

virtual bool yarp::os::Carrier::modifiesOutgoingData ( )
inlinevirtual

Check if this carrier modifies outgoing data through the Carrier::modifyOutgoingData method.

Returns
true if carrier wants Carrier::modifyOutgoingData called.

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, and yarp::os::ModifyingCarrier.

Definition at line 408 of file Carrier.h.

◆ modifiesReply()

virtual bool yarp::os::Carrier::modifiesReply ( )
inlinevirtual

Check if this carrier modifies outgoing data through the Carrier::modifyReply method.

Returns
true if carrier wants Carrier::modifyReply called.

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, and yarp::os::ModifyingCarrier.

Definition at line 432 of file Carrier.h.

◆ modifyIncomingData()

virtual ConnectionReader& yarp::os::Carrier::modifyIncomingData ( ConnectionReader reader)
inlinevirtual

Modify incoming payload data, if appropriate.

Doesn't need to be done immediately, it is fine to hold onto a reference to the incoming data reader and use it on demand. This can be handy in order to avoid unnecessary copies.

Parameters
readerfor incoming data.
Returns
reader for modified version of incoming data.
Note
If the ConnectionReader returned is not the same as the one in input, the setParentConnectionReader(&reader) should be called for the new one, or the envelope will not be handled correctly.

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, yarp::os::BayerCarrier, and yarp::os::PortMonitor.

Definition at line 387 of file Carrier.h.

◆ modifyOutgoingData()

virtual PortWriter& yarp::os::Carrier::modifyOutgoingData ( PortWriter writer)
inlinevirtual

Modify outgoing payload data, if appropriate.

Doesn't need to be done immediately, it is fine to hold onto a reference to the outgoing data reader and use it on demand. This can be handy in order to avoid unnecessary copies.

Parameters
writerfor outgoing data.
Returns
writer for modified version of outgoing data.

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, and yarp::os::PortMonitor.

Definition at line 422 of file Carrier.h.

◆ modifyReply()

virtual PortReader& yarp::os::Carrier::modifyReply ( PortReader reader)
inlinevirtual

Modify reply payload data, if appropriate.

Parameters
readerfor the replied message.
Returns
reader for modified version of the replied message.

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, and yarp::os::PortMonitor.

Definition at line 442 of file Carrier.h.

◆ prepareDisconnect()

virtual void yarp::os::Carrier::prepareDisconnect ( )
inlinevirtual

Do cleanup and preparation for the coming disconnect, if necessary.

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, and yarp::os::MpiBcastCarrier.

Definition at line 302 of file Carrier.h.

◆ prepareSend()

virtual bool yarp::os::Carrier::prepareSend ( ConnectionState proto)
pure virtual

Perform any initialization needed before writing on a connection.

Parameters
protothe protocol object, which tracks connection state
Returns
true on success, false on failure

Implemented in ForwardingCarrier, yarp::os::XmlRpcCarrier, yarp::os::TcpRosCarrier, yarp::os::MjpegCarrier, HumanCarrier, and yarp::os::AbstractCarrier.

◆ reply()

bool Carrier::reply ( ConnectionState proto,
SizedWriter writer 
)
virtual

◆ requireAck()

virtual bool yarp::os::Carrier::requireAck ( )
pure virtual

◆ respondToHeader()

◆ sendAck()

virtual bool yarp::os::Carrier::sendAck ( ConnectionState proto)
pure virtual

Send an acknowledgement, if needed for this carrier.

Parameters
protothe protocol object, which tracks connection state
Returns
true on success, false on failure

Implemented in ForwardingCarrier, yarp::os::MjpegCarrier, yarp::os::XmlRpcCarrier, yarp::os::TcpRosCarrier, HumanCarrier, yarp::os::impl::HttpCarrier, yarp::os::MpiCarrier, yarp::os::impl::NameserCarrier, yarp::os::AbstractCarrier, and yarp::os::impl::TextCarrier.

◆ sendHeader()

virtual bool yarp::os::Carrier::sendHeader ( ConnectionState proto)
pure virtual

Write a header appropriate to the carrier to the connection, followed by any carrier-specific data.

Must communicate at least the name of the originating port, if there is one.

Parameters
protothe protocol object, which tracks connection state
Returns
true on success, false on failure

Implemented in ForwardingCarrier, yarp::os::XmlRpcCarrier, yarp::os::TcpRosCarrier, yarp::os::MjpegCarrier, yarp::os::impl::HttpCarrier, HumanCarrier, yarp::os::impl::LocalCarrier, yarp::os::impl::NameserCarrier, yarp::os::MpiCarrier, yarp::os::impl::McastCarrier, yarp::os::AbstractCarrier, and yarp::os::impl::TextCarrier.

◆ setCarrierParams()

virtual void yarp::os::Carrier::setCarrierParams ( const Property params)
inlinevirtual

Configure carrier from port administrative commands.

Parameters
paramsproperties

Implements yarp::os::Connection.

Reimplemented in ForwardingCarrier, yarp::os::PriorityCarrier, yarp::os::PortMonitor, yarp::os::AbstractCarrier, and yarp::os::ModifyingCarrier.

Definition at line 476 of file Carrier.h.

◆ setParameters()

virtual void yarp::os::Carrier::setParameters ( const Bytes header)
pure virtual

Configure this carrier based on the first 8 bytes of the connection.

This will only be called if checkHeader passed.

Parameters
headera buffer holding the first 8 bytes received on the connection

Implemented in ForwardingCarrier, yarp::os::XmlRpcCarrier, yarp::os::TcpRosCarrier, yarp::os::MjpegCarrier, yarp::os::impl::HttpCarrier, yarp::os::impl::LocalCarrier, HumanCarrier, yarp::os::impl::ShmemCarrier, yarp::os::impl::UdpCarrier, yarp::os::impl::TcpCarrier, and yarp::os::AbstractCarrier.

◆ supportReply()

virtual bool yarp::os::Carrier::supportReply ( )
pure virtual

This flag is used by YARP to determine whether the connection can carry RPC traffic, that is, messages with replies.

Returns
true if carrier supports replies

Implements yarp::os::Connection.

Implemented in ForwardingCarrier, yarp::os::impl::HttpCarrier, yarp::os::TcpRosCarrier, yarp::os::XmlRpcCarrier, yarp::os::MjpegCarrier, yarp::os::impl::NameserCarrier, yarp::os::MpiBcastCarrier, yarp::os::MpiP2PCarrier, yarp::os::MpiCarrier, HumanCarrier, yarp::os::AbstractCarrier, and yarp::os::impl::TextCarrier.

◆ toString()

virtual ConstString yarp::os::Carrier::toString ( )
pure virtual

◆ write()

virtual bool yarp::os::Carrier::write ( ConnectionState proto,
SizedWriter writer 
)
pure virtual

Write a message.

Parameters
protothe protocol object, which tracks connection state
Returns
true on success, false on failure

Implemented in ForwardingCarrier, yarp::os::MjpegCarrier, yarp::os::XmlRpcCarrier, yarp::os::TcpRosCarrier, yarp::os::impl::HttpCarrier, HumanCarrier, yarp::os::impl::LocalCarrier, yarp::os::impl::NameserCarrier, yarp::os::AbstractCarrier, and yarp::os::MpiCarrier.


The documentation for this class was generated from the following files: