Advertise the action. This turns the Action object from a client into a server. The callback will be called with every goal sent to this action.
This works similarly to the callback for a C++ action.
A callback function to execute when the action is canceled.
Cancels an action goal.
The ID of the action goal to cancel.
Helper function to send action feedback inside an action handler.
The action goal ID.
The feedback to send.
Sends an action goal. Returns the feedback in the feedback callback while the action is running and the result in the result callback when the action is completed. Does nothing if this action is currently advertised.
The action goal to send.
The callback function when the action is completed.
OptionalfeedbackCallback: (feedback: TFeedback) => voidThe callback function when the action pulishes feedback.
OptionalfailedCallback: (error: string) => void = console.errorThe callback function when the action failed.
Helper function to set an action as canceled.
The action goal ID.
The result to set.
Helper function to set an action as failed.
The action goal ID.
Helper function to set an action as succeeded.
The action goal ID.
The result to set.
Unadvertise a previously advertised action.
A ROS 2 action client.