00001
00002 #ifndef OBJECT_MANIPULATION_MSGS_MESSAGE_PLACERESULT_H
00003 #define OBJECT_MANIPULATION_MSGS_MESSAGE_PLACERESULT_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 "object_manipulation_msgs/ManipulationResult.h"
00018 #include "geometry_msgs/PoseStamped.h"
00019 #include "geometry_msgs/PoseStamped.h"
00020 #include "object_manipulation_msgs/PlaceLocationResult.h"
00021
00022 namespace object_manipulation_msgs
00023 {
00024 template <class ContainerAllocator>
00025 struct PlaceResult_ {
00026 typedef PlaceResult_<ContainerAllocator> Type;
00027
00028 PlaceResult_()
00029 : manipulation_result()
00030 , place_location()
00031 , attempted_locations()
00032 , attempted_location_results()
00033 {
00034 }
00035
00036 PlaceResult_(const ContainerAllocator& _alloc)
00037 : manipulation_result(_alloc)
00038 , place_location(_alloc)
00039 , attempted_locations(_alloc)
00040 , attempted_location_results(_alloc)
00041 {
00042 }
00043
00044 typedef ::object_manipulation_msgs::ManipulationResult_<ContainerAllocator> _manipulation_result_type;
00045 ::object_manipulation_msgs::ManipulationResult_<ContainerAllocator> manipulation_result;
00046
00047 typedef ::geometry_msgs::PoseStamped_<ContainerAllocator> _place_location_type;
00048 ::geometry_msgs::PoseStamped_<ContainerAllocator> place_location;
00049
00050 typedef std::vector< ::geometry_msgs::PoseStamped_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::geometry_msgs::PoseStamped_<ContainerAllocator> >::other > _attempted_locations_type;
00051 std::vector< ::geometry_msgs::PoseStamped_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::geometry_msgs::PoseStamped_<ContainerAllocator> >::other > attempted_locations;
00052
00053 typedef std::vector< ::object_manipulation_msgs::PlaceLocationResult_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::object_manipulation_msgs::PlaceLocationResult_<ContainerAllocator> >::other > _attempted_location_results_type;
00054 std::vector< ::object_manipulation_msgs::PlaceLocationResult_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::object_manipulation_msgs::PlaceLocationResult_<ContainerAllocator> >::other > attempted_location_results;
00055
00056
00057 ROS_DEPRECATED uint32_t get_attempted_locations_size() const { return (uint32_t)attempted_locations.size(); }
00058 ROS_DEPRECATED void set_attempted_locations_size(uint32_t size) { attempted_locations.resize((size_t)size); }
00059 ROS_DEPRECATED void get_attempted_locations_vec(std::vector< ::geometry_msgs::PoseStamped_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::geometry_msgs::PoseStamped_<ContainerAllocator> >::other > & vec) const { vec = this->attempted_locations; }
00060 ROS_DEPRECATED void set_attempted_locations_vec(const std::vector< ::geometry_msgs::PoseStamped_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::geometry_msgs::PoseStamped_<ContainerAllocator> >::other > & vec) { this->attempted_locations = vec; }
00061 ROS_DEPRECATED uint32_t get_attempted_location_results_size() const { return (uint32_t)attempted_location_results.size(); }
00062 ROS_DEPRECATED void set_attempted_location_results_size(uint32_t size) { attempted_location_results.resize((size_t)size); }
00063 ROS_DEPRECATED void get_attempted_location_results_vec(std::vector< ::object_manipulation_msgs::PlaceLocationResult_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::object_manipulation_msgs::PlaceLocationResult_<ContainerAllocator> >::other > & vec) const { vec = this->attempted_location_results; }
00064 ROS_DEPRECATED void set_attempted_location_results_vec(const std::vector< ::object_manipulation_msgs::PlaceLocationResult_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::object_manipulation_msgs::PlaceLocationResult_<ContainerAllocator> >::other > & vec) { this->attempted_location_results = vec; }
00065 private:
00066 static const char* __s_getDataType_() { return "object_manipulation_msgs/PlaceResult"; }
00067 public:
00068 ROS_DEPRECATED static const std::string __s_getDataType() { return __s_getDataType_(); }
00069
00070 ROS_DEPRECATED const std::string __getDataType() const { return __s_getDataType_(); }
00071
00072 private:
00073 static const char* __s_getMD5Sum_() { return "531ddb04b8422b6734fb74421d431059"; }
00074 public:
00075 ROS_DEPRECATED static const std::string __s_getMD5Sum() { return __s_getMD5Sum_(); }
00076
00077 ROS_DEPRECATED const std::string __getMD5Sum() const { return __s_getMD5Sum_(); }
00078
00079 private:
00080 static const char* __s_getMessageDefinition_() { return "# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======\n\
00081 \n\
00082 # The result of the pickup attempt\n\
00083 ManipulationResult manipulation_result\n\
00084 \n\
00085 # The successful place location, if any\n\
00086 geometry_msgs/PoseStamped place_location\n\
00087 \n\
00088 # the list of attempted locations, in the order in which they were attempted\n\
00089 # the successful one should be the last one in this list\n\
00090 geometry_msgs/PoseStamped[] attempted_locations\n\
00091 \n\
00092 # the outcomes of the attempted locations, in the same order as attempted_locations\n\
00093 PlaceLocationResult[] attempted_location_results\n\
00094 \n\
00095 \n\
00096 ================================================================================\n\
00097 MSG: object_manipulation_msgs/ManipulationResult\n\
00098 # Result codes for manipulation tasks\n\
00099 \n\
00100 # task completed as expected\n\
00101 # generally means you can proceed as planned\n\
00102 int32 SUCCESS = 1\n\
00103 \n\
00104 # task not possible (e.g. out of reach or obstacles in the way)\n\
00105 # generally means that the world was not disturbed, so you can try another task\n\
00106 int32 UNFEASIBLE = -1\n\
00107 \n\
00108 # task was thought possible, but failed due to unexpected events during execution\n\
00109 # it is likely that the world was disturbed, so you are encouraged to refresh\n\
00110 # your sensed world model before proceeding to another task\n\
00111 int32 FAILED = -2\n\
00112 \n\
00113 # a lower level error prevented task completion (e.g. joint controller not responding)\n\
00114 # generally requires human attention\n\
00115 int32 ERROR = -3\n\
00116 \n\
00117 # means that at some point during execution we ended up in a state that the collision-aware\n\
00118 # arm navigation module will not move out of. The world was likely not disturbed, but you \n\
00119 # probably need a new collision map to move the arm out of the stuck position\n\
00120 int32 ARM_MOVEMENT_PREVENTED = -4\n\
00121 \n\
00122 # specific to grasp actions\n\
00123 # the object was grasped successfully, but the lift attempt could not achieve the minimum lift distance requested\n\
00124 # it is likely that the collision environment will see collisions between the hand/object and the support surface\n\
00125 int32 LIFT_FAILED = -5\n\
00126 \n\
00127 # specific to place actions\n\
00128 # the object was placed successfully, but the retreat attempt could not achieve the minimum retreat distance requested\n\
00129 # it is likely that the collision environment will see collisions between the hand and the object\n\
00130 int32 RETREAT_FAILED = -6\n\
00131 \n\
00132 # indicates that somewhere along the line a human said \"wait, stop, this is bad, go back and do something else\"\n\
00133 int32 CANCELLED = -7\n\
00134 \n\
00135 # the actual value of this error code\n\
00136 int32 value\n\
00137 \n\
00138 ================================================================================\n\
00139 MSG: geometry_msgs/PoseStamped\n\
00140 # A Pose with reference coordinate frame and timestamp\n\
00141 Header header\n\
00142 Pose pose\n\
00143 \n\
00144 ================================================================================\n\
00145 MSG: std_msgs/Header\n\
00146 # Standard metadata for higher-level stamped data types.\n\
00147 # This is generally used to communicate timestamped data \n\
00148 # in a particular coordinate frame.\n\
00149 # \n\
00150 # sequence ID: consecutively increasing ID \n\
00151 uint32 seq\n\
00152 #Two-integer timestamp that is expressed as:\n\
00153 # * stamp.secs: seconds (stamp_secs) since epoch\n\
00154 # * stamp.nsecs: nanoseconds since stamp_secs\n\
00155 # time-handling sugar is provided by the client library\n\
00156 time stamp\n\
00157 #Frame this data is associated with\n\
00158 # 0: no frame\n\
00159 # 1: global frame\n\
00160 string frame_id\n\
00161 \n\
00162 ================================================================================\n\
00163 MSG: geometry_msgs/Pose\n\
00164 # A representation of pose in free space, composed of postion and orientation. \n\
00165 Point position\n\
00166 Quaternion orientation\n\
00167 \n\
00168 ================================================================================\n\
00169 MSG: geometry_msgs/Point\n\
00170 # This contains the position of a point in free space\n\
00171 float64 x\n\
00172 float64 y\n\
00173 float64 z\n\
00174 \n\
00175 ================================================================================\n\
00176 MSG: geometry_msgs/Quaternion\n\
00177 # This represents an orientation in free space in quaternion form.\n\
00178 \n\
00179 float64 x\n\
00180 float64 y\n\
00181 float64 z\n\
00182 float64 w\n\
00183 \n\
00184 ================================================================================\n\
00185 MSG: object_manipulation_msgs/PlaceLocationResult\n\
00186 int32 SUCCESS = 1\n\
00187 int32 PLACE_OUT_OF_REACH = 2\n\
00188 int32 PLACE_IN_COLLISION = 3\n\
00189 int32 PLACE_UNFEASIBLE = 4\n\
00190 int32 PREPLACE_OUT_OF_REACH = 5\n\
00191 int32 PREPLACE_IN_COLLISION = 6\n\
00192 int32 PREPLACE_UNFEASIBLE = 7\n\
00193 int32 RETREAT_OUT_OF_REACH = 8\n\
00194 int32 RETREAT_IN_COLLISION = 9\n\
00195 int32 RETREAT_UNFEASIBLE = 10\n\
00196 int32 MOVE_ARM_FAILED = 11\n\
00197 int32 PLACE_FAILED = 12\n\
00198 int32 RETREAT_FAILED = 13\n\
00199 int32 result_code\n\
00200 \n\
00201 # whether the state of the world was disturbed by this attempt. generally, this flag\n\
00202 # shows if another task can be attempted, or a new sensed world model is recommeded\n\
00203 # before proceeding\n\
00204 bool continuation_possible\n\
00205 \n\
00206 "; }
00207 public:
00208 ROS_DEPRECATED static const std::string __s_getMessageDefinition() { return __s_getMessageDefinition_(); }
00209
00210 ROS_DEPRECATED const std::string __getMessageDefinition() const { return __s_getMessageDefinition_(); }
00211
00212 ROS_DEPRECATED virtual uint8_t *serialize(uint8_t *write_ptr, uint32_t seq) const
00213 {
00214 ros::serialization::OStream stream(write_ptr, 1000000000);
00215 ros::serialization::serialize(stream, manipulation_result);
00216 ros::serialization::serialize(stream, place_location);
00217 ros::serialization::serialize(stream, attempted_locations);
00218 ros::serialization::serialize(stream, attempted_location_results);
00219 return stream.getData();
00220 }
00221
00222 ROS_DEPRECATED virtual uint8_t *deserialize(uint8_t *read_ptr)
00223 {
00224 ros::serialization::IStream stream(read_ptr, 1000000000);
00225 ros::serialization::deserialize(stream, manipulation_result);
00226 ros::serialization::deserialize(stream, place_location);
00227 ros::serialization::deserialize(stream, attempted_locations);
00228 ros::serialization::deserialize(stream, attempted_location_results);
00229 return stream.getData();
00230 }
00231
00232 ROS_DEPRECATED virtual uint32_t serializationLength() const
00233 {
00234 uint32_t size = 0;
00235 size += ros::serialization::serializationLength(manipulation_result);
00236 size += ros::serialization::serializationLength(place_location);
00237 size += ros::serialization::serializationLength(attempted_locations);
00238 size += ros::serialization::serializationLength(attempted_location_results);
00239 return size;
00240 }
00241
00242 typedef boost::shared_ptr< ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> > Ptr;
00243 typedef boost::shared_ptr< ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> const> ConstPtr;
00244 boost::shared_ptr<std::map<std::string, std::string> > __connection_header;
00245 };
00246 typedef ::object_manipulation_msgs::PlaceResult_<std::allocator<void> > PlaceResult;
00247
00248 typedef boost::shared_ptr< ::object_manipulation_msgs::PlaceResult> PlaceResultPtr;
00249 typedef boost::shared_ptr< ::object_manipulation_msgs::PlaceResult const> PlaceResultConstPtr;
00250
00251
00252 template<typename ContainerAllocator>
00253 std::ostream& operator<<(std::ostream& s, const ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> & v)
00254 {
00255 ros::message_operations::Printer< ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> >::stream(s, "", v);
00256 return s;}
00257
00258 }
00259
00260 namespace ros
00261 {
00262 namespace message_traits
00263 {
00264 template<class ContainerAllocator> struct IsMessage< ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> > : public TrueType {};
00265 template<class ContainerAllocator> struct IsMessage< ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> const> : public TrueType {};
00266 template<class ContainerAllocator>
00267 struct MD5Sum< ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> > {
00268 static const char* value()
00269 {
00270 return "531ddb04b8422b6734fb74421d431059";
00271 }
00272
00273 static const char* value(const ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> &) { return value(); }
00274 static const uint64_t static_value1 = 0x531ddb04b8422b67ULL;
00275 static const uint64_t static_value2 = 0x34fb74421d431059ULL;
00276 };
00277
00278 template<class ContainerAllocator>
00279 struct DataType< ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> > {
00280 static const char* value()
00281 {
00282 return "object_manipulation_msgs/PlaceResult";
00283 }
00284
00285 static const char* value(const ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> &) { return value(); }
00286 };
00287
00288 template<class ContainerAllocator>
00289 struct Definition< ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> > {
00290 static const char* value()
00291 {
00292 return "# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======\n\
00293 \n\
00294 # The result of the pickup attempt\n\
00295 ManipulationResult manipulation_result\n\
00296 \n\
00297 # The successful place location, if any\n\
00298 geometry_msgs/PoseStamped place_location\n\
00299 \n\
00300 # the list of attempted locations, in the order in which they were attempted\n\
00301 # the successful one should be the last one in this list\n\
00302 geometry_msgs/PoseStamped[] attempted_locations\n\
00303 \n\
00304 # the outcomes of the attempted locations, in the same order as attempted_locations\n\
00305 PlaceLocationResult[] attempted_location_results\n\
00306 \n\
00307 \n\
00308 ================================================================================\n\
00309 MSG: object_manipulation_msgs/ManipulationResult\n\
00310 # Result codes for manipulation tasks\n\
00311 \n\
00312 # task completed as expected\n\
00313 # generally means you can proceed as planned\n\
00314 int32 SUCCESS = 1\n\
00315 \n\
00316 # task not possible (e.g. out of reach or obstacles in the way)\n\
00317 # generally means that the world was not disturbed, so you can try another task\n\
00318 int32 UNFEASIBLE = -1\n\
00319 \n\
00320 # task was thought possible, but failed due to unexpected events during execution\n\
00321 # it is likely that the world was disturbed, so you are encouraged to refresh\n\
00322 # your sensed world model before proceeding to another task\n\
00323 int32 FAILED = -2\n\
00324 \n\
00325 # a lower level error prevented task completion (e.g. joint controller not responding)\n\
00326 # generally requires human attention\n\
00327 int32 ERROR = -3\n\
00328 \n\
00329 # means that at some point during execution we ended up in a state that the collision-aware\n\
00330 # arm navigation module will not move out of. The world was likely not disturbed, but you \n\
00331 # probably need a new collision map to move the arm out of the stuck position\n\
00332 int32 ARM_MOVEMENT_PREVENTED = -4\n\
00333 \n\
00334 # specific to grasp actions\n\
00335 # the object was grasped successfully, but the lift attempt could not achieve the minimum lift distance requested\n\
00336 # it is likely that the collision environment will see collisions between the hand/object and the support surface\n\
00337 int32 LIFT_FAILED = -5\n\
00338 \n\
00339 # specific to place actions\n\
00340 # the object was placed successfully, but the retreat attempt could not achieve the minimum retreat distance requested\n\
00341 # it is likely that the collision environment will see collisions between the hand and the object\n\
00342 int32 RETREAT_FAILED = -6\n\
00343 \n\
00344 # indicates that somewhere along the line a human said \"wait, stop, this is bad, go back and do something else\"\n\
00345 int32 CANCELLED = -7\n\
00346 \n\
00347 # the actual value of this error code\n\
00348 int32 value\n\
00349 \n\
00350 ================================================================================\n\
00351 MSG: geometry_msgs/PoseStamped\n\
00352 # A Pose with reference coordinate frame and timestamp\n\
00353 Header header\n\
00354 Pose pose\n\
00355 \n\
00356 ================================================================================\n\
00357 MSG: std_msgs/Header\n\
00358 # Standard metadata for higher-level stamped data types.\n\
00359 # This is generally used to communicate timestamped data \n\
00360 # in a particular coordinate frame.\n\
00361 # \n\
00362 # sequence ID: consecutively increasing ID \n\
00363 uint32 seq\n\
00364 #Two-integer timestamp that is expressed as:\n\
00365 # * stamp.secs: seconds (stamp_secs) since epoch\n\
00366 # * stamp.nsecs: nanoseconds since stamp_secs\n\
00367 # time-handling sugar is provided by the client library\n\
00368 time stamp\n\
00369 #Frame this data is associated with\n\
00370 # 0: no frame\n\
00371 # 1: global frame\n\
00372 string frame_id\n\
00373 \n\
00374 ================================================================================\n\
00375 MSG: geometry_msgs/Pose\n\
00376 # A representation of pose in free space, composed of postion and orientation. \n\
00377 Point position\n\
00378 Quaternion orientation\n\
00379 \n\
00380 ================================================================================\n\
00381 MSG: geometry_msgs/Point\n\
00382 # This contains the position of a point in free space\n\
00383 float64 x\n\
00384 float64 y\n\
00385 float64 z\n\
00386 \n\
00387 ================================================================================\n\
00388 MSG: geometry_msgs/Quaternion\n\
00389 # This represents an orientation in free space in quaternion form.\n\
00390 \n\
00391 float64 x\n\
00392 float64 y\n\
00393 float64 z\n\
00394 float64 w\n\
00395 \n\
00396 ================================================================================\n\
00397 MSG: object_manipulation_msgs/PlaceLocationResult\n\
00398 int32 SUCCESS = 1\n\
00399 int32 PLACE_OUT_OF_REACH = 2\n\
00400 int32 PLACE_IN_COLLISION = 3\n\
00401 int32 PLACE_UNFEASIBLE = 4\n\
00402 int32 PREPLACE_OUT_OF_REACH = 5\n\
00403 int32 PREPLACE_IN_COLLISION = 6\n\
00404 int32 PREPLACE_UNFEASIBLE = 7\n\
00405 int32 RETREAT_OUT_OF_REACH = 8\n\
00406 int32 RETREAT_IN_COLLISION = 9\n\
00407 int32 RETREAT_UNFEASIBLE = 10\n\
00408 int32 MOVE_ARM_FAILED = 11\n\
00409 int32 PLACE_FAILED = 12\n\
00410 int32 RETREAT_FAILED = 13\n\
00411 int32 result_code\n\
00412 \n\
00413 # whether the state of the world was disturbed by this attempt. generally, this flag\n\
00414 # shows if another task can be attempted, or a new sensed world model is recommeded\n\
00415 # before proceeding\n\
00416 bool continuation_possible\n\
00417 \n\
00418 ";
00419 }
00420
00421 static const char* value(const ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> &) { return value(); }
00422 };
00423
00424 }
00425 }
00426
00427 namespace ros
00428 {
00429 namespace serialization
00430 {
00431
00432 template<class ContainerAllocator> struct Serializer< ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> >
00433 {
00434 template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
00435 {
00436 stream.next(m.manipulation_result);
00437 stream.next(m.place_location);
00438 stream.next(m.attempted_locations);
00439 stream.next(m.attempted_location_results);
00440 }
00441
00442 ROS_DECLARE_ALLINONE_SERIALIZER;
00443 };
00444 }
00445 }
00446
00447 namespace ros
00448 {
00449 namespace message_operations
00450 {
00451
00452 template<class ContainerAllocator>
00453 struct Printer< ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> >
00454 {
00455 template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::object_manipulation_msgs::PlaceResult_<ContainerAllocator> & v)
00456 {
00457 s << indent << "manipulation_result: ";
00458 s << std::endl;
00459 Printer< ::object_manipulation_msgs::ManipulationResult_<ContainerAllocator> >::stream(s, indent + " ", v.manipulation_result);
00460 s << indent << "place_location: ";
00461 s << std::endl;
00462 Printer< ::geometry_msgs::PoseStamped_<ContainerAllocator> >::stream(s, indent + " ", v.place_location);
00463 s << indent << "attempted_locations[]" << std::endl;
00464 for (size_t i = 0; i < v.attempted_locations.size(); ++i)
00465 {
00466 s << indent << " attempted_locations[" << i << "]: ";
00467 s << std::endl;
00468 s << indent;
00469 Printer< ::geometry_msgs::PoseStamped_<ContainerAllocator> >::stream(s, indent + " ", v.attempted_locations[i]);
00470 }
00471 s << indent << "attempted_location_results[]" << std::endl;
00472 for (size_t i = 0; i < v.attempted_location_results.size(); ++i)
00473 {
00474 s << indent << " attempted_location_results[" << i << "]: ";
00475 s << std::endl;
00476 s << indent;
00477 Printer< ::object_manipulation_msgs::PlaceLocationResult_<ContainerAllocator> >::stream(s, indent + " ", v.attempted_location_results[i]);
00478 }
00479 }
00480 };
00481
00482
00483 }
00484 }
00485
00486 #endif // OBJECT_MANIPULATION_MSGS_MESSAGE_PLACERESULT_H
00487