00001
00002 #ifndef ARM_NAVIGATION_MSGS_MESSAGE_COLLISIONOBJECT_H
00003 #define ARM_NAVIGATION_MSGS_MESSAGE_COLLISIONOBJECT_H
00004 #include <string>
00005 #include <vector>
00006 #include <map>
00007 #include <ostream>
00008 #include "ros/serialization.h"
00009 #include "ros/builtin_message_traits.h"
00010 #include "ros/message_operations.h"
00011 #include "ros/time.h"
00012
00013 #include "ros/macros.h"
00014
00015 #include "ros/assert.h"
00016
00017 #include "std_msgs/Header.h"
00018 #include "arm_navigation_msgs/CollisionObjectOperation.h"
00019 #include "arm_navigation_msgs/Shape.h"
00020 #include "geometry_msgs/Pose.h"
00021
00022 namespace arm_navigation_msgs
00023 {
00024 template <class ContainerAllocator>
00025 struct CollisionObject_ {
00026 typedef CollisionObject_<ContainerAllocator> Type;
00027
00028 CollisionObject_()
00029 : header()
00030 , id()
00031 , padding(0.0)
00032 , operation()
00033 , shapes()
00034 , poses()
00035 {
00036 }
00037
00038 CollisionObject_(const ContainerAllocator& _alloc)
00039 : header(_alloc)
00040 , id(_alloc)
00041 , padding(0.0)
00042 , operation(_alloc)
00043 , shapes(_alloc)
00044 , poses(_alloc)
00045 {
00046 }
00047
00048 typedef ::std_msgs::Header_<ContainerAllocator> _header_type;
00049 ::std_msgs::Header_<ContainerAllocator> header;
00050
00051 typedef std::basic_string<char, std::char_traits<char>, typename ContainerAllocator::template rebind<char>::other > _id_type;
00052 std::basic_string<char, std::char_traits<char>, typename ContainerAllocator::template rebind<char>::other > id;
00053
00054 typedef float _padding_type;
00055 float padding;
00056
00057 typedef ::arm_navigation_msgs::CollisionObjectOperation_<ContainerAllocator> _operation_type;
00058 ::arm_navigation_msgs::CollisionObjectOperation_<ContainerAllocator> operation;
00059
00060 typedef std::vector< ::arm_navigation_msgs::Shape_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::arm_navigation_msgs::Shape_<ContainerAllocator> >::other > _shapes_type;
00061 std::vector< ::arm_navigation_msgs::Shape_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::arm_navigation_msgs::Shape_<ContainerAllocator> >::other > shapes;
00062
00063 typedef std::vector< ::geometry_msgs::Pose_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::geometry_msgs::Pose_<ContainerAllocator> >::other > _poses_type;
00064 std::vector< ::geometry_msgs::Pose_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::geometry_msgs::Pose_<ContainerAllocator> >::other > poses;
00065
00066
00067 typedef boost::shared_ptr< ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> > Ptr;
00068 typedef boost::shared_ptr< ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> const> ConstPtr;
00069 boost::shared_ptr<std::map<std::string, std::string> > __connection_header;
00070 };
00071 typedef ::arm_navigation_msgs::CollisionObject_<std::allocator<void> > CollisionObject;
00072
00073 typedef boost::shared_ptr< ::arm_navigation_msgs::CollisionObject> CollisionObjectPtr;
00074 typedef boost::shared_ptr< ::arm_navigation_msgs::CollisionObject const> CollisionObjectConstPtr;
00075
00076
00077 template<typename ContainerAllocator>
00078 std::ostream& operator<<(std::ostream& s, const ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> & v)
00079 {
00080 ros::message_operations::Printer< ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> >::stream(s, "", v);
00081 return s;}
00082
00083 }
00084
00085 namespace ros
00086 {
00087 namespace message_traits
00088 {
00089 template<class ContainerAllocator> struct IsMessage< ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> > : public TrueType {};
00090 template<class ContainerAllocator> struct IsMessage< ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> const> : public TrueType {};
00091 template<class ContainerAllocator>
00092 struct MD5Sum< ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> > {
00093 static const char* value()
00094 {
00095 return "7b972910c23ece1b873b3de0cf92ba97";
00096 }
00097
00098 static const char* value(const ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> &) { return value(); }
00099 static const uint64_t static_value1 = 0x7b972910c23ece1bULL;
00100 static const uint64_t static_value2 = 0x873b3de0cf92ba97ULL;
00101 };
00102
00103 template<class ContainerAllocator>
00104 struct DataType< ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> > {
00105 static const char* value()
00106 {
00107 return "arm_navigation_msgs/CollisionObject";
00108 }
00109
00110 static const char* value(const ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> &) { return value(); }
00111 };
00112
00113 template<class ContainerAllocator>
00114 struct Definition< ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> > {
00115 static const char* value()
00116 {
00117 return "# a header, used for interpreting the poses\n\
00118 Header header\n\
00119 \n\
00120 # the id of the object\n\
00121 string id\n\
00122 \n\
00123 # The padding used for filtering points near the object.\n\
00124 # This does not affect collision checking for the object. \n\
00125 # Set to negative to get zero padding.\n\
00126 float32 padding\n\
00127 \n\
00128 #This contains what is to be done with the object\n\
00129 CollisionObjectOperation operation\n\
00130 \n\
00131 #the shapes associated with the object\n\
00132 arm_navigation_msgs/Shape[] shapes\n\
00133 \n\
00134 #the poses associated with the shapes - will be transformed using the header\n\
00135 geometry_msgs/Pose[] poses\n\
00136 \n\
00137 ================================================================================\n\
00138 MSG: std_msgs/Header\n\
00139 # Standard metadata for higher-level stamped data types.\n\
00140 # This is generally used to communicate timestamped data \n\
00141 # in a particular coordinate frame.\n\
00142 # \n\
00143 # sequence ID: consecutively increasing ID \n\
00144 uint32 seq\n\
00145 #Two-integer timestamp that is expressed as:\n\
00146 # * stamp.secs: seconds (stamp_secs) since epoch\n\
00147 # * stamp.nsecs: nanoseconds since stamp_secs\n\
00148 # time-handling sugar is provided by the client library\n\
00149 time stamp\n\
00150 #Frame this data is associated with\n\
00151 # 0: no frame\n\
00152 # 1: global frame\n\
00153 string frame_id\n\
00154 \n\
00155 ================================================================================\n\
00156 MSG: arm_navigation_msgs/CollisionObjectOperation\n\
00157 #Puts the object into the environment\n\
00158 #or updates the object if already added\n\
00159 byte ADD=0\n\
00160 \n\
00161 #Removes the object from the environment entirely\n\
00162 byte REMOVE=1\n\
00163 \n\
00164 #Only valid within the context of a CollisionAttachedObject message\n\
00165 #Will be ignored if sent with an CollisionObject message\n\
00166 #Takes an attached object, detaches from the attached link\n\
00167 #But adds back in as regular object\n\
00168 byte DETACH_AND_ADD_AS_OBJECT=2\n\
00169 \n\
00170 #Only valid within the context of a CollisionAttachedObject message\n\
00171 #Will be ignored if sent with an CollisionObject message\n\
00172 #Takes current object in the environment and removes it as\n\
00173 #a regular object\n\
00174 byte ATTACH_AND_REMOVE_AS_OBJECT=3\n\
00175 \n\
00176 # Byte code for operation\n\
00177 byte operation\n\
00178 \n\
00179 ================================================================================\n\
00180 MSG: arm_navigation_msgs/Shape\n\
00181 byte SPHERE=0\n\
00182 byte BOX=1\n\
00183 byte CYLINDER=2\n\
00184 byte MESH=3\n\
00185 \n\
00186 byte type\n\
00187 \n\
00188 \n\
00189 #### define sphere, box, cylinder ####\n\
00190 # the origin of each shape is considered at the shape's center\n\
00191 \n\
00192 # for sphere\n\
00193 # radius := dimensions[0]\n\
00194 \n\
00195 # for cylinder\n\
00196 # radius := dimensions[0]\n\
00197 # length := dimensions[1]\n\
00198 # the length is along the Z axis\n\
00199 \n\
00200 # for box\n\
00201 # size_x := dimensions[0]\n\
00202 # size_y := dimensions[1]\n\
00203 # size_z := dimensions[2]\n\
00204 float64[] dimensions\n\
00205 \n\
00206 \n\
00207 #### define mesh ####\n\
00208 \n\
00209 # list of triangles; triangle k is defined by tre vertices located\n\
00210 # at indices triangles[3k], triangles[3k+1], triangles[3k+2]\n\
00211 int32[] triangles\n\
00212 geometry_msgs/Point[] vertices\n\
00213 \n\
00214 ================================================================================\n\
00215 MSG: geometry_msgs/Point\n\
00216 # This contains the position of a point in free space\n\
00217 float64 x\n\
00218 float64 y\n\
00219 float64 z\n\
00220 \n\
00221 ================================================================================\n\
00222 MSG: geometry_msgs/Pose\n\
00223 # A representation of pose in free space, composed of postion and orientation. \n\
00224 Point position\n\
00225 Quaternion orientation\n\
00226 \n\
00227 ================================================================================\n\
00228 MSG: geometry_msgs/Quaternion\n\
00229 # This represents an orientation in free space in quaternion form.\n\
00230 \n\
00231 float64 x\n\
00232 float64 y\n\
00233 float64 z\n\
00234 float64 w\n\
00235 \n\
00236 ";
00237 }
00238
00239 static const char* value(const ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> &) { return value(); }
00240 };
00241
00242 template<class ContainerAllocator> struct HasHeader< ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> > : public TrueType {};
00243 template<class ContainerAllocator> struct HasHeader< const ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> > : public TrueType {};
00244 }
00245 }
00246
00247 namespace ros
00248 {
00249 namespace serialization
00250 {
00251
00252 template<class ContainerAllocator> struct Serializer< ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> >
00253 {
00254 template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
00255 {
00256 stream.next(m.header);
00257 stream.next(m.id);
00258 stream.next(m.padding);
00259 stream.next(m.operation);
00260 stream.next(m.shapes);
00261 stream.next(m.poses);
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< ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> >
00276 {
00277 template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::arm_navigation_msgs::CollisionObject_<ContainerAllocator> & v)
00278 {
00279 s << indent << "header: ";
00280 s << std::endl;
00281 Printer< ::std_msgs::Header_<ContainerAllocator> >::stream(s, indent + " ", v.header);
00282 s << indent << "id: ";
00283 Printer<std::basic_string<char, std::char_traits<char>, typename ContainerAllocator::template rebind<char>::other > >::stream(s, indent + " ", v.id);
00284 s << indent << "padding: ";
00285 Printer<float>::stream(s, indent + " ", v.padding);
00286 s << indent << "operation: ";
00287 s << std::endl;
00288 Printer< ::arm_navigation_msgs::CollisionObjectOperation_<ContainerAllocator> >::stream(s, indent + " ", v.operation);
00289 s << indent << "shapes[]" << std::endl;
00290 for (size_t i = 0; i < v.shapes.size(); ++i)
00291 {
00292 s << indent << " shapes[" << i << "]: ";
00293 s << std::endl;
00294 s << indent;
00295 Printer< ::arm_navigation_msgs::Shape_<ContainerAllocator> >::stream(s, indent + " ", v.shapes[i]);
00296 }
00297 s << indent << "poses[]" << std::endl;
00298 for (size_t i = 0; i < v.poses.size(); ++i)
00299 {
00300 s << indent << " poses[" << i << "]: ";
00301 s << std::endl;
00302 s << indent;
00303 Printer< ::geometry_msgs::Pose_<ContainerAllocator> >::stream(s, indent + " ", v.poses[i]);
00304 }
00305 }
00306 };
00307
00308
00309 }
00310 }
00311
00312 #endif // ARM_NAVIGATION_MSGS_MESSAGE_COLLISIONOBJECT_H
00313