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