8 std::map<armarx::eStateType, armarx::skills::arondto::Statechart::StateType>
11 (armarx::skills::arondto::Statechart::StateType)
12 armarx::skills::arondto::Statechart::StateType::NORMAL},
14 (armarx::skills::arondto::Statechart::StateType)
15 armarx::skills::arondto::Statechart::StateType::FINAL},
17 (armarx::skills::arondto::Statechart::StateType)
18 armarx::skills::arondto::Statechart::StateType::REMOTE},
20 (armarx::skills::arondto::Statechart::StateType)
21 armarx::skills::arondto::Statechart::StateType::DYNAMIC_REMOTE},
23 (armarx::skills::arondto::Statechart::StateType)
24 armarx::skills::arondto::Statechart::StateType::UNDEFINED},
27 std::map<armarx::skills::arondto::Statechart::StateType, armarx::eStateType>
29 {(armarx::skills::arondto::Statechart::StateType)
30 armarx::skills::arondto::Statechart::StateType::NORMAL,
32 {(armarx::skills::arondto::Statechart::StateType)
33 armarx::skills::arondto::Statechart::StateType::FINAL,
35 {(armarx::skills::arondto::Statechart::StateType)
36 armarx::skills::arondto::Statechart::StateType::REMOTE,
38 {(armarx::skills::arondto::Statechart::StateType)
39 armarx::skills::arondto::Statechart::StateType::DYNAMIC_REMOTE,
41 {(armarx::skills::arondto::Statechart::StateType)
42 armarx::skills::arondto::Statechart::StateType::UNDEFINED,
47 fromAron(
const skills::arondto::Statechart::StateType& dto, eStateType&
bo)
55 bo = eStateType::eUndefined;
60 toAron(skills::arondto::Statechart::StateType& dto,
const eStateType&
bo)
68 dto.value = skills::arondto::Statechart::StateType::UNDEFINED;
86 for (
auto const& [key, val] :
bo)
88 dto.parameters[key] = val->value->toString();
93 fromAron(
const skills::arondto::Statechart::Transition& dto,
94 ProfilerStatechartTransitionWithParameters&
bo)
96 bo.processId = dto.processId;
97 bo.sourceStateIdentifier = dto.sourceStateIdentifier;
98 bo.targetStateIdentifier = dto.targetStateIdentifier;
99 bo.eventName = dto.eventName;
100 fromAron(dto.targetStateType,
bo.targetStateType);
101 fromAron(dto.inputParameters,
bo.inputParameters);
102 fromAron(dto.localParameters,
bo.localParameters);
103 fromAron(dto.outputParameters,
bo.outputParameters);
107 toAron(skills::arondto::Statechart::Transition& dto,
108 const ProfilerStatechartTransitionWithParameters&
bo)
110 dto.processId =
bo.processId;
111 dto.sourceStateIdentifier =
bo.sourceStateIdentifier;
112 dto.targetStateIdentifier =
bo.targetStateIdentifier;
113 dto.eventName =
bo.eventName;
114 toAron(dto.targetStateType,
bo.targetStateType);
115 toAron(dto.inputParameters,
bo.inputParameters);
116 toAron(dto.localParameters,
bo.localParameters);
117 toAron(dto.outputParameters,
bo.outputParameters);
123 bo.providerName = dto.providerName;
129 dto.providerName =
bo.providerName;
135 bo.skillName = dto.skillName;
143 dto.skillName =
bo.skillName;
144 dto.providerId.resetHard();
145 if (
bo.providerId.has_value())
147 toAron(dto.providerId, *
bo.providerId);
155 bo.description = dto.description;
156 bo.timeout = dto.timeout;
157 bo.rootProfileDefaults = dto.rootProfileParameterization;
158 if (dto.parametersType)
160 throw armarx::LocalException(
"Not implemented yet");
168 dto.description =
bo.description;
169 dto.timeout =
bo.timeout;
170 dto.rootProfileParameterization =
bo.rootProfileDefaults;
171 if (
bo.parametersType)
181 fromAron(
const armarx::skills::arondto::SkillExecutionRequest& dto,
185 bo.executorName = dto.executorName;
186 bo.parameters = dto.parameters;
190 toAron(armarx::skills::arondto::SkillExecutionRequest& dto,
194 dto.executorName =
bo.executorName;
195 dto.parameters =
bo.parameters;
201 static std::map<std::string, skills::SkillStatus> map{
210 fromAron(dto.skillId,
bo.executionId.skillId);
211 bo.executionId.executionStartedTime = dto.executionStartedTimestamp;
212 bo.executionId.executorName = dto.executorName;
213 bo.parameters = dto.parameters;
214 bo.result = dto.result;
215 bo.status = map.at(dto.status);
221 static std::map<skills::SkillStatus, std::string> map{
230 toAron(dto.skillId,
bo.executionId.skillId);
231 dto.executorName =
bo.executionId.executorName;
232 dto.executionStartedTimestamp =
bo.executionId.executionStartedTime;
233 dto.parameters =
bo.parameters;
234 dto.result =
bo.result;
235 dto.status = map.at(
bo.status);