#include <rtti/path.h>
Public Types | |
enum | Type { INVALID, ATTRIBUTE, ARRAY_ELEMENT } |
Public Member Functions | |
bool | operator== (const PathElement &lhs) const |
bool | operator!= (const PathElement &lhs) const |
Public Attributes | |
Type | mType = Type::INVALID |
union { | |
struct { | |
const char * Name | |
} Attribute | |
struct { | |
int Index | |
} ArrayElement | |
}; | |
Represents an element on a Path. Each element is of a specific type and has different data, depending on the type of the element. In order to be able to have an array (without dynamic allocs) of these elements, it makes use of an anonymous union to store the data. Then, depending on the type of the element, you can access the data through Element.Attribute or Element.ArrayElement.
Note: this class should be used through Path, not directly
|
strong |
bool operator!= | ( | const PathElement & | lhs | ) | const |
Inequality operator
bool operator== | ( | const PathElement & | lhs | ) | const |
Equality operator
union { ... } |
struct { ... } ArrayElement |
struct { ... } Attribute |
int Index |
Type mType = Type::INVALID |
const char* Name |