rclcpp_action
master
C++ ROS Action Client Library
|
Go to the documentation of this file.
15 #ifndef RCLCPP_ACTION__CLIENT_GOAL_HANDLE_HPP_
16 #define RCLCPP_ACTION__CLIENT_GOAL_HANDLE_HPP_
18 #include <rcl_action/action_client.h>
20 #include <action_msgs/msg/goal_status.hpp>
37 UNKNOWN = action_msgs::msg::GoalStatus::STATUS_UNKNOWN,
38 SUCCEEDED = action_msgs::msg::GoalStatus::STATUS_SUCCEEDED,
39 CANCELED = action_msgs::msg::GoalStatus::STATUS_CANCELED,
40 ABORTED = action_msgs::msg::GoalStatus::STATUS_ABORTED
45 template<
typename ActionT>
57 template<
typename ActionT>
71 typename ActionT::Result::SharedPtr
result;
75 using Result =
typename ActionT::Result;
104 [[deprecated(
"use rclcpp_action::Client::async_get_result() instead")]]
136 call_feedback_callback(
155 set_result_awareness(
bool awareness);
158 set_status(int8_t status);
168 bool is_result_aware_{
false};
174 int8_t status_{GoalStatus::STATUS_ACCEPTED};
181 #endif // RCLCPP_ACTION__CLIENT_GOAL_HANDLE_HPP_
struct rclcpp_action::ClientGoalHandle::WrappedResult WrappedResult
const GoalUUID & get_goal_id() const
Get the unique ID for the goal.
Definition: client_goal_handle_impl.hpp:46
Class for interacting with goals sent from action clients.
Definition: client_goal_handle.hpp:58
ActionT::Result::SharedPtr result
User defined fields sent back with an action.
Definition: client_goal_handle.hpp:71
Definition: client.hpp:44
GoalUUID goal_id
The unique identifier of the goal.
Definition: client_goal_handle.hpp:67
bool is_feedback_aware()
Check if an action client has subscribed to feedback for the goal.
Definition: client_goal_handle_impl.hpp:122
std::shared_future< WrappedResult > async_result()
Get a future to the goal result.
Definition: client_goal_handle_impl.hpp:60
Definition: client_goal_handle.hpp:64
typename ActionT::Feedback Feedback
Definition: client_goal_handle.hpp:74
ResultCode code
A status to indicate if the goal was canceled, aborted, or suceeded.
Definition: client_goal_handle.hpp:69
action_msgs::msg::GoalInfo GoalInfo
Definition: types.hpp:34
virtual ~ClientGoalHandle()
Definition: client_goal_handle_impl.hpp:40
int8_t get_status()
Get the goal status code.
Definition: client_goal_handle_impl.hpp:106
bool is_result_aware()
Check if an action client has requested the result for the goal.
Definition: client_goal_handle_impl.hpp:130
std::function< void(const WrappedResult &result)> ResultCallback
Definition: client_goal_handle.hpp:80
#define RCLCPP_SMART_PTR_DEFINITIONS_NOT_COPYABLE(...)
std::function< void(typename ClientGoalHandle< ActionT >::SharedPtr, const std::shared_ptr< const Feedback >)> FeedbackCallback
Definition: client_goal_handle.hpp:79
ResultCode
The possible statuses that an action goal can finish with.
Definition: client_goal_handle.hpp:35
Action Client.
Definition: client.hpp:255
typename ActionT::Result Result
Definition: client_goal_handle.hpp:75
rclcpp::Time get_goal_stamp() const
Get the time when the goal was accepted.
Definition: client_goal_handle_impl.hpp:53