ADTF
|
Accessing class for a instance of a struct. More...
Public Types | |
typedef const StructElementAccessIterator | const_iterator |
iterator type of this struct | |
Public Member Functions | |
StructTypeAccess ()=delete | |
default CTOR is deleted | |
StructTypeAccess (StructTypeAccess &&)=default | |
Move CTOR. | |
StructTypeAccess & | operator= (StructTypeAccess &&)=default |
Move assignment operator. More... | |
StructTypeAccess (const StructTypeAccess &)=default | |
copy assignment operator | |
StructTypeAccess & | operator= (const StructTypeAccess &)=default |
Copy CTOR. | |
StructTypeAccess (const std::shared_ptr< const datamodel::StructType > &struct_type) | |
Construct a new Struct Type Access object. More... | |
StructTypeAccess (std::nullptr_t) | |
Construct a empty Struct Type Access. | |
StructElementAccess | getElementByPath (const std::string name_path) const |
Get the StructElementAccess information class by path. More... | |
operator bool () const | |
The Struct access is a valid access type. More... | |
size_t | getStaticStructSize () const |
Get the known Static Struct Size of this instance. More... | |
size_t | getStaticUnalignedStructSize () const |
Get the known unaligned Static Struct Size of this instance (this is usually the last position + sizeof last element) More... | |
size_t | getStaticSerializedBitSize () const |
Get the known bitsize of this instance (this is usually the last position + sizeof last element) More... | |
bool | isDynamic () const |
retrieves information if it contains dynamic elements and so has dynamic size. More... | |
const datamodel::StructType & | getStructType () const |
Get the Struct Type it refers to (for data definition information) More... | |
const_iterator | cbegin () const |
constant iterator access More... | |
const_iterator | begin () const |
constant range based iterator access More... | |
const_iterator | cend () const |
constant end iterator More... | |
const_iterator | end () const |
constant range based end iterator More... | |
Private Member Functions | |
StructTypeAccess (const std::shared_ptr< const datamodel::StructType > &struct_type, OptionalSize serialized_struct_offset, OptionalSize deserialized_struct_offset) | |
Construct a new Struct Type Access object. More... | |
Private Attributes | |
std::shared_ptr< const datamodel::StructType > | _struct_type |
OptionalSize | _serialized_struct_as_element_offset |
OptionalSize | _deserialized_struct_as_element_offset |
const TypeInfo * | _type_info = nullptr |
Accessing class for a instance of a struct.
This will calculate the byte positions can be used for serialialization and deserialization.
Definition at line 336 of file dd_struct_access.h.
StructTypeAccess | ( | const std::shared_ptr< const datamodel::StructType > & | struct_type | ) |
Construct a new Struct Type Access object.
struct_type | the struct type it refers to. |
|
private |
Construct a new Struct Type Access object.
struct_type | the struct type it refers to. |
serialized_struct_offset | the offset of this instance within another struct |
deserialized_struct_offset | the offset of this instance within another struct |
const_iterator begin | ( | ) | const |
constant range based iterator access
const_iterator cbegin | ( | ) | const |
constant iterator access
const_iterator cend | ( | ) | const |
constant end iterator
const_iterator end | ( | ) | const |
constant range based end iterator
StructElementAccess getElementByPath | ( | const std::string | name_path | ) | const |
Get the StructElementAccess information class by path.
Separator is "." or "/"
Following element access paths are possible:
name_path | The path to the element. |
size_t getStaticSerializedBitSize | ( | ) | const |
Get the known bitsize of this instance (this is usually the last position + sizeof last element)
size_t getStaticStructSize | ( | ) | const |
Get the known Static Struct Size of this instance.
Referenced by structure< T >::GetSize().
size_t getStaticUnalignedStructSize | ( | ) | const |
Get the known unaligned Static Struct Size of this instance (this is usually the last position + sizeof last element)
const datamodel::StructType& getStructType | ( | ) | const |
Get the Struct Type it refers to (for data definition information)
bool isDynamic | ( | ) | const |
retrieves information if it contains dynamic elements and so has dynamic size.
true | has dynamic elements |
false | has no dynamic elements |
operator bool | ( | ) | const |
The Struct access is a valid access type.
|
default |
Move assignment operator.
|
private |
Definition at line 488 of file dd_struct_access.h.
|
private |
Definition at line 485 of file dd_struct_access.h.