WriteBufferedTripleBuffer< T > Class Template Reference

Same as the TripleBuffer, but partial writes of the data structure are ok. The write operation may be a bit slower and memory consumption may be 1/3 higher. More...

#include <ArmarXCore/util/CPPUtility/TripleBuffer.h>

Public Member Functions

T_getNonConstHiddenBuffer ()
 
T_getNonConstHiddenWriteBuffer ()
 
T_getNonConstReadBuffer ()
 
void commitWrite ()
 
const TgetReadBuffer () const
 
const TgetUpToDateReadBuffer () const
 
TgetWriteBuffer ()
 
const TgetWriteBuffer () const
 
void reinitAllBuffers (const T &init)
 
void setDebugMode (bool mode)
 
bool updateReadBuffer () const
 Swaps in the hidden buffer if it contains new data. More...
 
 WriteBufferedTripleBuffer ()
 
 WriteBufferedTripleBuffer (const T &init)
 

Detailed Description

template<typename T>
class armarx::WriteBufferedTripleBuffer< T >

Same as the TripleBuffer, but partial writes of the data structure are ok. The write operation may be a bit slower and memory consumption may be 1/3 higher.

See also
TripleBuffer

Definition at line 267 of file TripleBuffer.h.

Constructor & Destructor Documentation

◆ WriteBufferedTripleBuffer() [1/2]

Definition at line 270 of file TripleBuffer.h.

◆ WriteBufferedTripleBuffer() [2/2]

WriteBufferedTripleBuffer ( const T init)
inline

Definition at line 274 of file TripleBuffer.h.

Member Function Documentation

◆ _getNonConstHiddenBuffer()

T& _getNonConstHiddenBuffer ( )
inline
Returns
the current read buffer (sometimes required for more complex initialization)

Definition at line 307 of file TripleBuffer.h.

◆ _getNonConstHiddenWriteBuffer()

T& _getNonConstHiddenWriteBuffer ( )
inline
Returns
the current read buffer (sometimes required for more complex initialization)

Definition at line 312 of file TripleBuffer.h.

◆ _getNonConstReadBuffer()

T& _getNonConstReadBuffer ( )
inline
Returns
the current read buffer (sometimes required for more complex initialization)

Definition at line 302 of file TripleBuffer.h.

+ Here is the caller graph for this function:

◆ commitWrite()

void commitWrite ( )
inline

Definition at line 326 of file TripleBuffer.h.

◆ getReadBuffer()

const T& getReadBuffer ( ) const
inline
Returns
the current read buffer

Definition at line 291 of file TripleBuffer.h.

+ Here is the caller graph for this function:

◆ getUpToDateReadBuffer()

const T& getUpToDateReadBuffer ( ) const
inline
Returns
the most up to date read buffer

Definition at line 296 of file TripleBuffer.h.

+ Here is the caller graph for this function:

◆ getWriteBuffer() [1/2]

T& getWriteBuffer ( )
inline
Returns
the write buffer

Definition at line 280 of file TripleBuffer.h.

◆ getWriteBuffer() [2/2]

const T& getWriteBuffer ( ) const
inline
Returns
the write buffer

Definition at line 286 of file TripleBuffer.h.

◆ reinitAllBuffers()

void reinitAllBuffers ( const T init)
inline

Definition at line 332 of file TripleBuffer.h.

+ Here is the caller graph for this function:

◆ setDebugMode()

void setDebugMode ( bool  mode)
inline

Definition at line 338 of file TripleBuffer.h.

◆ updateReadBuffer()

bool updateReadBuffer ( ) const
inline

Swaps in the hidden buffer if it contains new data.

Returns
True if new data is available

Definition at line 321 of file TripleBuffer.h.

+ Here is the caller graph for this function:

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