diff --git a/webots_ros2_driver/include/webots_ros2_driver/WebotsNode.hpp b/webots_ros2_driver/include/webots_ros2_driver/WebotsNode.hpp index 7fc176652..9d38f7334 100644 --- a/webots_ros2_driver/include/webots_ros2_driver/WebotsNode.hpp +++ b/webots_ros2_driver/include/webots_ros2_driver/WebotsNode.hpp @@ -44,19 +44,21 @@ namespace webots_ros2_driver webots::Supervisor *robot() { return mRobot; } std::string urdf() const { return mRobotDescription; }; + protected: + webots::Supervisor* mRobot; + std::string mRobotName; + std::string mRobotDescription; + + rclcpp::Client::SharedPtr mClient; + void setAnotherNodeParameter(std::string anotherNodeName, std::string parameterName, std::string parameterValue); + private: void timerCallback(); std::unordered_map getDeviceRosProperties(const std::string &name) const; std::unordered_map getPluginProperties(tinyxml2::XMLElement *pluginElement) const; - void setAnotherNodeParameter(std::string anotherNodeName, std::string parameterName, std::string parameterValue); - rclcpp::Client::SharedPtr mClient; - - std::string mRobotName; - std::string mRobotDescription; - rclcpp::TimerBase::SharedPtr mTimer; int mStep; - webots::Supervisor *mRobot; + rclcpp::TimerBase::SharedPtr mTimer; std::vector> mPlugins; pluginlib::ClassLoader mPluginLoader; tinyxml2::XMLElement *mWebotsXMLElement;