Skip to content
Snippets Groups Projects
Commit 9714d5f0 authored by Mirko Wächter's avatar Mirko Wächter
Browse files

Revert "Revert "adjustment to simox fixes""

This reverts commit 0e331d7e.
parent 0e331d7e
No related branches found
No related tags found
No related merge requests found
......@@ -30,6 +30,9 @@
#include <VirtualRobot/Nodes/RobotNodeFixedFactory.h>
#include <VirtualRobot/Nodes/RobotNodePrismaticFactory.h>
#include <VirtualRobot/Nodes/RobotNodeRevoluteFactory.h>
#include <VirtualRobot/CollisionDetection/CollisionChecker.h>
#include <Eigen/Geometry>
#include <ArmarXCore/core/system/cmake/CMakePackageFinder.h>
......@@ -72,13 +75,13 @@ namespace armarx
}
RobotNodePtr RemoteRobot::getRootNode()
RobotNodePtr RemoteRobot::getRootNode() const
{
// lazy initialization needed since shared_from_this() must not be called in constructor
if (!_root)
{
_root = RemoteRobot::createRemoteRobotNode(_robot->getRootNode(), shared_from_this());
}
return _root;
}
......@@ -156,7 +159,7 @@ namespace armarx
return _robot->hasRobotNodeSet(name);
}
RobotNodeSetPtr RemoteRobot::getRobotNodeSet(const string& nodeSetName)
RobotNodeSetPtr RemoteRobot::getRobotNodeSet(const string& nodeSetName) const
{
vector<RobotNodePtr> storeNodes;
RobotNodeSetInfoPtr info = _robot->getRobotNodeSet(nodeSetName);
......@@ -165,7 +168,7 @@ namespace armarx
}
void RemoteRobot::getRobotNodeSets(vector<RobotNodeSetPtr>& storeNodeSet)
void RemoteRobot::getRobotNodeSets(vector<RobotNodeSetPtr>& storeNodeSet) const
{
NameList sets = _robot->getRobotNodeSets();
......@@ -399,7 +402,7 @@ namespace armarx
else
{
Ice::StringSeq includePaths;
for (const std::string & projectName : packages)
for (const std::string& projectName : packages)
{
if (projectName.empty())
{
......
......@@ -21,7 +21,7 @@
* @copyright http://www.gnu.org/licenses/gpl-2.0.txt
* GNU General Public License
*/
#pragma once
#ifndef _ARMARX_REMOTE_ROBOT_H__
#define _ARMARX_REMOTE_ROBOT_H__
......@@ -41,6 +41,13 @@
#include <boost/utility/enable_if.hpp>
#include <boost/type_traits/is_base_of.hpp>
//namespace VirtualRobot
//{
// class RobotNodeRevolute;
// class RobotNodePrismatic;
// class RobotNodeFixed;
//}
namespace armarx
{
// forward declaration of RemoteRobotNode
......@@ -150,7 +157,7 @@ namespace armarx
RemoteRobot(SharedRobotInterfacePrx robot);
virtual VirtualRobot::RobotNodePtr getRootNode();
virtual VirtualRobot::RobotNodePtr getRootNode() const;
virtual bool hasRobotNode(const std::string& robotNodeName);
virtual bool hasRobotNode(VirtualRobot::RobotNodePtr);
......@@ -159,8 +166,8 @@ namespace armarx
virtual void getRobotNodes(std::vector< VirtualRobot::RobotNodePtr >& storeNodes, bool clearVector = true);
virtual bool hasRobotNodeSet(const std::string& name);
virtual VirtualRobot::RobotNodeSetPtr getRobotNodeSet(const std::string& nodeSetName);
virtual void getRobotNodeSets(std::vector<VirtualRobot::RobotNodeSetPtr>& storeNodeSet);
virtual VirtualRobot::RobotNodeSetPtr getRobotNodeSet(const std::string& nodeSetName) const;
virtual void getRobotNodeSets(std::vector<VirtualRobot::RobotNodeSetPtr>& storeNodeSet) const;
/**
*
......@@ -258,7 +265,7 @@ namespace armarx
protected:
SharedRobotInterfacePrx _robot;
std::map<std::string, VirtualRobot::RobotNodePtr> _cachedNodes;
VirtualRobot::RobotNodePtr _root;
mutable VirtualRobot::RobotNodePtr _root;
static boost::recursive_mutex m;
......
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