The StringTreeLeaf is, as the name suggests, a leaf (terminal node) of a StringTree. It provides the pointer to the node and a list of numbers that represent the index that corresponds to the placeholder "#". More...
#include <deserializer.hpp>
Public Member Functions | |
StringTreeLeaf () | |
SString | toSString () |
std::string | toStdString () |
bool | toStr (SString &destination) const |
Utility functions to print the entire branch. | |
bool | toStr (std::string &destination) const |
int | toStr (char *buffer) const |
Public Attributes | |
uint8_t | array_size |
std::array< uint16_t, 7 > | index_array |
StringTreeNode * | node_ptr |
The StringTreeLeaf is, as the name suggests, a leaf (terminal node) of a StringTree. It provides the pointer to the node and a list of numbers that represent the index that corresponds to the placeholder "#".
For example if you want to represent the string
foo/2/bar/3/hello/world
This would correspond to a branch of the tree (from root to the leaf) equal to these 6 nodes, where "foo" is the root and "world" is the leaf
foo -> # -> bar -> # ->hello -> world
array_size will be equal to two and index_array will contain these numbers {2,3}
Definition at line 65 of file deserializer.hpp.
Definition at line 231 of file deserializer.cpp.
SString RosIntrospection::StringTreeLeaf::toSString | ( | ) | [inline] |
Definition at line 82 of file deserializer.hpp.
std::string RosIntrospection::StringTreeLeaf::toStdString | ( | ) | [inline] |
Definition at line 84 of file deserializer.hpp.
bool RosIntrospection::StringTreeLeaf::toStr | ( | SString & | destination | ) | const |
Utility functions to print the entire branch.
Definition at line 237 of file deserializer.cpp.
bool RosIntrospection::StringTreeLeaf::toStr | ( | std::string & | destination | ) | const |
Definition at line 250 of file deserializer.cpp.
int RosIntrospection::StringTreeLeaf::toStr | ( | char * | buffer | ) | const |
Definition at line 263 of file deserializer.cpp.
Definition at line 71 of file deserializer.hpp.
std::array<uint16_t,7> RosIntrospection::StringTreeLeaf::index_array |
Definition at line 73 of file deserializer.hpp.
Definition at line 69 of file deserializer.hpp.