RTC Toolkit 5.1.0
Loading...
Searching...
No Matches
Public Member Functions | List of all members
rtctk::standaloneTools::GenRtrWriter< T > Class Template Reference

Generic RTR Writer Class provides functionally to create one RTR's DP DDS, and one thread that writes value to the DP in a loop. More...

#include <rtctkGenRtrWriter.h>

Inheritance diagram for rtctk::standaloneTools::GenRtrWriter< T >:
rtctk::standaloneTools::GenRtrWriterBase

Public Member Functions

 GenRtrWriter (std::shared_ptr< rtctk_cfw::RuntimeRepoIf > &rtr, const rtctk_cfw::DataPointPath &dp, const std::string &server_alias="")
 
virtual ~GenRtrWriter () noexcept
 
 GenRtrWriter ()=delete
 
 GenRtrWriter (const GenRtrWriter &)=delete
 
 GenRtrWriter (GenRtrWriter &&)=delete
 
void Initialize (std::size_t dim_x, std::size_t dim_y, std::chrono::microseconds period, uint32_t iterations)
 Creates Data Point (DP) and publishing thread.
 
- Public Member Functions inherited from rtctk::standaloneTools::GenRtrWriterBase
 GenRtrWriterBase (std::shared_ptr< rtctk_cfw::RuntimeRepoIf > &rtr, const rtctk_cfw::DataPointPath &dp, const std::string &server_alias="")
 
virtual ~GenRtrWriterBase () noexcept
 
 GenRtrWriterBase ()=delete
 
 GenRtrWriterBase (const GenRtrWriterBase &)=delete
 
 GenRtrWriterBase (GenRtrWriterBase &&)=delete
 
void SignalThreadExit ()
 
void Finalize ()
 Stops publishing thread, and join it, delete data point (DP).
 
void Join ()
 

Additional Inherited Members

- Static Public Attributes inherited from rtctk::standaloneTools::GenRtrWriterBase
static std::atomic< uint16_t > s_idx = 0
 
- Protected Attributes inherited from rtctk::standaloneTools::GenRtrWriterBase
log4cplus::Logger & m_logger
 
uint16_t m_idx
 
std::shared_ptr< rtctk_cfw::RuntimeRepoIfm_rtr
 
rtctk_cfw::DataPointPath m_dp
 
std::string m_server_alias
 
bool m_dp_created
 
uint32_t m_payload_bytes
 
std::chrono::microseconds m_sleep_period
 
uint32_t m_iteration_num
 
std::thread m_thread
 
std::atomic< bool > m_thread_running = true
 
ba::accumulator_set< unsigned, ba::stats< ba::tag::mean, ba::tag::variance, ba::tag::min, ba::tag::max, ba::tag::count > > m_accumulator
 

Detailed Description

template<typename T>
class rtctk::standaloneTools::GenRtrWriter< T >

Generic RTR Writer Class provides functionally to create one RTR's DP DDS, and one thread that writes value to the DP in a loop.

So each object in parallel writes a value to RTR.

Note
It is intended to be used just internally in rtctkGenRtrWrite (maybe later in a dedicated dat task)

Constructor & Destructor Documentation

◆ GenRtrWriter() [1/4]

template<typename T >
rtctk::standaloneTools::GenRtrWriter< T >::GenRtrWriter ( std::shared_ptr< rtctk_cfw::RuntimeRepoIf > & rtr,
const rtctk_cfw::DataPointPath & dp,
const std::string & server_alias = "" )
inlineexplicit

◆ ~GenRtrWriter()

template<typename T >
virtual rtctk::standaloneTools::GenRtrWriter< T >::~GenRtrWriter ( )
inlinevirtualnoexcept

◆ GenRtrWriter() [2/4]

template<typename T >
rtctk::standaloneTools::GenRtrWriter< T >::GenRtrWriter ( )
delete

◆ GenRtrWriter() [3/4]

template<typename T >
rtctk::standaloneTools::GenRtrWriter< T >::GenRtrWriter ( const GenRtrWriter< T > & )
delete

◆ GenRtrWriter() [4/4]

template<typename T >
rtctk::standaloneTools::GenRtrWriter< T >::GenRtrWriter ( GenRtrWriter< T > && )
delete

Member Function Documentation

◆ Initialize()

template<typename T >
void rtctk::standaloneTools::GenRtrWriter< T >::Initialize ( std::size_t dim_x,
std::size_t dim_y,
std::chrono::microseconds period,
uint32_t iterations )
inlinevirtual

Creates Data Point (DP) and publishing thread.

Parameters
dim_xX size of the matrix
dim_yY size of the matrix
periodsleep between iterations
iterationsnumber of iterations

Implements rtctk::standaloneTools::GenRtrWriterBase.


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