Go to the documentation of this file.
38 #include <actionlib/TestAction.h>
69 printf(
"Creating ActionServer [%s]\n", name.c_str());
79 gh.
setSucceeded(TestResult(),
"The ref server has succeeded");
83 gh.
setAborted(TestResult(),
"The ref server has aborted");
86 gh.
setRejected(TestResult(),
"The ref server has rejected");
98 int main(
int argc,
char ** argv)
boost::shared_ptr< const Goal > getGoal() const
Accessor for the goal associated with the ServerGoalHandle.
Encapsulates a state machine for a given goal that the user can trigger transitions on....
ROSCPP_DECL void init(const M_string &remappings, const std::string &name, uint32_t options=0)
The ActionServer is a helpful tool for managing goal requests to a node. It allows the user to specif...
void setRejected(const Result &result=Result(), const std::string &text=std::string(""))
Set the status of the goal associated with the ServerGoalHandle to rejected.
int main(int argc, char **argv)
void goalCallback(GoalHandle gh)
ServerGoalHandle< TestAction > GoalHandle
void setAccepted(const std::string &text=std::string(""))
Accept the goal referenced by the goal handle. This will transition to the ACTIVE state or the PREEMP...
void setSucceeded(const Result &result=Result(), const std::string &text=std::string(""))
Set the status of the goal associated with the ServerGoalHandle to succeeded.
void cancelCallback(GoalHandle gh)
void start()
Explicitly start the action server, used it auto_start is set to false.
void setAborted(const Result &result=Result(), const std::string &text=std::string(""))
Set the status of the goal associated with the ServerGoalHandle to aborted.
RefServer(ros::NodeHandle &n, const std::string &name)
actionlib
Author(s): Eitan Marder-Eppstein, Vijay Pradeep, Mikael Arguedas
autogenerated on Fri May 19 2023 02:36:55