g2o
Loading...
Searching...
No Matches
g2o::Property< T > Class Template Reference

#include <property.h>

Inheritance diagram for g2o::Property< T >:
Collaboration diagram for g2o::Property< T >:

Public Types

typedef T ValueType

Public Member Functions

 Property (const std::string &name_)
 Property (const std::string &name_, const T &v)
void setValue (const T &v)
const T & value () const
virtual std::string toString () const
virtual bool fromString (const std::string &s)
Public Member Functions inherited from g2o::BaseProperty
 BaseProperty (const std::string &name_)
virtual ~BaseProperty ()
const std::string & name ()

Protected Attributes

T _value
Protected Attributes inherited from g2o::BaseProperty
std::string _name

Detailed Description

template<typename T>
class g2o::Property< T >

Definition at line 52 of file property.h.

Member Typedef Documentation

◆ ValueType

template<typename T>
typedef T g2o::Property< T >::ValueType

Definition at line 54 of file property.h.

Constructor & Destructor Documentation

◆ Property() [1/2]

template<typename T>
g2o::Property< T >::Property ( const std::string & name_)
inline

Definition at line 55 of file property.h.

BaseProperty(const std::string &name_)
Definition property.cpp:39

◆ Property() [2/2]

template<typename T>
g2o::Property< T >::Property ( const std::string & name_,
const T & v )
inline

Definition at line 56 of file property.h.

Member Function Documentation

◆ fromString()

template<typename T>
virtual bool g2o::Property< T >::fromString ( const std::string & s)
inlinevirtual

Implements g2o::BaseProperty.

Definition at line 65 of file property.h.

65 {
67 return status;
68 }
bool convertString(const std::string &s, T &x, bool failIfLeftoverChars=true)

◆ setValue()

template<typename T>
void g2o::Property< T >::setValue ( const T & v)
inline

Definition at line 58 of file property.h.

58{ _value = v; }

Referenced by PropertiesWidget::applyProperties().

◆ toString()

template<typename T>
virtual std::string g2o::Property< T >::toString ( ) const
inlinevirtual

Implements g2o::BaseProperty.

Definition at line 60 of file property.h.

60 {
62 sstr << _value;
63 return sstr.str();
64 }

◆ value()

template<typename T>
const T & g2o::Property< T >::value ( ) const
inline

Definition at line 59 of file property.h.

59{ return _value; }

Referenced by PropertiesWidget::updateDisplayedProperties().

Member Data Documentation

◆ _value

template<typename T>
T g2o::Property< T >::_value
protected

Definition at line 71 of file property.h.


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