OpenDaVINCI  4.16.0
odcore::io::protocol::AbstractProtocol Class Referenceabstract

#include <AbstractProtocol.h>

Inheritance diagram for odcore::io::protocol::AbstractProtocol:
Inheritance graph

Public Member Functions

virtual ~AbstractProtocol ()
void setStringSender (StringSender *sender)
void sendByStringSender (const string &data)
virtual void nextString (const string &s)=0

Protected Member Functions

 AbstractProtocol ()

Detailed Description

Base class for realizing byte sequence protocols.

Constructor & Destructor Documentation

odcore::io::protocol::AbstractProtocol::AbstractProtocol ( )

Protected constructor to enforce subclasses.

odcore::io::protocol::AbstractProtocol::~AbstractProtocol ( )

References setStringSender().

Member Function Documentation

virtual void odcore::io::StringListener::nextString ( const string &  s)
pure virtualinherited
void odcore::io::protocol::AbstractProtocol::sendByStringSender ( const string &  data)

This method needs to be called by subclasses to actually send some data according to the implemented protocol.

dataData to be sent.

References odcore::io::StringSender::send().

Referenced by odcore::io::protocol::StringProtocol::send(), and odcore::io::protocol::NetstringsProtocol::send().

void odcore::io::protocol::AbstractProtocol::setStringSender ( StringSender sender)

This method sets the StringSender (implemented by a connection like SerialPort) that can actually send the data.

senderStringSender that will send the data.

Referenced by ~AbstractProtocol().