Public Member Functions | Private Attributes | List of all members
xsens::JanitorRestore< T > Class Template Reference

Value restoring janitor class. More...

#include <xsens_janitors.h>

Public Member Functions

void disable (void)
 Disables the value restoring. More...
 
void enable (void)
 Enables the value restoring. More...
 
 JanitorRestore (T &control, bool enabl=true)
 Constructor. More...
 
 ~JanitorRestore ()
 Destructor. More...
 

Private Attributes

T & m_control
 
bool m_enabled
 
m_value
 

Detailed Description

template<class T>
class xsens::JanitorRestore< T >

Value restoring janitor class.

This class can be used to make sure that the value that is in the variable at the time the janitor is created will be in it again when the janitor leaves scope.

Definition at line 106 of file xsens_janitors.h.

Constructor & Destructor Documentation

◆ JanitorRestore()

template<class T >
xsens::JanitorRestore< T >::JanitorRestore ( T &  control,
bool  enabl = true 
)
inline

Constructor.

Definition at line 116 of file xsens_janitors.h.

◆ ~JanitorRestore()

template<class T >
xsens::JanitorRestore< T >::~JanitorRestore ( )
inline

Destructor.

Definition at line 121 of file xsens_janitors.h.

Member Function Documentation

◆ disable()

template<class T >
void xsens::JanitorRestore< T >::disable ( void  )
inline

Disables the value restoring.

Definition at line 129 of file xsens_janitors.h.

◆ enable()

template<class T >
void xsens::JanitorRestore< T >::enable ( void  )
inline

Enables the value restoring.

Definition at line 136 of file xsens_janitors.h.

Member Data Documentation

◆ m_control

template<class T >
T& xsens::JanitorRestore< T >::m_control
private

Definition at line 109 of file xsens_janitors.h.

◆ m_enabled

template<class T >
bool xsens::JanitorRestore< T >::m_enabled
private

Definition at line 111 of file xsens_janitors.h.

◆ m_value

template<class T >
T xsens::JanitorRestore< T >::m_value
private

Definition at line 110 of file xsens_janitors.h.


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


xsens_mti_driver
Author(s):
autogenerated on Sun Sep 3 2023 02:43:23