Skip to content
Snippets Groups Projects
Commit 46cf08d4 authored by Raphael Grimm's avatar Raphael Grimm
Browse files

Add RobotUnitModule::ControllerManagement::getNJointControllerNames

parent 2c2afd20
No related branches found
No related tags found
No related merge requests found
......@@ -269,6 +269,19 @@ namespace armarx
auto guard = getGuard();
return getMapKeys(nJointControllers);
}
std::vector<std::string> ControllerManagement::getNJointControllerNames(const std::vector<NJointControllerPtr> &ctrls) const
{
std::vector<std::string> result;
result.reserve(ctrls.size());
for(const auto& ctrl : ctrls)
{
if(ctrl)
{
result.emplace_back(ctrl->getInstanceName());
}
}
return result;
}
void ControllerManagement::activateNJointControllers(const Ice::StringSeq& names, const Ice::Current&)
......
......@@ -293,6 +293,14 @@ namespace armarx
* @throw If there is no \ref NJointcontroller for \param name
*/
const NJointControllerPtr& getNJointControllerNotNull(const std::string& name) const;
/**
* @brief Returns the names of given \ref NJointController "NJointControllers"
* @param ctrls The \ref NJointController "NJointControllers"
* @return The names of given \ref NJointController "NJointControllers"
*/
std::vector<std::string> getNJointControllerNames(const std::vector<armarx::NJointControllerPtr>& ctrls) const;
// //////////////////////////////////////////////////////////////////////////////////////// //
// //////////////////////////////////// implementation //////////////////////////////////// //
// //////////////////////////////////////////////////////////////////////////////////////// //
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment