|
| TreeNode (const std::string &name) |
| Constructor. More...
|
|
virtual | ~TreeNode () |
| Destructor. More...
|
|
int | getId () const |
| Get node ID. More...
|
|
void | setId (const int &id) |
| Set node ID. More...
|
|
void | expand () |
| Expand node. More...
|
|
void | collapse () |
| Collapse node. More...
|
|
void | print (const std::string &indent="") |
| Print tree to console. More...
|
|
const std::vector< Method > & | functions () const |
| Get list of functions exported by this object. More...
|
|
template<typename RET , typename... Arguments> |
void | addFunction (const std::string &name, RET(*fn)(Arguments...)) |
| Add (export) static function. More...
|
|
template<class T , typename RET , typename... Arguments> |
void | addFunction (const std::string &name, T *obj, RET(T::*fn)(Arguments...)) |
| Add (export) method on object. More...
|
|
template<class T , typename RET , typename... Arguments> |
void | addFunction (const std::string &name, T *obj, RET(T::*fn)(Arguments...) const) |
| Add (export) const method on object. More...
|
|
virtual bool | isObject () const override |
| Check if property is an object. More...
|
|
virtual std::unique_ptr< AbstractTyped > | clone () const override |
|
virtual const std::type_info & | type () const override |
|
virtual std::string | typeName () const override |
|
virtual bool | isReadOnly () const override |
|
virtual bool | isComposite () const override |
|
virtual size_t | numSubValues () const override |
|
virtual AbstractTyped * | subValue (size_t i) override |
|
virtual bool | isEnum () const override |
|
virtual bool | isArray () const override |
|
virtual bool | isVariant () const override |
|
virtual bool | isString () const override |
|
virtual bool | isBool () const override |
|
virtual bool | isNumber () const override |
|
virtual bool | isIntegral () const override |
|
virtual bool | isSignedIntegral () const override |
|
virtual bool | isUnsignedIntegral () const override |
|
virtual bool | isFloatingPoint () const override |
|
virtual Variant | toVariant () const override |
|
virtual bool | fromVariant (const Variant &value) override |
|
virtual std::string | toString () const override |
|
virtual bool | fromString (const std::string &value) override |
|
virtual bool | toBool () const override |
|
virtual bool | fromBool (bool value) override |
|
virtual long long | toLongLong () const override |
|
virtual bool | fromLongLong (long long value) override |
|
virtual unsigned long long | toULongLong () const override |
|
virtual bool | fromULongLong (unsigned long long value) override |
|
virtual double | toDouble () const override |
|
virtual bool | fromDouble (double value) override |
|
std::string | relativePathTo (const Object *const other) const |
| Get the relative path to another object. More...
|
|
| Object () |
| Constructor. More...
|
|
| Object (const std::string &name) |
| Constructor. More...
|
|
| Object (const Object &)=delete |
| Copy constructor (deleted) More...
|
|
virtual | ~Object () |
| Destructor. More...
|
|
Object & | operator= (const Object &)=delete |
| Copy assignment operator (deleted) More...
|
|
const std::string & | className () const |
| Get class name. More...
|
|
void | setClassName (const std::string &className) |
| Set class name. More...
|
|
void | clear () |
| Clear properties. More...
|
|
const std::unordered_map< std::string, AbstractProperty * > & | properties () const |
| Get properties. More...
|
|
bool | propertyExists (const std::string &name) const |
| Check if property exists. More...
|
|
AbstractProperty * | property (size_t index) |
| Get property by index. More...
|
|
const AbstractProperty * | property (size_t index) const |
|
AbstractProperty * | property (const std::string &path) |
| Get property by name. More...
|
|
const AbstractProperty * | property (const std::string &path) const |
|
bool | addProperty (AbstractProperty *property) |
| Add property to object. More...
|
|
bool | addProperty (std::unique_ptr< AbstractProperty > &&property) |
| Add property to object. More...
|
|
template<typename Type , typename... Arguments> |
bool | addProperty (const std::string &name, Arguments &&...arguments) |
| Create and add property to object. More...
|
|
bool | removeProperty (AbstractProperty *property) |
| Remove property from object. More...
|
|
template<typename T > |
DynamicProperty< T > * | createDynamicProperty (const std::string &name, const T &value=T()) |
| Create dynamic property. More...
|
|
| AbstractProperty () |
| Constructor. More...
|
|
| AbstractProperty (const Variant &options) |
| Constructor. More...
|
|
virtual | ~AbstractProperty () |
| Destructor. More...
|
|
const std::string & | name () const |
| Get name. More...
|
|
void | setName (const std::string &name) |
| Set name. More...
|
|
std::string | qualifiedName (const Object *relativeRoot=nullptr) const |
| Get qualified name. More...
|
|
Object * | parent () const |
| Get parent object. More...
|
|
bool | hasParent () const |
| Finds out whether the Object has a parent. More...
|
|
const VariantMap & | options () const |
| Get options of property. More...
|
|
void | setOptions (const VariantMap &map) |
| Set options of property. More...
|
|
bool | hasOption (const std::string &key) const |
| Check if option is set. More...
|
|
const Variant & | option (const std::string &key) const |
| Get option of property. More...
|
|
template<typename Type > |
Type | option (const std::string &key, const Type &defaultValue=Type()) const |
| Get option of property convert to a specific type. More...
|
|
void | setOption (const std::string &key, const Variant &value) |
| Set option of property. More...
|
|
bool | removeOption (const std::string &key) |
| Remove option of property. More...
|
|
Example class for dynamic hierarchies.