Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
MoveModel.h
00001 #ifndef _ROS_jsk_interactive_marker_MoveModel_h 00002 #define _ROS_jsk_interactive_marker_MoveModel_h 00003 00004 #include <stdint.h> 00005 #include <string.h> 00006 #include <stdlib.h> 00007 #include "ros/msg.h" 00008 #include "std_msgs/Header.h" 00009 #include "sensor_msgs/JointState.h" 00010 #include "geometry_msgs/PoseStamped.h" 00011 00012 namespace jsk_interactive_marker 00013 { 00014 00015 class MoveModel : public ros::Msg 00016 { 00017 public: 00018 typedef std_msgs::Header _header_type; 00019 _header_type header; 00020 typedef const char* _name_type; 00021 _name_type name; 00022 typedef const char* _description_type; 00023 _description_type description; 00024 typedef sensor_msgs::JointState _joint_state_origin_type; 00025 _joint_state_origin_type joint_state_origin; 00026 typedef sensor_msgs::JointState _joint_state_goal_type; 00027 _joint_state_goal_type joint_state_goal; 00028 typedef geometry_msgs::PoseStamped _pose_origin_type; 00029 _pose_origin_type pose_origin; 00030 typedef geometry_msgs::PoseStamped _pose_goal_type; 00031 _pose_goal_type pose_goal; 00032 00033 MoveModel(): 00034 header(), 00035 name(""), 00036 description(""), 00037 joint_state_origin(), 00038 joint_state_goal(), 00039 pose_origin(), 00040 pose_goal() 00041 { 00042 } 00043 00044 virtual int serialize(unsigned char *outbuffer) const 00045 { 00046 int offset = 0; 00047 offset += this->header.serialize(outbuffer + offset); 00048 uint32_t length_name = strlen(this->name); 00049 varToArr(outbuffer + offset, length_name); 00050 offset += 4; 00051 memcpy(outbuffer + offset, this->name, length_name); 00052 offset += length_name; 00053 uint32_t length_description = strlen(this->description); 00054 varToArr(outbuffer + offset, length_description); 00055 offset += 4; 00056 memcpy(outbuffer + offset, this->description, length_description); 00057 offset += length_description; 00058 offset += this->joint_state_origin.serialize(outbuffer + offset); 00059 offset += this->joint_state_goal.serialize(outbuffer + offset); 00060 offset += this->pose_origin.serialize(outbuffer + offset); 00061 offset += this->pose_goal.serialize(outbuffer + offset); 00062 return offset; 00063 } 00064 00065 virtual int deserialize(unsigned char *inbuffer) 00066 { 00067 int offset = 0; 00068 offset += this->header.deserialize(inbuffer + offset); 00069 uint32_t length_name; 00070 arrToVar(length_name, (inbuffer + offset)); 00071 offset += 4; 00072 for(unsigned int k= offset; k< offset+length_name; ++k){ 00073 inbuffer[k-1]=inbuffer[k]; 00074 } 00075 inbuffer[offset+length_name-1]=0; 00076 this->name = (char *)(inbuffer + offset-1); 00077 offset += length_name; 00078 uint32_t length_description; 00079 arrToVar(length_description, (inbuffer + offset)); 00080 offset += 4; 00081 for(unsigned int k= offset; k< offset+length_description; ++k){ 00082 inbuffer[k-1]=inbuffer[k]; 00083 } 00084 inbuffer[offset+length_description-1]=0; 00085 this->description = (char *)(inbuffer + offset-1); 00086 offset += length_description; 00087 offset += this->joint_state_origin.deserialize(inbuffer + offset); 00088 offset += this->joint_state_goal.deserialize(inbuffer + offset); 00089 offset += this->pose_origin.deserialize(inbuffer + offset); 00090 offset += this->pose_goal.deserialize(inbuffer + offset); 00091 return offset; 00092 } 00093 00094 virtual const char * getType(){ return "jsk_interactive_marker/MoveModel"; }; 00095 virtual const char * getMD5(){ return "61edcddd6ca50e876e68d4fcf06c90f6"; }; 00096 00097 }; 00098 00099 } 00100 #endif
Generated on Mon Sep 26 2022 13:47:02 by
