a generic variable template: value + flag to know if the variable is set More...
#include <libstaroffice_internal.hxx>
Public Member Functions | |
STOFFVariable () | |
constructor | |
STOFFVariable (T const &def) | |
constructor with a default value | |
STOFFVariable (STOFFVariable const &orig) | |
copy constructor | |
STOFFVariable & | operator= (STOFFVariable const &orig) |
copy operator | |
STOFFVariable & | operator= (T const &val) |
set a value | |
void | insert (STOFFVariable const &orig) |
update the current value if orig is set | |
T const * | operator-> () const |
operator* | |
T * | operator-> () |
operator* | |
T const & | operator* () const |
operator* | |
T & | operator* () |
operator* | |
T const & | get () const |
return the current value | |
bool | isSet () const |
return true if the variable is set | |
void | setSet (bool newVal) |
define if the variable is set | |
Protected Attributes | |
T | m_data |
the value | |
bool | m_set |
a flag to know if the variable is set or not |
a generic variable template: value + flag to know if the variable is set
STOFFVariable< T >::STOFFVariable | ( | ) | [inline] |
constructor
STOFFVariable< T >::STOFFVariable | ( | T const & | def | ) | [inline, explicit] |
constructor with a default value
STOFFVariable< T >::STOFFVariable | ( | STOFFVariable< T > const & | orig | ) | [inline] |
copy constructor
T const& STOFFVariable< T >::get | ( | ) | const [inline] |
return the current value
void STOFFVariable< T >::insert | ( | STOFFVariable< T > const & | orig | ) | [inline] |
update the current value if orig is set
bool STOFFVariable< T >::isSet | ( | ) | const [inline] |
return true if the variable is set
T const& STOFFVariable< T >::operator* | ( | ) | const [inline] |
operator*
T& STOFFVariable< T >::operator* | ( | ) | [inline] |
operator*
T const* STOFFVariable< T >::operator-> | ( | ) | const [inline] |
operator*
T* STOFFVariable< T >::operator-> | ( | ) | [inline] |
operator*
STOFFVariable& STOFFVariable< T >::operator= | ( | STOFFVariable< T > const & | orig | ) | [inline] |
copy operator
STOFFVariable& STOFFVariable< T >::operator= | ( | T const & | val | ) | [inline] |
set a value
void STOFFVariable< T >::setSet | ( | bool | newVal | ) | [inline] |
define if the variable is set
T STOFFVariable< T >::m_data [protected] |
the value
Referenced by STOFFVariable< T >::get(), STOFFVariable< T >::insert(), STOFFVariable< T >::operator*(), STOFFVariable< T >::operator->(), and STOFFVariable< T >::operator=().
bool STOFFVariable< T >::m_set [protected] |
a flag to know if the variable is set or not
Referenced by STOFFVariable< T >::insert(), STOFFVariable< T >::isSet(), STOFFVariable< T >::operator*(), STOFFVariable< T >::operator->(), STOFFVariable< T >::operator=(), and STOFFVariable< T >::setSet().