Object Class Reference

The Object class. More...

#include <RobotAPI/libraries/aron/core/type/variant/container/Object.h>

+ Inheritance diagram for Object:

Public Member Functions

void addMemberType (const std::string &, const VariantPtr &)
 
void addTemplate (const std::string &) const
 
void addTemplateInstantiation (const std::string &) const
 
bool checkObjectName (const std::string &) const
 
size_t childrenSize () const override
 
std::vector< std::string > getAllKeys () const
 
std::vector< VariantPtrgetChildren () const override
 get all child elements More...
 
std::map< std::string, VariantPtrgetDirectMemberTypes () const
 
std::shared_ptr< ObjectgetExtends () const
 
std::string getFullName () const override
 get the full name of this specific type More...
 
VariantPtr getMemberType (const std::string &) const
 
std::map< std::string, VariantPtrgetMemberTypes () const
 
std::string getObjectName () const
 
std::string getObjectNameWithoutNamespace () const
 
std::string getObjectNameWithTemplateInstantiations () const
 
std::string getObjectNameWithTemplates () const
 
std::string getShortName () const override
 get a short name of this specific type More...
 
std::vector< std::string > getTemplateInstantiations () const
 
std::vector< std::string > getTemplates () const
 
bool hasMemberType (const std::string &) const
 
VariantPtr navigateAbsolute (const Path &path) const override
 naviate absolute More...
 
 Object (const Path &=Path())
 
 Object (const type::dto::AronObject &, const Path &=Path())
 
void setExtends (const std::shared_ptr< Object > &)
 
void setMemberTypes (const std::map< std::string, VariantPtr > &)
 
void setObjectName (const std::string &)
 
void setTemplateInstantiations (const std::vector< std::string > &) const
 
void setTemplates (const std::vector< std::string > &)
 
type::dto::AronObjectPtr toAronObjectDTO () const
 
- Public Member Functions inherited from ContainerVariant< type::dto::AronObject, Object >
virtual ~ContainerVariant ()=default
 
- Public Member Functions inherited from SpecializedVariantBase< type::dto::AronObject, Object >
type::Maybe getMaybe () const override
 get the maybe type More...
 
VariantPtr navigateRelative (const Path &path) const override
 navigate relative More...
 
 operator type::dto::AronObject ()
 
bool operator== (const Object &other) const
 
bool operator== (const Variant &other) const override
 
void setMaybe (const type::Maybe m) override
 set the maybetype of this type More...
 
 SpecializedVariantBase (const type::Descriptor &descriptor, const Path &path)
 
 SpecializedVariantBase (const type::dto::AronObject &o, const type::Descriptor &descriptor, const Path &path)
 
type::dto::GenericTypePtr toAronDTO () const override
 convert this variant to a dto object. More...
 
virtual ~SpecializedVariantBase ()=default
 
- Public Member Functions inherited from Variant
type::Descriptor getDescriptor () const
 
virtual type::Maybe getMaybe () const =0
 get the maybe type More...
 
Path getPath () const
 
bool operator== (const VariantPtr &other) const
 
std::string pathToString () const
 
virtual type::dto::GenericTypePtr toAronDTO () const =0
 convert this variant to a dto object. More...
 
 Variant (const type::Descriptor &descriptor, const Path &path=Path())
 
virtual ~Variant ()=default
 

Static Public Member Functions

static ObjectPtr FromAronObjectDTO (const type::dto::AronObjectPtr &, const aron::Path &path=aron::Path())
 
static std::string GetFullNamePrefix ()
 
static std::string GetNamePrefix ()
 
static type::dto::AronObjectPtr ToAronObjectDTO (const ObjectPtr &)
 
- Static Public Member Functions inherited from SpecializedVariantBase< type::dto::AronObject, Object >
static const ObjectDynamicCast (const Variant &n)
 
static std::shared_ptr< ObjectDynamicCast (const VariantPtr &n)
 
static ObjectDynamicCast (Variant &n)
 
static std::shared_ptr< ObjectDynamicCastAndCheck (const VariantPtr &n)
 
- Static Public Member Functions inherited from Variant
static VariantPtr FromAronDTO (const type::dto::GenericType &, const Path &=Path())
 create a variant object from an dto object More...
 

Additional Inherited Members

- Public Types inherited from Variant
using PointerType = VariantPtr
 
- Protected Attributes inherited from SpecializedVariantBase< type::dto::AronObject, Object >
type::dto::AronObject ::PointerType aron
 
- Protected Attributes inherited from Variant
const type::Descriptor descriptor
 
const Path path
 

Detailed Description

The Object class.

It represents the object type An object may have different types for each member, here represented as a map, mapping from the member name (as string) to the type (as a variant)

Definition at line 42 of file Object.h.

Constructor & Destructor Documentation

◆ Object() [1/2]

Object ( const Path path = Path())

Definition at line 34 of file Object.cpp.

◆ Object() [2/2]

Object ( const type::dto::AronObject &  o,
const Path path = Path() 
)

Definition at line 39 of file Object.cpp.

+ Here is the call graph for this function:

