66 Base(desc), helper(properties, srv)
81 return ::armarx::skills::Skill::InitResult{
86 main(
const typename Base::SpecializedMainInput& in)
override
88 const Eigen::Isometry3f relativeTarget = this->relativeTarget(in);
99 auto future = std::async(std::launch::async,
100 [
this]() {
return helper.
getNavigator()->waitForStop(); });
112 auto se = future.get();
119 if (se.isSafetyStopTriggeredEvent())
123 return armarx::skills::Skill::MainResult{
126 if (se.isUserAbortTriggeredEvent())
130 return armarx::skills::Skill::MainResult{
133 if (se.isInternalErrorEvent())
136 << se.toInternalErrorEvent().message;
138 return armarx::skills::Skill::MainResult{
141 if (se.isGlobalPlanningFailedEvent())
144 << se.toGlobalPlanningFailedEvent().message;
146 return ::armarx::skills::Skill::MainResult{
151 return ::armarx::skills::Skill::MainResult{
155 return armarx::skills::Skill::MainResult{
160 onStopRequested()
override
162 if (helper.getNavigator().has_value())
165 helper.getNavigator()->stop();
171 NavigatingSkillHelper helper;
A result struct for th main method of a skill.