00001
00002 #ifndef TEST_ROSCPP_SERIALIZATION_MESSAGE_FIXEDLENGTHSTRINGARRAY_H
00003 #define TEST_ROSCPP_SERIALIZATION_MESSAGE_FIXEDLENGTHSTRINGARRAY_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
00014 namespace test_roscpp_serialization
00015 {
00016 template <class ContainerAllocator>
00017 struct FixedLengthStringArray_ : public ros::Message
00018 {
00019 typedef FixedLengthStringArray_<ContainerAllocator> Type;
00020
00021 FixedLengthStringArray_()
00022 : foo()
00023 {
00024 }
00025
00026 FixedLengthStringArray_(const ContainerAllocator& _alloc)
00027 : foo()
00028 {
00029 foo.assign(std::basic_string<char, std::char_traits<char>, typename ContainerAllocator::template rebind<char>::other > (_alloc));
00030 }
00031
00032 typedef boost::array<std::basic_string<char, std::char_traits<char>, typename ContainerAllocator::template rebind<char>::other > , 5> _foo_type;
00033 boost::array<std::basic_string<char, std::char_traits<char>, typename ContainerAllocator::template rebind<char>::other > , 5> foo;
00034
00035
00036 ROS_DEPRECATED uint32_t get_foo_size() const { return (uint32_t)foo.size(); }
00037 private:
00038 static const char* __s_getDataType_() { return "test_roscpp_serialization/FixedLengthStringArray"; }
00039 public:
00040 ROS_DEPRECATED static const std::string __s_getDataType() { return __s_getDataType_(); }
00041
00042 ROS_DEPRECATED const std::string __getDataType() const { return __s_getDataType_(); }
00043
00044 private:
00045 static const char* __s_getMD5Sum_() { return "8e291ac046196a95bbe34c1555b382cc"; }
00046 public:
00047 ROS_DEPRECATED static const std::string __s_getMD5Sum() { return __s_getMD5Sum_(); }
00048
00049 ROS_DEPRECATED const std::string __getMD5Sum() const { return __s_getMD5Sum_(); }
00050
00051 private:
00052 static const char* __s_getMessageDefinition_() { return "string[5] foo\n\
00053 \n\
00054 "; }
00055 public:
00056 ROS_DEPRECATED static const std::string __s_getMessageDefinition() { return __s_getMessageDefinition_(); }
00057
00058 ROS_DEPRECATED const std::string __getMessageDefinition() const { return __s_getMessageDefinition_(); }
00059
00060 ROS_DEPRECATED virtual uint8_t *serialize(uint8_t *write_ptr, uint32_t seq) const
00061 {
00062 ros::serialization::OStream stream(write_ptr, 1000000000);
00063 ros::serialization::serialize(stream, foo);
00064 return stream.getData();
00065 }
00066
00067 ROS_DEPRECATED virtual uint8_t *deserialize(uint8_t *read_ptr)
00068 {
00069 ros::serialization::IStream stream(read_ptr, 1000000000);
00070 ros::serialization::deserialize(stream, foo);
00071 return stream.getData();
00072 }
00073
00074 ROS_DEPRECATED virtual uint32_t serializationLength() const
00075 {
00076 uint32_t size = 0;
00077 size += ros::serialization::serializationLength(foo);
00078 return size;
00079 }
00080
00081 typedef boost::shared_ptr< ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> > Ptr;
00082 typedef boost::shared_ptr< ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> const> ConstPtr;
00083 };
00084 typedef ::test_roscpp_serialization::FixedLengthStringArray_<std::allocator<void> > FixedLengthStringArray;
00085
00086 typedef boost::shared_ptr< ::test_roscpp_serialization::FixedLengthStringArray> FixedLengthStringArrayPtr;
00087 typedef boost::shared_ptr< ::test_roscpp_serialization::FixedLengthStringArray const> FixedLengthStringArrayConstPtr;
00088
00089
00090 template<typename ContainerAllocator>
00091 std::ostream& operator<<(std::ostream& s, const ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> & v)
00092 {
00093 ros::message_operations::Printer< ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> >::stream(s, "", v);
00094 return s;}
00095
00096 }
00097
00098 namespace ros
00099 {
00100 namespace message_traits
00101 {
00102 template<class ContainerAllocator>
00103 struct MD5Sum< ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> > {
00104 static const char* value()
00105 {
00106 return "8e291ac046196a95bbe34c1555b382cc";
00107 }
00108
00109 static const char* value(const ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> &) { return value(); }
00110 static const uint64_t static_value1 = 0x8e291ac046196a95ULL;
00111 static const uint64_t static_value2 = 0xbbe34c1555b382ccULL;
00112 };
00113
00114 template<class ContainerAllocator>
00115 struct DataType< ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> > {
00116 static const char* value()
00117 {
00118 return "test_roscpp_serialization/FixedLengthStringArray";
00119 }
00120
00121 static const char* value(const ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> &) { return value(); }
00122 };
00123
00124 template<class ContainerAllocator>
00125 struct Definition< ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> > {
00126 static const char* value()
00127 {
00128 return "string[5] foo\n\
00129 \n\
00130 ";
00131 }
00132
00133 static const char* value(const ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> &) { return value(); }
00134 };
00135
00136 }
00137 }
00138
00139 namespace ros
00140 {
00141 namespace serialization
00142 {
00143
00144 template<class ContainerAllocator> struct Serializer< ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> >
00145 {
00146 template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
00147 {
00148 stream.next(m.foo);
00149 }
00150
00151 ROS_DECLARE_ALLINONE_SERIALIZER;
00152 };
00153 }
00154 }
00155
00156 namespace ros
00157 {
00158 namespace message_operations
00159 {
00160
00161 template<class ContainerAllocator>
00162 struct Printer< ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> >
00163 {
00164 template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::test_roscpp_serialization::FixedLengthStringArray_<ContainerAllocator> & v)
00165 {
00166 s << indent << "foo[]" << std::endl;
00167 for (size_t i = 0; i < v.foo.size(); ++i)
00168 {
00169 s << indent << " foo[" << i << "]: ";
00170 Printer<std::basic_string<char, std::char_traits<char>, typename ContainerAllocator::template rebind<char>::other > >::stream(s, indent + " ", v.foo[i]);
00171 }
00172 }
00173 };
00174
00175
00176 }
00177 }
00178
00179 #endif // TEST_ROSCPP_SERIALIZATION_MESSAGE_FIXEDLENGTHSTRINGARRAY_H
00180