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