00001
00002 #ifndef CLEARPATH_BASE_MESSAGE_MAGNETOMETER_H
00003 #define CLEARPATH_BASE_MESSAGE_MAGNETOMETER_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 "std_msgs/Header.h"
00014
00015 namespace clearpath_base
00016 {
00017 template <class ContainerAllocator>
00018 struct Magnetometer_ : public ros::Message
00019 {
00020 typedef Magnetometer_<ContainerAllocator> Type;
00021
00022 Magnetometer_()
00023 : header()
00024 , x(0.0)
00025 , y(0.0)
00026 , z(0.0)
00027 {
00028 }
00029
00030 Magnetometer_(const ContainerAllocator& _alloc)
00031 : header(_alloc)
00032 , x(0.0)
00033 , y(0.0)
00034 , z(0.0)
00035 {
00036 }
00037
00038 typedef ::std_msgs::Header_<ContainerAllocator> _header_type;
00039 ::std_msgs::Header_<ContainerAllocator> header;
00040
00041 typedef double _x_type;
00042 double x;
00043
00044 typedef double _y_type;
00045 double y;
00046
00047 typedef double _z_type;
00048 double z;
00049
00050
00051 private:
00052 static const char* __s_getDataType_() { return "clearpath_base/Magnetometer"; }
00053 public:
00054 ROS_DEPRECATED static const std::string __s_getDataType() { return __s_getDataType_(); }
00055
00056 ROS_DEPRECATED const std::string __getDataType() const { return __s_getDataType_(); }
00057
00058 private:
00059 static const char* __s_getMD5Sum_() { return "5defbd163657b4f6f639ba6d5676cc01"; }
00060 public:
00061 ROS_DEPRECATED static const std::string __s_getMD5Sum() { return __s_getMD5Sum_(); }
00062
00063 ROS_DEPRECATED const std::string __getMD5Sum() const { return __s_getMD5Sum_(); }
00064
00065 private:
00066 static const char* __s_getMessageDefinition_() { return "Header header\n\
00067 float64 x\n\
00068 float64 y\n\
00069 float64 z\n\
00070 ================================================================================\n\
00071 MSG: std_msgs/Header\n\
00072 # Standard metadata for higher-level stamped data types.\n\
00073 # This is generally used to communicate timestamped data \n\
00074 # in a particular coordinate frame.\n\
00075 # \n\
00076 # sequence ID: consecutively increasing ID \n\
00077 uint32 seq\n\
00078 #Two-integer timestamp that is expressed as:\n\
00079 # * stamp.secs: seconds (stamp_secs) since epoch\n\
00080 # * stamp.nsecs: nanoseconds since stamp_secs\n\
00081 # time-handling sugar is provided by the client library\n\
00082 time stamp\n\
00083 #Frame this data is associated with\n\
00084 # 0: no frame\n\
00085 # 1: global frame\n\
00086 string frame_id\n\
00087 \n\
00088 "; }
00089 public:
00090 ROS_DEPRECATED static const std::string __s_getMessageDefinition() { return __s_getMessageDefinition_(); }
00091
00092 ROS_DEPRECATED const std::string __getMessageDefinition() const { return __s_getMessageDefinition_(); }
00093
00094 ROS_DEPRECATED virtual uint8_t *serialize(uint8_t *write_ptr, uint32_t seq) const
00095 {
00096 ros::serialization::OStream stream(write_ptr, 1000000000);
00097 ros::serialization::serialize(stream, header);
00098 ros::serialization::serialize(stream, x);
00099 ros::serialization::serialize(stream, y);
00100 ros::serialization::serialize(stream, z);
00101 return stream.getData();
00102 }
00103
00104 ROS_DEPRECATED virtual uint8_t *deserialize(uint8_t *read_ptr)
00105 {
00106 ros::serialization::IStream stream(read_ptr, 1000000000);
00107 ros::serialization::deserialize(stream, header);
00108 ros::serialization::deserialize(stream, x);
00109 ros::serialization::deserialize(stream, y);
00110 ros::serialization::deserialize(stream, z);
00111 return stream.getData();
00112 }
00113
00114 ROS_DEPRECATED virtual uint32_t serializationLength() const
00115 {
00116 uint32_t size = 0;
00117 size += ros::serialization::serializationLength(header);
00118 size += ros::serialization::serializationLength(x);
00119 size += ros::serialization::serializationLength(y);
00120 size += ros::serialization::serializationLength(z);
00121 return size;
00122 }
00123
00124 typedef boost::shared_ptr< ::clearpath_base::Magnetometer_<ContainerAllocator> > Ptr;
00125 typedef boost::shared_ptr< ::clearpath_base::Magnetometer_<ContainerAllocator> const> ConstPtr;
00126 };
00127 typedef ::clearpath_base::Magnetometer_<std::allocator<void> > Magnetometer;
00128
00129 typedef boost::shared_ptr< ::clearpath_base::Magnetometer> MagnetometerPtr;
00130 typedef boost::shared_ptr< ::clearpath_base::Magnetometer const> MagnetometerConstPtr;
00131
00132
00133 template<typename ContainerAllocator>
00134 std::ostream& operator<<(std::ostream& s, const ::clearpath_base::Magnetometer_<ContainerAllocator> & v)
00135 {
00136 ros::message_operations::Printer< ::clearpath_base::Magnetometer_<ContainerAllocator> >::stream(s, "", v);
00137 return s;}
00138
00139 }
00140
00141 namespace ros
00142 {
00143 namespace message_traits
00144 {
00145 template<class ContainerAllocator>
00146 struct MD5Sum< ::clearpath_base::Magnetometer_<ContainerAllocator> > {
00147 static const char* value()
00148 {
00149 return "5defbd163657b4f6f639ba6d5676cc01";
00150 }
00151
00152 static const char* value(const ::clearpath_base::Magnetometer_<ContainerAllocator> &) { return value(); }
00153 static const uint64_t static_value1 = 0x5defbd163657b4f6ULL;
00154 static const uint64_t static_value2 = 0xf639ba6d5676cc01ULL;
00155 };
00156
00157 template<class ContainerAllocator>
00158 struct DataType< ::clearpath_base::Magnetometer_<ContainerAllocator> > {
00159 static const char* value()
00160 {
00161 return "clearpath_base/Magnetometer";
00162 }
00163
00164 static const char* value(const ::clearpath_base::Magnetometer_<ContainerAllocator> &) { return value(); }
00165 };
00166
00167 template<class ContainerAllocator>
00168 struct Definition< ::clearpath_base::Magnetometer_<ContainerAllocator> > {
00169 static const char* value()
00170 {
00171 return "Header header\n\
00172 float64 x\n\
00173 float64 y\n\
00174 float64 z\n\
00175 ================================================================================\n\
00176 MSG: std_msgs/Header\n\
00177 # Standard metadata for higher-level stamped data types.\n\
00178 # This is generally used to communicate timestamped data \n\
00179 # in a particular coordinate frame.\n\
00180 # \n\
00181 # sequence ID: consecutively increasing ID \n\
00182 uint32 seq\n\
00183 #Two-integer timestamp that is expressed as:\n\
00184 # * stamp.secs: seconds (stamp_secs) since epoch\n\
00185 # * stamp.nsecs: nanoseconds since stamp_secs\n\
00186 # time-handling sugar is provided by the client library\n\
00187 time stamp\n\
00188 #Frame this data is associated with\n\
00189 # 0: no frame\n\
00190 # 1: global frame\n\
00191 string frame_id\n\
00192 \n\
00193 ";
00194 }
00195
00196 static const char* value(const ::clearpath_base::Magnetometer_<ContainerAllocator> &) { return value(); }
00197 };
00198
00199 template<class ContainerAllocator> struct HasHeader< ::clearpath_base::Magnetometer_<ContainerAllocator> > : public TrueType {};
00200 template<class ContainerAllocator> struct HasHeader< const ::clearpath_base::Magnetometer_<ContainerAllocator> > : public TrueType {};
00201 }
00202 }
00203
00204 namespace ros
00205 {
00206 namespace serialization
00207 {
00208
00209 template<class ContainerAllocator> struct Serializer< ::clearpath_base::Magnetometer_<ContainerAllocator> >
00210 {
00211 template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
00212 {
00213 stream.next(m.header);
00214 stream.next(m.x);
00215 stream.next(m.y);
00216 stream.next(m.z);
00217 }
00218
00219 ROS_DECLARE_ALLINONE_SERIALIZER;
00220 };
00221 }
00222 }
00223
00224 namespace ros
00225 {
00226 namespace message_operations
00227 {
00228
00229 template<class ContainerAllocator>
00230 struct Printer< ::clearpath_base::Magnetometer_<ContainerAllocator> >
00231 {
00232 template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::clearpath_base::Magnetometer_<ContainerAllocator> & v)
00233 {
00234 s << indent << "header: ";
00235 s << std::endl;
00236 Printer< ::std_msgs::Header_<ContainerAllocator> >::stream(s, indent + " ", v.header);
00237 s << indent << "x: ";
00238 Printer<double>::stream(s, indent + " ", v.x);
00239 s << indent << "y: ";
00240 Printer<double>::stream(s, indent + " ", v.y);
00241 s << indent << "z: ";
00242 Printer<double>::stream(s, indent + " ", v.z);
00243 }
00244 };
00245
00246
00247 }
00248 }
00249
00250 #endif // CLEARPATH_BASE_MESSAGE_MAGNETOMETER_H
00251