Template Class ClientGoalHandle

Nested Relationships

Nested Types

Class Documentation

template<typename ActionT>
class ClientGoalHandle

Class for interacting with goals sent from action clients.

Use this class to check the status of a goal as well as get the result.

This class is not meant to be created by a user, instead it is created when a goal has been accepted. A Client will create an instance and return it to the user (via a future) after calling Client::async_send_goal.

Public Types

using Feedback = typename ActionT::Feedback
using Result = typename ActionT::Result
using FeedbackCallback = std::function<void(typename ClientGoalHandle<ActionT>::SharedPtr, const std::shared_ptr<const Feedback>)>
using ResultCallback = std::function<void(const WrappedResult &result)>

Public Functions

virtual ~ClientGoalHandle()
const GoalUUID &get_goal_id() const

Get the unique ID for the goal.

rclcpp::Time get_goal_stamp() const

Get the time when the goal was accepted.

int8_t get_status()

Get the goal status code.

bool is_feedback_aware()

Check if an action client has subscribed to feedback for the goal.

bool is_result_aware()

Check if an action client has requested the result for the goal.

struct WrappedResult

Public Members

GoalUUID goal_id

The unique identifier of the goal.

ResultCode code

A status to indicate if the goal was canceled, aborted, or suceeded.

ActionT::Result::SharedPtr result

User defined fields sent back with an action.