00001
00002 #ifndef FINGERTIP_PRESSURE_MESSAGE_PRESSUREINFO_H
00003 #define FINGERTIP_PRESSURE_MESSAGE_PRESSUREINFO_H
00004 #include <string>
00005 #include <vector>
00006 #include <ostream>
00007 #include "ros/serialization.h"
00008 #include "ros/builtin_message_traits.h"
00009 #include "ros/message_operations.h"
00010 #include "ros/message.h"
00011 #include "ros/time.h"
00012
00013 #include "fingertip_pressure/PressureInfoElement.h"
00014
00015 namespace fingertip_pressure
00016 {
00017 template <class ContainerAllocator>
00018 struct PressureInfo_ : public ros::Message
00019 {
00020 typedef PressureInfo_<ContainerAllocator> Type;
00021
00022 PressureInfo_()
00023 : sensor()
00024 {
00025 }
00026
00027 PressureInfo_(const ContainerAllocator& _alloc)
00028 : sensor(_alloc)
00029 {
00030 }
00031
00032 typedef std::vector< ::fingertip_pressure::PressureInfoElement_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::fingertip_pressure::PressureInfoElement_<ContainerAllocator> >::other > _sensor_type;
00033 std::vector< ::fingertip_pressure::PressureInfoElement_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::fingertip_pressure::PressureInfoElement_<ContainerAllocator> >::other > sensor;
00034
00035
00036 ROS_DEPRECATED uint32_t get_sensor_size() const { return (uint32_t)sensor.size(); }
00037 ROS_DEPRECATED void set_sensor_size(uint32_t size) { sensor.resize((size_t)size); }
00038 ROS_DEPRECATED void get_sensor_vec(std::vector< ::fingertip_pressure::PressureInfoElement_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::fingertip_pressure::PressureInfoElement_<ContainerAllocator> >::other > & vec) const { vec = this->sensor; }
00039 ROS_DEPRECATED void set_sensor_vec(const std::vector< ::fingertip_pressure::PressureInfoElement_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::fingertip_pressure::PressureInfoElement_<ContainerAllocator> >::other > & vec) { this->sensor = vec; }
00040 private:
00041 static const char* __s_getDataType_() { return "fingertip_pressure/PressureInfo"; }
00042 public:
00043 ROS_DEPRECATED static const std::string __s_getDataType() { return __s_getDataType_(); }
00044
00045 ROS_DEPRECATED const std::string __getDataType() const { return __s_getDataType_(); }
00046
00047 private:
00048 static const char* __s_getMD5Sum_() { return "a11fc5bae3534aa023741e378743af5b"; }
00049 public:
00050 ROS_DEPRECATED static const std::string __s_getMD5Sum() { return __s_getMD5Sum_(); }
00051
00052 ROS_DEPRECATED const std::string __getMD5Sum() const { return __s_getMD5Sum_(); }
00053
00054 private:
00055 static const char* __s_getMessageDefinition_() { return "PressureInfoElement[] sensor # List of pressure sensors for which information is being published\n\
00056 \n\
00057 ================================================================================\n\
00058 MSG: fingertip_pressure/PressureInfoElement\n\
00059 string frame_id # Frame ID\n\
00060 geometry_msgs/Vector3[] center # Corner of sensor (meters)\n\
00061 geometry_msgs/Vector3[] halfside1 # Half of one edge of sensor (meters)\n\
00062 geometry_msgs/Vector3[] halfside2 # Half of perpendicular edge of sensor (meters)\n\
00063 # Sensor corners are at center+-halfside1+-halfside2\n\
00064 # Cross product of halfside1 and halfside2 points out\n\
00065 float64[] force_per_unit # Multiply this by the raw sensor value to get a force\n\
00066 \n\
00067 ================================================================================\n\
00068 MSG: geometry_msgs/Vector3\n\
00069 # This represents a vector in free space. \n\
00070 \n\
00071 float64 x\n\
00072 float64 y\n\
00073 float64 z\n\
00074 "; }
00075 public:
00076 ROS_DEPRECATED static const std::string __s_getMessageDefinition() { return __s_getMessageDefinition_(); }
00077
00078 ROS_DEPRECATED const std::string __getMessageDefinition() const { return __s_getMessageDefinition_(); }
00079
00080 ROS_DEPRECATED virtual uint8_t *serialize(uint8_t *write_ptr, uint32_t seq) const
00081 {
00082 ros::serialization::OStream stream(write_ptr, 1000000000);
00083 ros::serialization::serialize(stream, sensor);
00084 return stream.getData();
00085 }
00086
00087 ROS_DEPRECATED virtual uint8_t *deserialize(uint8_t *read_ptr)
00088 {
00089 ros::serialization::IStream stream(read_ptr, 1000000000);
00090 ros::serialization::deserialize(stream, sensor);
00091 return stream.getData();
00092 }
00093
00094 ROS_DEPRECATED virtual uint32_t serializationLength() const
00095 {
00096 uint32_t size = 0;
00097 size += ros::serialization::serializationLength(sensor);
00098 return size;
00099 }
00100
00101 typedef boost::shared_ptr< ::fingertip_pressure::PressureInfo_<ContainerAllocator> > Ptr;
00102 typedef boost::shared_ptr< ::fingertip_pressure::PressureInfo_<ContainerAllocator> const> ConstPtr;
00103 };
00104 typedef ::fingertip_pressure::PressureInfo_<std::allocator<void> > PressureInfo;
00105
00106 typedef boost::shared_ptr< ::fingertip_pressure::PressureInfo> PressureInfoPtr;
00107 typedef boost::shared_ptr< ::fingertip_pressure::PressureInfo const> PressureInfoConstPtr;
00108
00109
00110 template<typename ContainerAllocator>
00111 std::ostream& operator<<(std::ostream& s, const ::fingertip_pressure::PressureInfo_<ContainerAllocator> & v)
00112 {
00113 ros::message_operations::Printer< ::fingertip_pressure::PressureInfo_<ContainerAllocator> >::stream(s, "", v);
00114 return s;}
00115
00116 }
00117
00118 namespace ros
00119 {
00120 namespace message_traits
00121 {
00122 template<class ContainerAllocator>
00123 struct MD5Sum< ::fingertip_pressure::PressureInfo_<ContainerAllocator> > {
00124 static const char* value()
00125 {
00126 return "a11fc5bae3534aa023741e378743af5b";
00127 }
00128
00129 static const char* value(const ::fingertip_pressure::PressureInfo_<ContainerAllocator> &) { return value(); }
00130 static const uint64_t static_value1 = 0xa11fc5bae3534aa0ULL;
00131 static const uint64_t static_value2 = 0x23741e378743af5bULL;
00132 };
00133
00134 template<class ContainerAllocator>
00135 struct DataType< ::fingertip_pressure::PressureInfo_<ContainerAllocator> > {
00136 static const char* value()
00137 {
00138 return "fingertip_pressure/PressureInfo";
00139 }
00140
00141 static const char* value(const ::fingertip_pressure::PressureInfo_<ContainerAllocator> &) { return value(); }
00142 };
00143
00144 template<class ContainerAllocator>
00145 struct Definition< ::fingertip_pressure::PressureInfo_<ContainerAllocator> > {
00146 static const char* value()
00147 {
00148 return "PressureInfoElement[] sensor # List of pressure sensors for which information is being published\n\
00149 \n\
00150 ================================================================================\n\
00151 MSG: fingertip_pressure/PressureInfoElement\n\
00152 string frame_id # Frame ID\n\
00153 geometry_msgs/Vector3[] center # Corner of sensor (meters)\n\
00154 geometry_msgs/Vector3[] halfside1 # Half of one edge of sensor (meters)\n\
00155 geometry_msgs/Vector3[] halfside2 # Half of perpendicular edge of sensor (meters)\n\
00156 # Sensor corners are at center+-halfside1+-halfside2\n\
00157 # Cross product of halfside1 and halfside2 points out\n\
00158 float64[] force_per_unit # Multiply this by the raw sensor value to get a force\n\
00159 \n\
00160 ================================================================================\n\
00161 MSG: geometry_msgs/Vector3\n\
00162 # This represents a vector in free space. \n\
00163 \n\
00164 float64 x\n\
00165 float64 y\n\
00166 float64 z\n\
00167 ";
00168 }
00169
00170 static const char* value(const ::fingertip_pressure::PressureInfo_<ContainerAllocator> &) { return value(); }
00171 };
00172
00173 }
00174 }
00175
00176 namespace ros
00177 {
00178 namespace serialization
00179 {
00180
00181 template<class ContainerAllocator> struct Serializer< ::fingertip_pressure::PressureInfo_<ContainerAllocator> >
00182 {
00183 template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
00184 {
00185 stream.next(m.sensor);
00186 }
00187
00188 ROS_DECLARE_ALLINONE_SERIALIZER;
00189 };
00190 }
00191 }
00192
00193 namespace ros
00194 {
00195 namespace message_operations
00196 {
00197
00198 template<class ContainerAllocator>
00199 struct Printer< ::fingertip_pressure::PressureInfo_<ContainerAllocator> >
00200 {
00201 template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::fingertip_pressure::PressureInfo_<ContainerAllocator> & v)
00202 {
00203 s << indent << "sensor[]" << std::endl;
00204 for (size_t i = 0; i < v.sensor.size(); ++i)
00205 {
00206 s << indent << " sensor[" << i << "]: ";
00207 s << std::endl;
00208 s << indent;
00209 Printer< ::fingertip_pressure::PressureInfoElement_<ContainerAllocator> >::stream(s, indent + " ", v.sensor[i]);
00210 }
00211 }
00212 };
00213
00214
00215 }
00216 }
00217
00218 #endif // FINGERTIP_PRESSURE_MESSAGE_PRESSUREINFO_H
00219