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