DDS  ver. 3.6
Classes | Typedefs | Enumerations | Functions | Variables
dds::intercom_api Namespace Reference

DDS intercom API. More...

Classes

class  CCustomCmd
 
class  CIntercomService
 
class  CKeyValue
 
class  CRMSPluginProtocol
 Class implements basic API for DDS RMS plug-ins. More...
 
struct  SInit
 Structure holds information of init notification. More...
 
struct  SMessage
 Structure holds information of message notification. More...
 
struct  SSubmit
 Structure holds information of submit notification. More...
 

Typedefs

typedef boost::signals2::signal< void(EErrorCode, const std::string &)> errorSignal_t
 

Enumerations

enum  EMsgSeverity { EMsgSeverity::info, EMsgSeverity::error }
 Enumeration with message severity. More...
 
enum  EErrorCode {
  ConnectionFailed, RemoteEndDisconnected, TransportServiceFailed, UpdateKeyValueFailed,
  SendKeyValueFailed, SendCustomCmdFailed, KeyValueVersionMismatch, KeyValueNotFound,
  UserCodeException
}
 Error codes for intercom API. More...
 

Functions

std::ostream & operator<< (std::ostream &_os, EMsgSeverity _severity)
 Support ostreaming EMsgSeverity. More...
 

Variables

const std::string g_sRmsAgentSign = "rms_agent_sign"
 Sign that is send to commander if RMS plug-in is connecting to it. More...
 
const std::string g_sToolsAPISign = "tools_api_sign"
 Sign that is send to commander if Tools-API is connecting to it. More...
 

Detailed Description

DDS intercom API.

\detail Internally CKeyValue and CCustomCmd use shared memory transport to talk to DDS agent. CCustomCmd can also connect to DDS commander. In case of a problem it tries to reconnect for 2 minutes and if not connected send an error with EErrorCode::ConnectionFailed error code. If none of the DDS services are running a different error is sent - EErrorCode::TransportServiceFailed. In the error message a detailed information is provided about what caused the error. In order to get an error messages from DDS one should subscribe using CIntercomService::subscribeOnError(errorSignal_t::slot_function_type _subscriber) function.

Typedef Documentation

◆ errorSignal_t

typedef boost::signals2::signal<void(EErrorCode, const std::string&)> dds::intercom_api::errorSignal_t

Enumeration Type Documentation

◆ EErrorCode

Error codes for intercom API.

Enumerator
ConnectionFailed 

Failed to connect either to DDS commander or to DDS agent.

RemoteEndDisconnected 

Remote end closed the connection.

TransportServiceFailed 

Error in the transport, for example, if DDS is not running.

UpdateKeyValueFailed 

Key-value update error on the DDS commander side.

SendKeyValueFailed 

Error sending key-value (if not connected to DDS commander or DDS agent).

SendCustomCmdFailed 

Error sending custom command (if not connected to DDS commander or DDS agent).

KeyValueVersionMismatch 

Key value update request failed because version is too old.

KeyValueNotFound 

Key value update failed due to the wrong key.

UserCodeException 

Exception in the user code.

◆ EMsgSeverity

Enumeration with message severity.

Enumerator
info 

Information messages.

error 

Error messages.

Function Documentation

◆ operator<<()

std::ostream& dds::intercom_api::operator<< ( std::ostream &  _os,
EMsgSeverity  _severity 
)
inline

Support ostreaming EMsgSeverity.

Variable Documentation

◆ g_sRmsAgentSign

const std::string dds::intercom_api::g_sRmsAgentSign = "rms_agent_sign"

Sign that is send to commander if RMS plug-in is connecting to it.

◆ g_sToolsAPISign

const std::string dds::intercom_api::g_sToolsAPISign = "tools_api_sign"

Sign that is send to commander if Tools-API is connecting to it.