List Class Reference

#include <RobotAPI/libraries/aron/core/data/variant/container/List.h>

+ Inheritance diagram for List:

Public Member Functions

void addElement (const VariantPtr &)
 
size_t childrenSize () const override
 get the children size of a data variant More...
 
void clear ()
 
ListPtr clone (const Path &p) const override
 
bool fullfillsType (const type::VariantPtr &) const override
 checks, if the current data variant fullfills the given type More...
 
DictPtr getAsDict () const
 
std::vector< VariantPtrgetChildren () const override
 get the children of a data variant More...
 
VariantPtr getElement (unsigned int) const
 
std::vector< VariantPtrgetElements () const
 
std::string getFullName () const override
 get the full str representation of this variant More...
 
std::string getShortName () const override
 get a short str representation of this variant More...
 
bool hasElement (unsigned int) const
 
 List (const data::dto::ListPtr &, const Path &path=Path())
 
 List (const Path &path=Path())
 
 List (const std::vector< VariantPtr > &, const Path &path=Path())
 
VariantPtr navigateAbsolute (const Path &path) const override
 naviate absolute More...
 
bool operator== (const List &) const override
 
bool operator== (const ListPtr &) const override
 
type::VariantPtr recalculateType () const override
 recalculate the type of a data variant. Please not tha the mapping ist NOT bijective, so the calculated type may be wrong More...
 
void removeElement (unsigned int)
 
void setElement (unsigned int, const VariantPtr &)
 
data::dto::ListPtr toAronListDTO () const
 
- Public Member Functions inherited from ContainerVariant< data::dto::List, List >
 SpecializedVariantBase ()=delete
 
 SpecializedVariantBase (const data::Descriptor descriptor, const Path &path=Path())
 
 SpecializedVariantBase (const typename AronDataType::PointerType &o, const data::Descriptor descriptor, const Path &path=Path())
 
virtual ~ContainerVariant ()=default
 
- Public Member Functions inherited from SpecializedVariantBase< data::dto::List, List >
virtual PointerType clone () const
 
VariantPtr cloneAsVariant () const override
 get a pointer to a copy of this variant More...
 
VariantPtr cloneAsVariant (const Path &newPath) const override
 
VariantPtr navigateRelative (const Path &path) const override
 navigate relative More...
 
 operator typename AronDataType::PointerType ()
 
virtual bool operator== (const PointerType &other) const=0
 
bool operator== (const Variant &other) const override
 
 SpecializedVariantBase ()=delete
 
 SpecializedVariantBase (const data::Descriptor descriptor, const Path &path=Path())
 
 SpecializedVariantBase (const typename AronDataType::PointerType &o, const data::Descriptor descriptor, const Path &path=Path())
 
data::dto::GenericDataPtr toAronDTO () const override
 convert the variant to the ice representation More...
 
virtual ~SpecializedVariantBase ()=default
 
- Public Member Functions inherited from Variant
virtual VariantPtr cloneAsVariant () const =0
 get a pointer to a copy of this variant More...
 
data::Descriptor getDescriptor () const
 getter for the descriptor enum More...
 
Path getPath () const
 get the path More...
 
bool operator== (const VariantPtr &other) const
 
std::string pathToString () const
 get the path as string More...
 
virtual data::dto::GenericDataPtr toAronDTO () const =0
 convert the variant to the ice representation More...
 
 Variant ()=delete
 
 Variant (const data::Descriptor &descriptor, const Path &path)
 
virtual ~Variant ()=default
 

Static Public Member Functions

static PointerType FromAronListDTO (const data::dto::ListPtr &aron)
 
static data::dto::ListPtr ToAronListDTO (const PointerType &navigator)
 
- Static Public Member Functions inherited from SpecializedVariantBase< data::dto::List, List >
static const ListDynamicCast (const Variant &n)
 
static PointerType DynamicCast (const VariantPtr &n)
 
static ListDynamicCast (Variant &n)
 
static PointerType DynamicCastAndCheck (const VariantPtr &n)
 
- Static Public Member Functions inherited from Variant
static VariantPtr FromAronDTO (const data::dto::GenericDataPtr &, const Path &=Path())
 create a variant from a dto object More...
 
static std::vector< VariantPtrFromAronDTO (const std::vector< data::dto::GenericDataPtr > &, const Path &=Path())
 create a list of variants from a list of dto objects More...
 
static std::vector< data::dto::GenericDataPtr > ToAronDTO (const std::vector< VariantPtr > &)
 return a list of dto objects from a list of variant objects More...
 

Additional Inherited Members

