00001
00002 #ifndef TEST_ROSJAVA_MESSAGE_TESTBADDATATYPES_H
00003 #define TEST_ROSJAVA_MESSAGE_TESTBADDATATYPES_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/Byte.h"
00014 #include "std_msgs/ByteMultiArray.h"
00015
00016 namespace test_rosjava
00017 {
00018 template <class ContainerAllocator>
00019 struct TestBadDataTypes_ : public ros::Message
00020 {
00021 typedef TestBadDataTypes_<ContainerAllocator> Type;
00022
00023 TestBadDataTypes_()
00024 : Byte_f()
00025 , ByteMultiArray_f()
00026 {
00027 }
00028
00029 TestBadDataTypes_(const ContainerAllocator& _alloc)
00030 : Byte_f()
00031 , ByteMultiArray_f()
00032 {
00033 Byte_f.assign( ::std_msgs::Byte_<ContainerAllocator> (_alloc));
00034 ByteMultiArray_f.assign( ::std_msgs::ByteMultiArray_<ContainerAllocator> (_alloc));
00035 }
00036
00037 typedef boost::array< ::std_msgs::Byte_<ContainerAllocator> , 2> _Byte_f_type;
00038 boost::array< ::std_msgs::Byte_<ContainerAllocator> , 2> Byte_f;
00039
00040 typedef boost::array< ::std_msgs::ByteMultiArray_<ContainerAllocator> , 1> _ByteMultiArray_f_type;
00041 boost::array< ::std_msgs::ByteMultiArray_<ContainerAllocator> , 1> ByteMultiArray_f;
00042
00043
00044 ROS_DEPRECATED uint32_t get_Byte_f_size() const { return (uint32_t)Byte_f.size(); }
00045 ROS_DEPRECATED uint32_t get_ByteMultiArray_f_size() const { return (uint32_t)ByteMultiArray_f.size(); }
00046 private:
00047 static const char* __s_getDataType_() { return "test_rosjava/TestBadDataTypes"; }
00048 public:
00049 ROS_DEPRECATED static const std::string __s_getDataType() { return __s_getDataType_(); }
00050
00051 ROS_DEPRECATED const std::string __getDataType() const { return __s_getDataType_(); }
00052
00053 private:
00054 static const char* __s_getMD5Sum_() { return "f0fea41d38f14ed745582d619f53bcd0"; }
00055 public:
00056 ROS_DEPRECATED static const std::string __s_getMD5Sum() { return __s_getMD5Sum_(); }
00057
00058 ROS_DEPRECATED const std::string __getMD5Sum() const { return __s_getMD5Sum_(); }
00059
00060 private:
00061 static const char* __s_getMessageDefinition_() { return "# Unfortunately, can't test these fully because roscpp message generation\n\
00062 # is broken. \n\
00063 \n\
00064 std_msgs/Byte[2] Byte_f\n\
00065 std_msgs/ByteMultiArray[1] ByteMultiArray_f\n\
00066 \n\
00067 ================================================================================\n\
00068 MSG: std_msgs/Byte\n\
00069 byte data\n\
00070 \n\
00071 ================================================================================\n\
00072 MSG: std_msgs/ByteMultiArray\n\
00073 # Please look at the MultiArrayLayout message definition for\n\
00074 # documentation on all multiarrays.\n\
00075 \n\
00076 MultiArrayLayout layout # specification of data layout\n\
00077 byte[] data # array of data\n\
00078 \n\
00079 \n\
00080 ================================================================================\n\
00081 MSG: std_msgs/MultiArrayLayout\n\
00082 # The multiarray declares a generic multi-dimensional array of a\n\
00083 # particular data type. Dimensions are ordered from outer most\n\
00084 # to inner most.\n\
00085 \n\
00086 MultiArrayDimension[] dim # Array of dimension properties\n\
00087 uint32 data_offset # padding bytes at front of data\n\
00088 \n\
00089 # Accessors should ALWAYS be written in terms of dimension stride\n\
00090 # and specified outer-most dimension first.\n\
00091 # \n\
00092 # multiarray(i,j,k) = data[data_offset + dim_stride[1]*i + dim_stride[2]*j + k]\n\
00093 #\n\
00094 # A standard, 3-channel 640x480 image with interleaved color channels\n\
00095 # would be specified as:\n\
00096 #\n\
00097 # dim[0].label = \"height\"\n\
00098 # dim[0].size = 480\n\
00099 # dim[0].stride = 3*640*480 = 921600 (note dim[0] stride is just size of image)\n\
00100 # dim[1].label = \"width\"\n\
00101 # dim[1].size = 640\n\
00102 # dim[1].stride = 3*640 = 1920\n\
00103 # dim[2].label = \"channel\"\n\
00104 # dim[2].size = 3\n\
00105 # dim[2].stride = 3\n\
00106 #\n\
00107 # multiarray(i,j,k) refers to the ith row, jth column, and kth channel.\n\
00108 ================================================================================\n\
00109 MSG: std_msgs/MultiArrayDimension\n\
00110 string label # label of given dimension\n\
00111 uint32 size # size of given dimension (in type units)\n\
00112 uint32 stride # stride of given dimension\n\
00113 "; }
00114 public:
00115 ROS_DEPRECATED static const std::string __s_getMessageDefinition() { return __s_getMessageDefinition_(); }
00116
00117 ROS_DEPRECATED const std::string __getMessageDefinition() const { return __s_getMessageDefinition_(); }
00118
00119 ROS_DEPRECATED virtual uint8_t *serialize(uint8_t *write_ptr, uint32_t seq) const
00120 {
00121 ros::serialization::OStream stream(write_ptr, 1000000000);
00122 ros::serialization::serialize(stream, Byte_f);
00123 ros::serialization::serialize(stream, ByteMultiArray_f);
00124 return stream.getData();
00125 }
00126
00127 ROS_DEPRECATED virtual uint8_t *deserialize(uint8_t *read_ptr)
00128 {
00129 ros::serialization::IStream stream(read_ptr, 1000000000);
00130 ros::serialization::deserialize(stream, Byte_f);
00131 ros::serialization::deserialize(stream, ByteMultiArray_f);
00132 return stream.getData();
00133 }
00134
00135 ROS_DEPRECATED virtual uint32_t serializationLength() const
00136 {
00137 uint32_t size = 0;
00138 size += ros::serialization::serializationLength(Byte_f);
00139 size += ros::serialization::serializationLength(ByteMultiArray_f);
00140 return size;
00141 }
00142
00143 typedef boost::shared_ptr< ::test_rosjava::TestBadDataTypes_<ContainerAllocator> > Ptr;
00144 typedef boost::shared_ptr< ::test_rosjava::TestBadDataTypes_<ContainerAllocator> const> ConstPtr;
00145 };
00146 typedef ::test_rosjava::TestBadDataTypes_<std::allocator<void> > TestBadDataTypes;
00147
00148 typedef boost::shared_ptr< ::test_rosjava::TestBadDataTypes> TestBadDataTypesPtr;
00149 typedef boost::shared_ptr< ::test_rosjava::TestBadDataTypes const> TestBadDataTypesConstPtr;
00150
00151
00152 template<typename ContainerAllocator>
00153 std::ostream& operator<<(std::ostream& s, const ::test_rosjava::TestBadDataTypes_<ContainerAllocator> & v)
00154 {
00155 ros::message_operations::Printer< ::test_rosjava::TestBadDataTypes_<ContainerAllocator> >::stream(s, "", v);
00156 return s;}
00157
00158 }
00159
00160 namespace ros
00161 {
00162 namespace message_traits
00163 {
00164 template<class ContainerAllocator>
00165 struct MD5Sum< ::test_rosjava::TestBadDataTypes_<ContainerAllocator> > {
00166 static const char* value()
00167 {
00168 return "f0fea41d38f14ed745582d619f53bcd0";
00169 }
00170
00171 static const char* value(const ::test_rosjava::TestBadDataTypes_<ContainerAllocator> &) { return value(); }
00172 static const uint64_t static_value1 = 0xf0fea41d38f14ed7ULL;
00173 static const uint64_t static_value2 = 0x45582d619f53bcd0ULL;
00174 };
00175
00176 template<class ContainerAllocator>
00177 struct DataType< ::test_rosjava::TestBadDataTypes_<ContainerAllocator> > {
00178 static const char* value()
00179 {
00180 return "test_rosjava/TestBadDataTypes";
00181 }
00182
00183 static const char* value(const ::test_rosjava::TestBadDataTypes_<ContainerAllocator> &) { return value(); }
00184 };
00185
00186 template<class ContainerAllocator>
00187 struct Definition< ::test_rosjava::TestBadDataTypes_<ContainerAllocator> > {
00188 static const char* value()
00189 {
00190 return "# Unfortunately, can't test these fully because roscpp message generation\n\
00191 # is broken. \n\
00192 \n\
00193 std_msgs/Byte[2] Byte_f\n\
00194 std_msgs/ByteMultiArray[1] ByteMultiArray_f\n\
00195 \n\
00196 ================================================================================\n\
00197 MSG: std_msgs/Byte\n\
00198 byte data\n\
00199 \n\
00200 ================================================================================\n\
00201 MSG: std_msgs/ByteMultiArray\n\
00202 # Please look at the MultiArrayLayout message definition for\n\
00203 # documentation on all multiarrays.\n\
00204 \n\
00205 MultiArrayLayout layout # specification of data layout\n\
00206 byte[] data # array of data\n\
00207 \n\
00208 \n\
00209 ================================================================================\n\
00210 MSG: std_msgs/MultiArrayLayout\n\
00211 # The multiarray declares a generic multi-dimensional array of a\n\
00212 # particular data type. Dimensions are ordered from outer most\n\
00213 # to inner most.\n\
00214 \n\
00215 MultiArrayDimension[] dim # Array of dimension properties\n\
00216 uint32 data_offset # padding bytes at front of data\n\
00217 \n\
00218 # Accessors should ALWAYS be written in terms of dimension stride\n\
00219 # and specified outer-most dimension first.\n\
00220 # \n\
00221 # multiarray(i,j,k) = data[data_offset + dim_stride[1]*i + dim_stride[2]*j + k]\n\
00222 #\n\
00223 # A standard, 3-channel 640x480 image with interleaved color channels\n\
00224 # would be specified as:\n\
00225 #\n\
00226 # dim[0].label = \"height\"\n\
00227 # dim[0].size = 480\n\
00228 # dim[0].stride = 3*640*480 = 921600 (note dim[0] stride is just size of image)\n\
00229 # dim[1].label = \"width\"\n\
00230 # dim[1].size = 640\n\
00231 # dim[1].stride = 3*640 = 1920\n\
00232 # dim[2].label = \"channel\"\n\
00233 # dim[2].size = 3\n\
00234 # dim[2].stride = 3\n\
00235 #\n\
00236 # multiarray(i,j,k) refers to the ith row, jth column, and kth channel.\n\
00237 ================================================================================\n\
00238 MSG: std_msgs/MultiArrayDimension\n\
00239 string label # label of given dimension\n\
00240 uint32 size # size of given dimension (in type units)\n\
00241 uint32 stride # stride of given dimension\n\
00242 ";
00243 }
00244
00245 static const char* value(const ::test_rosjava::TestBadDataTypes_<ContainerAllocator> &) { return value(); }
00246 };
00247
00248 }
00249 }
00250
00251 namespace ros
00252 {
00253 namespace serialization
00254 {
00255
00256 template<class ContainerAllocator> struct Serializer< ::test_rosjava::TestBadDataTypes_<ContainerAllocator> >
00257 {
00258 template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
00259 {
00260 stream.next(m.Byte_f);
00261 stream.next(m.ByteMultiArray_f);
00262 }
00263
00264 ROS_DECLARE_ALLINONE_SERIALIZER;
00265 };
00266 }
00267 }
00268
00269 namespace ros
00270 {
00271 namespace message_operations
00272 {
00273
00274 template<class ContainerAllocator>
00275 struct Printer< ::test_rosjava::TestBadDataTypes_<ContainerAllocator> >
00276 {
00277 template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::test_rosjava::TestBadDataTypes_<ContainerAllocator> & v)
00278 {
00279 s << indent << "Byte_f[]" << std::endl;
00280 for (size_t i = 0; i < v.Byte_f.size(); ++i)
00281 {
00282 s << indent << " Byte_f[" << i << "]: ";
00283 s << std::endl;
00284 s << indent;
00285 Printer< ::std_msgs::Byte_<ContainerAllocator> >::stream(s, indent + " ", v.Byte_f[i]);
00286 }
00287 s << indent << "ByteMultiArray_f[]" << std::endl;
00288 for (size_t i = 0; i < v.ByteMultiArray_f.size(); ++i)
00289 {
00290 s << indent << " ByteMultiArray_f[" << i << "]: ";
00291 s << std::endl;
00292 s << indent;
00293 Printer< ::std_msgs::ByteMultiArray_<ContainerAllocator> >::stream(s, indent + " ", v.ByteMultiArray_f[i]);
00294 }
00295 }
00296 };
00297
00298
00299 }
00300 }
00301
00302 #endif // TEST_ROSJAVA_MESSAGE_TESTBADDATATYPES_H
00303