42 namespace motoman_utils
45 bool getJointGroups(
const std::string topic_param, std::map<int, RobotGroup> & robot_groups)
53 std::vector<XmlRpc::XmlRpcValue> topics_list;
58 for (
int i = 0; i < topics_list_rpc.
size(); i++)
61 state_value = topics_list_rpc[i];
63 topics_list.push_back(state_value);
67 for (
size_t i = 0; i < topics_list.size(); i++)
71 std::vector<std::string> rg_joint_names;
75 joints = topics_list[i][
"joints"];
76 for (
int jt = 0; jt < joints.
size(); jt++)
78 rg_joint_names.push_back(static_cast<std::string>(joints[jt]));
84 group_number = topics_list[i][
"group"];
85 int group_number_int =
static_cast<int>(group_number);
88 std::string name_string;
90 name = topics_list[i][
"name"];
91 name_string =
static_cast<std::string
>(name);
94 std::string ns_string;
96 ns = topics_list[i][
"ns"];
98 ns_string =
static_cast<std::string
>(ns);
105 ROS_DEBUG_STREAM(
" ns: " << ns_string);
111 robot_groups[group_number] = rg;
void set_group_id(int gid)
bool getJointGroups(const std::string topic_param, std::map< int, RobotGroup > &robot_groups)
Parses multi-group joints from topic_param.
void set_name(std::string name)
ROSCPP_DECL bool get(const std::string &key, std::string &s)
void set_joint_names(std::vector< std::string > jnames)
ROSCPP_DECL bool has(const std::string &key)
#define ROS_DEBUG_STREAM(args)
#define ROS_INFO_STREAM(args)
void set_ns(std::string ns)
#define ROS_ERROR_STREAM(args)