36 return "MultiHandUnit";
47 _handInfos.reserve(units.size());
48 for (
const auto& name : units)
50 _handInfos.emplace_back();
51 _handInfos.back().proxyName = name;
59 for (
auto& info : _handInfos)
61 getProxy(info.proxy, info.proxyName);
62 info.handName = info.proxy->getHandName();
63 _hands[info.handName] = info.proxy;
93 const NameValueMap& jointValues,
96 _hands.at(handName)->setJointAngles(jointValues);
102 return _hands.at(handName)->getCurrentJointValues();
ComponentPropertyDefinitions(std::string prefix, bool hasObjectNameParameter=true)
std::string getConfigIdentifier()
Retrieve config identifier for this component as set in constructor.
bool usingProxy(const std::string &name, const std::string &endpoints="")
Registers a proxy for retrieval after initialization and adds it to the dependency list.
Ice::ObjectPrx getProxy(long timeoutMs=0, bool waitForScheduler=true) const
Returns the proxy of this object (optionally it waits for the proxy)
MultiHandUnitPropertyDefinitions(std::string prefix)
void setJointValues(const std::string &handName, const NameValueMap &jointValues, const Ice::Current &=Ice::emptyCurrent) override
virtual void onInitComponent() override
virtual void onDisconnectComponent() override
virtual armarx::PropertyDefinitionsPtr createPropertyDefinitions() override
HandInfoSeq getHandInfos(const Ice::Current &=Ice::emptyCurrent) override
virtual void onConnectComponent() override
NameValueMap getJointValues(const std::string &handName, const Ice::Current &=Ice::emptyCurrent) override
virtual void onExitComponent() override
virtual std::string getDefaultName() const override
std::string prefix
Prefix of the properties such as namespace, domain, component name, etc.
PropertyDefinition< PropertyType > & defineOptionalProperty(const std::string &name, PropertyType defaultValue, const std::string &description="", PropertyDefinitionBase::PropertyConstness constness=PropertyDefinitionBase::eConstant)
void getPropertyAsCSV(ContainerT &val, const std::string &name, const std::string &splitBy=",;", bool trimElements=true, bool removeEmptyElements=true)
#define ARMARX_ERROR
The logging level for unexpected behaviour, that must be fixed.
This file offers overloads of toIce() and fromIce() functions for STL container types.
IceUtil::Handle< class PropertyDefinitionContainer > PropertyDefinitionsPtr
PropertyDefinitions smart pointer type.