- Public Types inherited from ContainerVariant< data::dto::List, List >
using Base = SpecializedVariantBase< data::dto::List, List >
 
- Public Types inherited from SpecializedVariantBase< data::dto::List, List >
using AronDataType = data::dto::List
 
using Base = data::Variant
 
using PointerType = std::shared_ptr< List >
 
- Public Types inherited from Variant
using PointerType = VariantPtr
 
- Protected Attributes inherited from SpecializedVariantBase< data::dto::List, List >
AronDataType::PointerType aron
 
- Protected Attributes inherited from Variant
const data::Descriptor descriptor
 
const Path path
 

Detailed Description

Definition at line 43 of file List.h.

Constructor & Destructor Documentation

◆ List() [1/3]

List ( const Path path = Path())

Definition at line 39 of file List.cpp.

+ Here is the caller graph for this function:

◆ List() [2/3]

List ( const data::dto::ListPtr &  l,
const Path path = Path() 
)

Definition at line 45 of file List.cpp.

+ Here is the call graph for this function:

◆ List() [3/3]

List ( const std::vector< VariantPtr > &  n,
const Path path = Path() 
)

Definition at line 57 of file List.cpp.

+ Here is the call graph for this function:

Member Function Documentation

◆ addElement()

void addElement ( const VariantPtr n)

Definition at line 141 of file List.cpp.

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

◆ childrenSize()

size_t childrenSize ( ) const
overridevirtual

get the children size of a data variant

Implements Variant.

Definition at line 353 of file List.cpp.

+ Here is the caller graph for this function:

◆ clear()

void clear ( )

Definition at line 221 of file List.cpp.

◆ clone()

ListPtr clone ( const Path p) const
overridevirtual

Implements SpecializedVariantBase< data::dto::List, List >.

Definition at line 103 of file List.cpp.

+ Here is the call graph for this function:

◆ FromAronListDTO()

ListPtr FromAronListDTO ( const data::dto::ListPtr &  aron)
static

Definition at line 115 of file List.cpp.

◆ fullfillsType()

bool fullfillsType ( const type::VariantPtr ) const
overridevirtual

checks, if the current data variant fullfills the given type

Implements Variant.

Definition at line 255 of file List.cpp.

+ Here is the call graph for this function:

◆ getAsDict()

DictPtr getAsDict ( ) const

Definition at line 132 of file List.cpp.

+ Here is the call graph for this function:

◆ getChildren()

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

get the children of a data variant

Implements Variant.

Definition at line 347 of file List.cpp.

◆ getElement()

VariantPtr getElement ( unsigned int  i) const

Definition at line 191 of file List.cpp.

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

◆ getElements()

std::vector< VariantPtr > getElements ( ) const

Definition at line 206 of file List.cpp.

+ Here is the caller graph for this function:

◆ getFullName()

std::string getFullName ( ) const
overridevirtual

get the full str representation of this variant

Implements Variant.

Definition at line 241 of file List.cpp.

◆ getShortName()

std::string getShortName ( ) const
overridevirtual

get a short str representation of this variant

Implements Variant.

Definition at line 235 of file List.cpp.

◆ hasElement()

bool hasElement ( unsigned int  i) const

Definition at line 185 of file List.cpp.

+ Here is the caller graph for this function:

◆ navigateAbsolute()

VariantPtr navigateAbsolute ( const Path path) const
overridevirtual

naviate absolute

Implements Variant.

Definition at line 359 of file List.cpp.

+ Here is the call graph for this function:

◆ operator==() [1/2]

bool operator== ( const List other) const
overridevirtual

Implements SpecializedVariantBase< data::dto::List, List >.

Definition at line 67 of file List.cpp.

+ Here is the call graph for this function:

◆ operator==() [2/2]

bool operator== ( const ListPtr other) const
override

Definition at line 93 of file List.cpp.

◆ recalculateType()

type::VariantPtr recalculateType ( ) const
overridevirtual

recalculate the type of a data variant. Please not tha the mapping ist NOT bijective, so the calculated type may be wrong

Implements Variant.

Definition at line 248 of file List.cpp.

◆ removeElement()

void removeElement ( unsigned int  i)

Definition at line 212 of file List.cpp.

+ Here is the call graph for this function:

◆ setElement()

void setElement ( unsigned int  i,
const VariantPtr n 
)

Definition at line 147 of file List.cpp.

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

◆ toAronListDTO()

data::dto::ListPtr toAronListDTO ( ) const

Definition at line 228 of file List.cpp.

◆ ToAronListDTO()

data::dto::ListPtr ToAronListDTO ( const PointerType navigator)
static

Definition at line 125 of file List.cpp.


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