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