AutoAPMS
Resilient Robot Mission Management
|
Struct that encapsulates the identity string for a declared behavior tree. More...
#include <auto_apms_behavior_tree_core/tree/tree_resource.hpp>
Public Member Functions | |
TreeResourceIdentity (const std::string &identity) | |
Constructor of a behavior tree resource identity object. | |
TreeResourceIdentity (const char *identity) | |
Constructor of a tree resource identity object. | |
TreeResourceIdentity ()=default | |
Constructor of an empty tree resource identity object. | |
std::string | str () const |
Create the corresponding identity string. | |
bool | empty () const |
Determine whether this tree resource identity object is considered empty. | |
Public Attributes | |
std::string | package_name |
Name of the package that registers the resource. | |
std::string | file_stem |
Name of the file (without extension) that contains the resource's tree document. | |
std::string | tree_name |
Name of a specific tree inside the resource's tree document. | |
Struct that encapsulates the identity string for a declared behavior tree.
Its only purpose is to create the corresponding instance of TreeResource.
Definition at line 32 of file tree_resource.hpp.
TreeResourceIdentity | ( | const std::string & | identity | ) |
Constructor of a behavior tree resource identity object.
identity
must be formatted like <package_name>::<tree_file_stem>::<tree_name>
.
identity | Identity string for a specific behavior tree resource. |
auto_apms_util::exceptions::ResourceIdentityFormatError | if the identity string has wrong format. |
Definition at line 31 of file tree_resource.cpp.
TreeResourceIdentity | ( | const char * | identity | ) |
Constructor of a tree resource identity object.
identity
must be formatted like <package_name>::<tree_file_stem>::<tree_name>
.
identity | C-style identity string for a specific behavior tree resource. |
auto_apms_util::exceptions::ResourceIdentityFormatError | if the identity string has wrong format. |
Definition at line 52 of file tree_resource.cpp.
|
default |
Constructor of an empty tree resource identity object.
The user must manually populate the member fields according to the resource this object should identify.
std::string str | ( | ) | const |
Create the corresponding identity string.
Definition at line 58 of file tree_resource.cpp.
bool empty | ( | ) | const |
Determine whether this tree resource identity object is considered empty.
true
if none of the member fields are set, false
otherwise. Definition at line 60 of file tree_resource.cpp.
std::string package_name |
Name of the package that registers the resource.
Definition at line 76 of file tree_resource.hpp.
std::string file_stem |
Name of the file (without extension) that contains the resource's tree document.
Definition at line 78 of file tree_resource.hpp.
std::string tree_name |
Name of a specific tree inside the resource's tree document.
Definition at line 80 of file tree_resource.hpp.