#include <gepetto/viewer/node-property.h>
Public Types | |
typedef shared_ptr< EnumProperty > | Ptr_t |
typedef boost::function< T(void)> | Getter_t |
typedef boost::function< void(const T &)> | Setter_t |
![]() | |
typedef boost::function< void(const T &)> | Setter_t |
typedef boost::function< T(void)> | Getter_t |
typedef shared_ptr< PropertyTpl > | Ptr_t |
Public Member Functions | |
virtual std::string | type () |
const MetaEnum * | metaEnum () const |
EnumProperty (const std::string &name, const MetaEnum *type, const Getter_t &g, const Setter_t &s) | |
bool | set (const int &value) |
Set the enum property. More... | |
![]() | |
PropertyTpl (const std::string &name, const Getter_t &g, const Setter_t &s) | |
bool | set (const T &value) |
bool | get (T &value) |
bool | hasReadAccess () const |
bool | hasWriteAccess () const |
const Getter_t & | getter () const |
void | getter (const Getter_t &g) |
const Setter_t & | setter () const |
void | setter (const Setter_t &s) |
![]() | |
virtual bool | set (const bool &v) |
virtual bool | set (const float &v) |
virtual bool | set (const std::string &v) |
virtual bool | set (const unsigned long &v) |
virtual bool | set (const osgVector2 &v) |
virtual bool | set (const osgVector3 &v) |
virtual bool | set (const osgVector4 &v) |
virtual bool | set (const Configuration &v) |
virtual bool | get (bool &v) |
virtual bool | get (int &v) |
virtual bool | get (float &v) |
virtual bool | get (std::string &v) |
virtual bool | get (unsigned long &v) |
virtual bool | get (osgVector2 &v) |
virtual bool | get (osgVector3 &v) |
virtual bool | get (osgVector4 &v) |
virtual bool | get (Configuration &v) |
const std::string & | name () const |
Static Public Member Functions | |
static Ptr_t | create (const std::string &name, const MetaEnum *type, const Getter_t &g, const Setter_t &s) |
![]() | |
static Ptr_t | create (const std::string &name, const Getter_t &g, const Setter_t &s) |
template<typename Obj > | |
static Getter_t | getterFromMemberFunction (Obj *obj, const T &(Obj::*mem_func)() const) |
template<typename Obj > | |
static Getter_t | getterFromMemberFunction (Obj *obj, T(Obj::*mem_func)() const) |
template<typename Obj > | |
static Setter_t | setterFromMemberFunction (Obj *obj, void(Obj::*mem_func)(const T &)) |
template<typename Obj > | |
static Setter_t | setterFromMemberFunction (Obj *obj, void(Obj::*mem_func)(T)) |
Additional Inherited Members | |
![]() | |
Property (const std::string &name) | |
template<typename T > | |
void | invalidType (T) const |
void | invalidGet () const |
void | invalidSet () const |
![]() | |
const std::string | name_ |
typedef boost::function< T (void)> gepetto::viewer::PropertyTpl< T >::Getter_t |
typedef shared_ptr<EnumProperty> gepetto::viewer::EnumProperty::Ptr_t |
typedef boost::function<void(const T&)> gepetto::viewer::PropertyTpl< T >::Setter_t |
|
inline |
|
inlinestatic |
|
inline |
|
virtual |
Set the enum property.
It also checks that value
is a valid enum.
Reimplemented from gepetto::viewer::Property.
|
inlinevirtual |
Reimplemented from gepetto::viewer::PropertyTpl< T >.