Main Page
Modules
Namespaces
Classes
Files
File List
File Members
src
decorators
subtree_node.cpp
Go to the documentation of this file.
1
#include "
behaviortree_cpp/decorators/subtree_node.h
"
2
3
4
BT::DecoratorSubtreeNode::DecoratorSubtreeNode
(
const
std::string &name) :
5
DecoratorNode
(name, {} )
6
{
7
setRegistrationID
(
"SubTree"
);
8
}
9
10
BT::NodeStatus
BT::DecoratorSubtreeNode::tick
()
11
{
12
NodeStatus
prev_status =
status
();
13
if
(prev_status ==
NodeStatus::IDLE
)
14
{
15
setStatus
(
NodeStatus::RUNNING
);
16
}
17
return
child_node_
->
executeTick
();
18
}
19
subtree_node.h
BT::NodeStatus::IDLE
BT::DecoratorNode::child_node_
TreeNode * child_node_
Definition:
decorator_node.h:11
BT::DecoratorNode
Definition:
decorator_node.h:8
BT::NodeStatus::RUNNING
BT::TreeNode::setRegistrationID
void setRegistrationID(StringView ID)
Definition:
tree_node.h:158
BT::TreeNode::status
NodeStatus status() const
Definition:
tree_node.cpp:56
BT::NodeStatus
NodeStatus
Definition:
basic_types.h:35
BT::TreeNode::executeTick
virtual BT::NodeStatus executeTick()
The method that should be used to invoke tick() and setStatus();.
Definition:
tree_node.cpp:33
BT::DecoratorSubtreeNode::tick
virtual BT::NodeStatus tick() override
Method to be implemented by the user.
Definition:
subtree_node.cpp:10
BT::DecoratorSubtreeNode::DecoratorSubtreeNode
DecoratorSubtreeNode(const std::string &name)
Definition:
subtree_node.cpp:4
BT::TreeNode::setStatus
void setStatus(NodeStatus new_status)
Definition:
tree_node.cpp:40
behaviortree_cpp
Author(s): Michele Colledanchise, Davide Faconti
autogenerated on Sat Jun 8 2019 18:04:05