ddt 1.2.1
Loading...
Searching...
No Matches
List of all members
ddt::DdtDataProducer Class Reference

#include <ddtDataProducer.hpp>

Inheritance diagram for ddt::DdtDataProducer:
ddt::DdtProducerConsumerBase
 DdtDataProducer (DdtLogger *logger)
 
 DdtDataProducer (const std::string &data_stream_identifier, const int32_t latency, const int32_t deadline, const std::string publishing_uri, DdtLogger *logger)
 
 ~DdtDataProducer () override
 
void Publish (DataPacket data_packet)
 
void Notify (const NotificationType type) override
 
std::string get_publishing_uri () const
 

Additional Inherited Members

- Public Types inherited from ddt::DdtProducerConsumerBase
enum  NotificationType { NEW_DATA , PUB_REG , PUB_UNREG , SHM_DEL }
 
- Public Member Functions inherited from ddt::DdtProducerConsumerBase
 DdtProducerConsumerBase (DdtLogger *ddt_logger)
 
virtual ~DdtProducerConsumerBase ()
 
- Protected Member Functions inherited from ddt::DdtProducerConsumerBase
void Init (DdtLogger *ddt_logger)
 
void LoadDefaults ()
 
void ReadIni ()
 
void PrintConfigValues ()
 
int32_t GetFreePort () const
 
- Protected Attributes inherited from ddt::DdtProducerConsumerBase
int32_t min_port
 
int32_t max_port
 
DdtLoggerlogger
 
const int MIN_PORT_DEFAULT = 5100
 
const int MAX_PORT_DEFAULT = 5500
 
const int MIN_RANGE = 3
 
const int LINE_LENGTH = 256
 

Detailed Description

This class provides the functionality to publish data over network and enables sending new data notifications.

Constructor & Destructor Documentation

◆ DdtDataProducer() [1/2]

DdtDataProducer::DdtDataProducer ( DdtLogger * logger)
explicit

Constructor

Parameters
loggerA DDT logger object (no transfer of ownership).

◆ DdtDataProducer() [2/2]

DdtDataProducer::DdtDataProducer ( const std::string & data_stream_identifier,
const int32_t latency,
const int32_t deadline,
const std::string publishing_uri,
DdtLogger * logger )

Constructor

Parameters
data_stream_identifierThe data stream identifier.
latencyA MAL QoS parameter. Shall be the maximum time a sample may remain in-transit between the publisher and subscriber in [ms].
deadlineA MAL QoS parameter. Shall be the maximum age of a sample in [s].
publishing_uriThe publishing URI.
loggerA DDT logger object (no transfer of ownership).

◆ ~DdtDataProducer()

DdtDataProducer::~DdtDataProducer ( )
overridedefault

Destructor

Member Function Documentation

◆ get_publishing_uri()

std::string DdtDataProducer::get_publishing_uri ( ) const

Returns publishing_uri.

Returns
The publishing URI.

◆ Notify()

void DdtDataProducer::Notify ( const NotificationType type)
overridevirtual

Attaches a notification to the data packet and sends it via MALps to remote brokers.

Parameters
typeThe type of the notification.

Implements ddt::DdtProducerConsumerBase.

◆ Publish()

void DdtDataProducer::Publish ( DataPacket data_packet)

Publishes the data over network.

Parameters
data_packetThe data packet.

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