RosWrapperBase.h
Go to the documentation of this file.
1 //| This file is a part of the ORCA framework.
2 //|
3 //| Copyright 2018, Fuzzy Logic Robotics
4 //| Copyright 2017, ISIR / Universite Pierre et Marie Curie (UPMC)
5 //|
6 //| Main contributor(s): Antoine Hoarau, Ryan Lober, and
7 //| Fuzzy Logic Robotics <info@fuzzylogicrobotics.com>
8 //|
9 //| ORCA is a whole-body reactive controller framework for robotics.
10 //|
11 //| This software is governed by the CeCILL-C license under French law and
12 //| abiding by the rules of distribution of free software. You can use,
13 //| modify and/ or redistribute the software under the terms of the CeCILL-C
14 //| license as circulated by CEA, CNRS and INRIA at the following URL
15 //| "http://www.cecill.info".
16 //|
17 //| As a counterpart to the access to the source code and rights to copy,
18 //| modify and redistribute granted by the license, users are provided only
19 //| with a limited warranty and the software's author, the holder of the
20 //| economic rights, and the successive licensors have only limited
21 //| liability.
22 //|
23 //| In this respect, the user's attention is drawn to the risks associated
24 //| with loading, using, modifying and/or developing or reproducing the
25 //| software by the user in light of its specific status of free software,
26 //| that may mean that it is complicated to manipulate, and that also
27 //| therefore means that it is reserved for developers and experienced
28 //| professionals having in-depth computer knowledge. Users are therefore
29 //| encouraged to load and test the software's suitability as regards their
30 //| requirements in conditions enabling the security of their systems and/or
31 //| data to be ensured and, more generally, to use and operate it in the
32 //| same conditions as regards security.
33 //|
34 //| The fact that you are presently reading this means that you have had
35 //| knowledge of the CeCILL-C license and that you accept its terms.
36 
37 #pragma once
38 
39 #include <ros/ros.h>
40 #include <orca/orca.h>
42 #include <orca_ros/services.h>
43 #include <orca_ros/messages.h>
44 
45 namespace orca_ros
46 {
47 namespace common
48 {
49 
51  {
52  public:
53  RosWrapperBase (const std::string& robot_name,
54  const std::string& controller_name="",
55  const std::string& obj_name="",
56  const std::string& generic_prefix="");
57  virtual ~RosWrapperBase ();
58 
59 
63  std::string getRobotName();
64 
68  std::string getControllerName();
69 
73  std::string getGenericPrefix();
74 
78  std::string getObjectName();
79 
83  std::shared_ptr<ros::NodeHandle> getNodeHandle();
84 
85 
89  std::string getNamespacePrefix();
90 
91 
92  std::string getRobotNamespacePrefix();
93 
94  private:
95  std::string rn_ = "";
96  std::string cn_ = "";
97  std::string gp_ = "";
98  std::string on_ = "";
99  std::shared_ptr<ros::NodeHandle> nh_;
100  };
101 
102 } //common
103 } // orca_ros
Definition: RosWrapperBase.h:50
RosWrapperBase(const std::string &robot_name, const std::string &controller_name="", const std::string &obj_name="", const std::string &generic_prefix="")
Definition: RosWrapperBase.cc:5
std::string getNamespacePrefix()
Definition: RosWrapperBase.cc:42
std::string getRobotNamespacePrefix()
Definition: RosWrapperBase.cc:60
std::string getObjectName()
Definition: RosWrapperBase.cc:38
Definition: RosCartesianAccelerationPID.h:42
std::string getRobotName()
Definition: RosWrapperBase.cc:26
std::shared_ptr< ros::NodeHandle > getNodeHandle()
Definition: RosWrapperBase.cc:22
std::string getControllerName()
Definition: RosWrapperBase.cc:30
virtual ~RosWrapperBase()
Definition: RosWrapperBase.cc:18
std::string getGenericPrefix()
Definition: RosWrapperBase.cc:34