Member Function Documentation

◆ addMemberType()

void addMemberType ( const std::string &  k,
const VariantPtr v 
)

Definition at line 147 of file Object.cpp.

+ Here is the call graph for this function:

◆ addTemplate()

void addTemplate ( const std::string &  s) const

Definition at line 213 of file Object.cpp.

+ Here is the call graph for this function:

◆ addTemplateInstantiation()

void addTemplateInstantiation ( const std::string &  s) const

Definition at line 224 of file Object.cpp.

+ Here is the call graph for this function:

◆ checkObjectName()

bool checkObjectName ( const std::string &  s) const

Definition at line 74 of file Object.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ childrenSize()

size_t childrenSize ( ) const
overridevirtual

Implements Variant.

Definition at line 304 of file Object.cpp.

◆ FromAronObjectDTO()

ObjectPtr FromAronObjectDTO ( const type::dto::AronObjectPtr &  aron,
const aron::Path path = aron::Path() 
)
static

Definition at line 54 of file Object.cpp.

+ Here is the caller graph for this function:

◆ getAllKeys()

std::vector< std::string > getAllKeys ( ) const

Definition at line 261 of file Object.cpp.

+ Here is the call graph for this function:

◆ getChildren()

std::vector< VariantPtr > getChildren ( ) const
overridevirtual

get all child elements

Implements Variant.

Definition at line 286 of file Object.cpp.

◆ getDirectMemberTypes()

std::map< std::string, VariantPtr > getDirectMemberTypes ( ) const

Definition at line 122 of file Object.cpp.

+ Here is the caller graph for this function:

◆ getExtends()

std::shared_ptr< Object > getExtends ( ) const

Definition at line 255 of file Object.cpp.

+ Here is the caller graph for this function:

◆ getFullName()

std::string getFullName ( ) const
overridevirtual

get the full name of this specific type

Implements Variant.

Definition at line 317 of file Object.cpp.

◆ GetFullNamePrefix()

std::string GetFullNamePrefix ( )
static

Definition at line 324 of file Object.cpp.

◆ getMemberType()

VariantPtr getMemberType ( const std::string &  s) const

Definition at line 128 of file Object.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getMemberTypes()

std::map< std::string, VariantPtr > getMemberTypes ( ) const

Definition at line 108 of file Object.cpp.

+ Here is the caller graph for this function:

◆ GetNamePrefix()

std::string GetNamePrefix ( )
static

Definition at line 330 of file Object.cpp.

◆ getObjectName()

std::string getObjectName ( ) const

Definition at line 249 of file Object.cpp.

+ Here is the caller graph for this function:

◆ getObjectNameWithoutNamespace()

std::string getObjectNameWithoutNamespace ( ) const

Definition at line 186 of file Object.cpp.

+ Here is the call graph for this function:

◆ getObjectNameWithTemplateInstantiations()

std::string getObjectNameWithTemplateInstantiations ( ) const

Definition at line 193 of file Object.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getObjectNameWithTemplates()

std::string getObjectNameWithTemplates ( ) const

Definition at line 203 of file Object.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getShortName()

std::string getShortName ( ) const
overridevirtual

get a short name of this specific type

Implements Variant.

Definition at line 310 of file Object.cpp.

◆ getTemplateInstantiations()

std::vector< std::string > getTemplateInstantiations ( ) const

Definition at line 243 of file Object.cpp.

+ Here is the caller graph for this function:

◆ getTemplates()

std::vector< std::string > getTemplates ( ) const

Definition at line 237 of file Object.cpp.

+ Here is the caller graph for this function:

◆ hasMemberType()

bool hasMemberType ( const std::string &  k) const

Definition at line 180 of file Object.cpp.

+ Here is the caller graph for this function:

◆ navigateAbsolute()

VariantPtr navigateAbsolute ( const Path path) const
overridevirtual

naviate absolute

Implements Variant.

Definition at line 336 of file Object.cpp.

+ Here is the call graph for this function:

◆ setExtends()

void setExtends ( const std::shared_ptr< Object > &  p)

Definition at line 170 of file Object.cpp.

◆ setMemberTypes()

void setMemberTypes ( const std::map< std::string, VariantPtr > &  memberTypes)

Definition at line 86 of file Object.cpp.

+ Here is the call graph for this function:

◆ setObjectName()

void setObjectName ( const std::string &  n)

Definition at line 162 of file Object.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setTemplateInstantiations()

void setTemplateInstantiations ( const std::vector< std::string > &  templateInstantiations) const

Definition at line 102 of file Object.cpp.

◆ setTemplates()

void setTemplates ( const std::vector< std::string > &  templates)

Definition at line 96 of file Object.cpp.

◆ toAronObjectDTO()

type::dto::AronObjectPtr toAronObjectDTO ( ) const

Definition at line 279 of file Object.cpp.

◆ ToAronObjectDTO()

type::dto::AronObjectPtr ToAronObjectDTO ( const ObjectPtr aron)
static

Definition at line 64 of file Object.cpp.

+ Here is the caller graph for this function:

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