BufferedMemoryMixin< _CoreSegmentT > Class Template Referenceabstract

#include <RobotAPI/libraries/armem/server/ltm/detail/mixins/BufferedMemoryMixin.h>

Public Member Functions

 BufferedMemoryMixin (const MemoryID &id)
 
void bufferFinished ()
 
void directlyStore (const armem::server::wm::Memory &serverMemory)
 
void directlyStore (const armem::wm::Memory &memory)
 
virtual ~BufferedMemoryMixin ()=default
 

Protected Member Functions

virtual void _directlyStore (const armem::wm::Memory &memory)=0
 
void addToBuffer (const armem::wm::Memory &memory)
 
void configureMixin (const nlohmann::json &json)
 configuration More...
 
void createPropertyDefinitions (PropertyDefinitionsPtr &defs, const std::string &prefix)
 
armem::wm::Memory getBuffer () const
 
void setMixinMemoryID (const MemoryID &id)
 
void start ()
 
void stop ()
 
void storeBuffer ()
 

Protected Attributes

std::unique_ptr< armem::wm::Memorybuffer
 Internal memory for data consolidated from wm to ltm (double-buffer) The to-put-to-ltm buffer (contains data in plain text) This buffer may still be filtered (e.g. More...
 
std::atomic_flag storeFlag = ATOMIC_FLAG_INIT
 
float storeFrequency = 10
 The frequency (Hz) to store data to the ltm. More...
 
std::unique_ptr< armem::wm::Memoryto_store
 

Detailed Description

template<class _CoreSegmentT>
class armarx::armem::server::ltm::detail::mixin::BufferedMemoryMixin< _CoreSegmentT >

Definition at line 18 of file BufferedMemoryMixin.h.

Constructor & Destructor Documentation

◆ BufferedMemoryMixin()

BufferedMemoryMixin ( const MemoryID id)
inline

Definition at line 22 of file BufferedMemoryMixin.h.

◆ ~BufferedMemoryMixin()

virtual ~BufferedMemoryMixin ( )
virtualdefault

Member Function Documentation

◆ _directlyStore()

virtual void _directlyStore ( const armem::wm::Memory memory)
protectedpure virtual

Implemented in Memory.

+ Here is the caller graph for this function:

◆ addToBuffer()

void addToBuffer ( const armem::wm::Memory memory)
inlineprotected

Definition at line 143 of file BufferedMemoryMixin.h.

◆ bufferFinished()

void bufferFinished ( )
inline

Definition at line 50 of file BufferedMemoryMixin.h.

◆ configureMixin()

void configureMixin ( const nlohmann::json &  json)
inlineprotected

configuration

Definition at line 124 of file BufferedMemoryMixin.h.

◆ createPropertyDefinitions()

void createPropertyDefinitions ( PropertyDefinitionsPtr defs,
const std::string &  prefix 
)
inlineprotected

Definition at line 135 of file BufferedMemoryMixin.h.

◆ directlyStore() [1/2]

void directlyStore ( const armem::server::wm::Memory serverMemory)
inline

Definition at line 41 of file BufferedMemoryMixin.h.

◆ directlyStore() [2/2]

void directlyStore ( const armem::wm::Memory memory)
inline

Definition at line 31 of file BufferedMemoryMixin.h.

+ Here is the caller graph for this function:

◆ getBuffer()

armem::wm::Memory getBuffer ( ) const
inlineprotected

Definition at line 92 of file BufferedMemoryMixin.h.

◆ setMixinMemoryID()

void setMixinMemoryID ( const MemoryID id)
inlineprotected

Definition at line 57 of file BufferedMemoryMixin.h.

◆ start()

void start ( )
inlineprotected

Definition at line 66 of file BufferedMemoryMixin.h.

◆ stop()

void stop ( )
inlineprotected

Definition at line 81 of file BufferedMemoryMixin.h.

◆ storeBuffer()

void storeBuffer ( )
inlineprotected

Definition at line 99 of file BufferedMemoryMixin.h.

+ Here is the caller graph for this function:

Member Data Documentation

◆ buffer

std::unique_ptr<armem::wm::Memory> buffer
protected

Internal memory for data consolidated from wm to ltm (double-buffer) The to-put-to-ltm buffer (contains data in plain text) This buffer may still be filtered (e.g.

snapshot filters). This means that it is not guaranteed that all data in the buffer will be stored in the ltm

Definition at line 155 of file BufferedMemoryMixin.h.

◆ storeFlag

std::atomic_flag storeFlag = ATOMIC_FLAG_INIT
protected

Definition at line 157 of file BufferedMemoryMixin.h.

◆ storeFrequency

float storeFrequency = 10
protected

The frequency (Hz) to store data to the ltm.

Definition at line 160 of file BufferedMemoryMixin.h.

◆ to_store

std::unique_ptr<armem::wm::Memory> to_store
protected

Definition at line 156 of file BufferedMemoryMixin.h.


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