Common
common packages for kyubic
 
Loading...
Searching...
No Matches
fibonacci_action.hpp
Go to the documentation of this file.
1
10#ifndef _FIBONACCI_ACTION_HPP
11#define _FIBONACCI_ACTION_HPP
12
13#include <action_tutorials_interfaces/action/fibonacci.hpp>
15
16namespace behavior_tree
17{
18
22class FibonacciAction : public RosActionNode<action_tutorials_interfaces::action::Fibonacci>
23{
24public:
32 const std::string & name, const BT::NodeConfig & config, rclcpp::Node::SharedPtr ros_node);
33
38 static BT::PortsList providedPorts();
39
44 bool setGoal(typename Action::Goal & goal) override;
45
50 BT::NodeStatus onResult(const WrappedResult & wr) override;
51
56 void onFeedback(const std::shared_ptr<const Feedback> feedback) override;
57};
58
59} // namespace behavior_tree
60
61#endif // _FIBONACCI_ACTION_HPP
Fibonacci Action Client implementation using the RosActionNode template.
Definition: fibonacci_action.hpp:23
BT::NodeStatus onResult(const WrappedResult &wr) override
Implementation of onResult. Checks the result code and sets the output port if successful.
Definition: fibonacci_action.cpp:41
void onFeedback(const std::shared_ptr< const Feedback > feedback) override
(Optional) Implementation of onFeedback. Logs the partial sequence length.
Definition: fibonacci_action.cpp:56
bool setGoal(typename Action::Goal &goal) override
Implementation of setGoal. Gets the "order" from the input port and populates the goal message.
Definition: fibonacci_action.cpp:29
static BT::PortsList providedPorts()
Define ports required by this specific action.
Definition: fibonacci_action.cpp:21
Template for ROS2 Action with Behavior Tree.
Definition: ros_action_node.hpp:28
typename rclcpp_action::ClientGoalHandle< Action >::WrappedResult WrappedResult
Definition: ros_action_node.hpp:33
Abstract class for ROS2 Action client with Behavior Tree.