$search
00001 """autogenerated by genmsg_py from GraspHandPostureExecutionActionResult.msg. Do not edit.""" 00002 import roslib.message 00003 import struct 00004 00005 import object_manipulation_msgs.msg 00006 import roslib.rostime 00007 import actionlib_msgs.msg 00008 import std_msgs.msg 00009 00010 class GraspHandPostureExecutionActionResult(roslib.message.Message): 00011 _md5sum = "6434d1842053adb9e907efbf917fa72b" 00012 _type = "object_manipulation_msgs/GraspHandPostureExecutionActionResult" 00013 _has_header = True #flag to mark the presence of a Header object 00014 _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== 00015 00016 Header header 00017 actionlib_msgs/GoalStatus status 00018 GraspHandPostureExecutionResult result 00019 00020 ================================================================================ 00021 MSG: std_msgs/Header 00022 # Standard metadata for higher-level stamped data types. 00023 # This is generally used to communicate timestamped data 00024 # in a particular coordinate frame. 00025 # 00026 # sequence ID: consecutively increasing ID 00027 uint32 seq 00028 #Two-integer timestamp that is expressed as: 00029 # * stamp.secs: seconds (stamp_secs) since epoch 00030 # * stamp.nsecs: nanoseconds since stamp_secs 00031 # time-handling sugar is provided by the client library 00032 time stamp 00033 #Frame this data is associated with 00034 # 0: no frame 00035 # 1: global frame 00036 string frame_id 00037 00038 ================================================================================ 00039 MSG: actionlib_msgs/GoalStatus 00040 GoalID goal_id 00041 uint8 status 00042 uint8 PENDING = 0 # The goal has yet to be processed by the action server 00043 uint8 ACTIVE = 1 # The goal is currently being processed by the action server 00044 uint8 PREEMPTED = 2 # The goal received a cancel request after it started executing 00045 # and has since completed its execution (Terminal State) 00046 uint8 SUCCEEDED = 3 # The goal was achieved successfully by the action server (Terminal State) 00047 uint8 ABORTED = 4 # The goal was aborted during execution by the action server due 00048 # to some failure (Terminal State) 00049 uint8 REJECTED = 5 # The goal was rejected by the action server without being processed, 00050 # because the goal was unattainable or invalid (Terminal State) 00051 uint8 PREEMPTING = 6 # The goal received a cancel request after it started executing 00052 # and has not yet completed execution 00053 uint8 RECALLING = 7 # The goal received a cancel request before it started executing, 00054 # but the action server has not yet confirmed that the goal is canceled 00055 uint8 RECALLED = 8 # The goal received a cancel request before it started executing 00056 # and was successfully cancelled (Terminal State) 00057 uint8 LOST = 9 # An action client can determine that a goal is LOST. This should not be 00058 # sent over the wire by an action server 00059 00060 #Allow for the user to associate a string with GoalStatus for debugging 00061 string text 00062 00063 00064 ================================================================================ 00065 MSG: actionlib_msgs/GoalID 00066 # The stamp should store the time at which this goal was requested. 00067 # It is used by an action server when it tries to preempt all 00068 # goals that were requested before a certain time 00069 time stamp 00070 00071 # The id provides a way to associate feedback and 00072 # result message with specific goal requests. The id 00073 # specified must be unique. 00074 string id 00075 00076 00077 ================================================================================ 00078 MSG: object_manipulation_msgs/GraspHandPostureExecutionResult 00079 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== 00080 # the result of the action 00081 ManipulationResult result 00082 00083 00084 ================================================================================ 00085 MSG: object_manipulation_msgs/ManipulationResult 00086 # Result codes for manipulation tasks 00087 00088 # task completed as expected 00089 # generally means you can proceed as planned 00090 int32 SUCCESS = 1 00091 00092 # task not possible (e.g. out of reach or obstacles in the way) 00093 # generally means that the world was not disturbed, so you can try another task 00094 int32 UNFEASIBLE = -1 00095 00096 # task was thought possible, but failed due to unexpected events during execution 00097 # it is likely that the world was disturbed, so you are encouraged to refresh 00098 # your sensed world model before proceeding to another task 00099 int32 FAILED = -2 00100 00101 # a lower level error prevented task completion (e.g. joint controller not responding) 00102 # generally requires human attention 00103 int32 ERROR = -3 00104 00105 # means that at some point during execution we ended up in a state that the collision-aware 00106 # arm navigation module will not move out of. The world was likely not disturbed, but you 00107 # probably need a new collision map to move the arm out of the stuck position 00108 int32 ARM_MOVEMENT_PREVENTED = -4 00109 00110 # specific to grasp actions 00111 # the object was grasped successfully, but the lift attempt could not achieve the minimum lift distance requested 00112 # it is likely that the collision environment will see collisions between the hand/object and the support surface 00113 int32 LIFT_FAILED = -5 00114 00115 # specific to place actions 00116 # the object was placed successfully, but the retreat attempt could not achieve the minimum retreat distance requested 00117 # it is likely that the collision environment will see collisions between the hand and the object 00118 int32 RETREAT_FAILED = -6 00119 00120 # indicates that somewhere along the line a human said "wait, stop, this is bad, go back and do something else" 00121 int32 CANCELLED = -7 00122 00123 # the actual value of this error code 00124 int32 value 00125 00126 """ 00127 __slots__ = ['header','status','result'] 00128 _slot_types = ['Header','actionlib_msgs/GoalStatus','object_manipulation_msgs/GraspHandPostureExecutionResult'] 00129 00130 def __init__(self, *args, **kwds): 00131 """ 00132 Constructor. Any message fields that are implicitly/explicitly 00133 set to None will be assigned a default value. The recommend 00134 use is keyword arguments as this is more robust to future message 00135 changes. You cannot mix in-order arguments and keyword arguments. 00136 00137 The available fields are: 00138 header,status,result 00139 00140 @param args: complete set of field values, in .msg order 00141 @param kwds: use keyword arguments corresponding to message field names 00142 to set specific fields. 00143 """ 00144 if args or kwds: 00145 super(GraspHandPostureExecutionActionResult, self).__init__(*args, **kwds) 00146 #message fields cannot be None, assign default values for those that are 00147 if self.header is None: 00148 self.header = std_msgs.msg._Header.Header() 00149 if self.status is None: 00150 self.status = actionlib_msgs.msg.GoalStatus() 00151 if self.result is None: 00152 self.result = object_manipulation_msgs.msg.GraspHandPostureExecutionResult() 00153 else: 00154 self.header = std_msgs.msg._Header.Header() 00155 self.status = actionlib_msgs.msg.GoalStatus() 00156 self.result = object_manipulation_msgs.msg.GraspHandPostureExecutionResult() 00157 00158 def _get_types(self): 00159 """ 00160 internal API method 00161 """ 00162 return self._slot_types 00163 00164 def serialize(self, buff): 00165 """ 00166 serialize message into buffer 00167 @param buff: buffer 00168 @type buff: StringIO 00169 """ 00170 try: 00171 _x = self 00172 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs)) 00173 _x = self.header.frame_id 00174 length = len(_x) 00175 buff.write(struct.pack('<I%ss'%length, length, _x)) 00176 _x = self 00177 buff.write(_struct_2I.pack(_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs)) 00178 _x = self.status.goal_id.id 00179 length = len(_x) 00180 buff.write(struct.pack('<I%ss'%length, length, _x)) 00181 buff.write(_struct_B.pack(self.status.status)) 00182 _x = self.status.text 00183 length = len(_x) 00184 buff.write(struct.pack('<I%ss'%length, length, _x)) 00185 buff.write(_struct_i.pack(self.result.result.value)) 00186 except struct.error as se: self._check_types(se) 00187 except TypeError as te: self._check_types(te) 00188 00189 def deserialize(self, str): 00190 """ 00191 unpack serialized message in str into this message instance 00192 @param str: byte array of serialized message 00193 @type str: str 00194 """ 00195 try: 00196 if self.header is None: 00197 self.header = std_msgs.msg._Header.Header() 00198 if self.status is None: 00199 self.status = actionlib_msgs.msg.GoalStatus() 00200 if self.result is None: 00201 self.result = object_manipulation_msgs.msg.GraspHandPostureExecutionResult() 00202 end = 0 00203 _x = self 00204 start = end 00205 end += 12 00206 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00207 start = end 00208 end += 4 00209 (length,) = _struct_I.unpack(str[start:end]) 00210 start = end 00211 end += length 00212 self.header.frame_id = str[start:end] 00213 _x = self 00214 start = end 00215 end += 8 00216 (_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end]) 00217 start = end 00218 end += 4 00219 (length,) = _struct_I.unpack(str[start:end]) 00220 start = end 00221 end += length 00222 self.status.goal_id.id = str[start:end] 00223 start = end 00224 end += 1 00225 (self.status.status,) = _struct_B.unpack(str[start:end]) 00226 start = end 00227 end += 4 00228 (length,) = _struct_I.unpack(str[start:end]) 00229 start = end 00230 end += length 00231 self.status.text = str[start:end] 00232 start = end 00233 end += 4 00234 (self.result.result.value,) = _struct_i.unpack(str[start:end]) 00235 return self 00236 except struct.error as e: 00237 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00238 00239 00240 def serialize_numpy(self, buff, numpy): 00241 """ 00242 serialize message with numpy array types into buffer 00243 @param buff: buffer 00244 @type buff: StringIO 00245 @param numpy: numpy python module 00246 @type numpy module 00247 """ 00248 try: 00249 _x = self 00250 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs)) 00251 _x = self.header.frame_id 00252 length = len(_x) 00253 buff.write(struct.pack('<I%ss'%length, length, _x)) 00254 _x = self 00255 buff.write(_struct_2I.pack(_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs)) 00256 _x = self.status.goal_id.id 00257 length = len(_x) 00258 buff.write(struct.pack('<I%ss'%length, length, _x)) 00259 buff.write(_struct_B.pack(self.status.status)) 00260 _x = self.status.text 00261 length = len(_x) 00262 buff.write(struct.pack('<I%ss'%length, length, _x)) 00263 buff.write(_struct_i.pack(self.result.result.value)) 00264 except struct.error as se: self._check_types(se) 00265 except TypeError as te: self._check_types(te) 00266 00267 def deserialize_numpy(self, str, numpy): 00268 """ 00269 unpack serialized message in str into this message instance using numpy for array types 00270 @param str: byte array of serialized message 00271 @type str: str 00272 @param numpy: numpy python module 00273 @type numpy: module 00274 """ 00275 try: 00276 if self.header is None: 00277 self.header = std_msgs.msg._Header.Header() 00278 if self.status is None: 00279 self.status = actionlib_msgs.msg.GoalStatus() 00280 if self.result is None: 00281 self.result = object_manipulation_msgs.msg.GraspHandPostureExecutionResult() 00282 end = 0 00283 _x = self 00284 start = end 00285 end += 12 00286 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00287 start = end 00288 end += 4 00289 (length,) = _struct_I.unpack(str[start:end]) 00290 start = end 00291 end += length 00292 self.header.frame_id = str[start:end] 00293 _x = self 00294 start = end 00295 end += 8 00296 (_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end]) 00297 start = end 00298 end += 4 00299 (length,) = _struct_I.unpack(str[start:end]) 00300 start = end 00301 end += length 00302 self.status.goal_id.id = str[start:end] 00303 start = end 00304 end += 1 00305 (self.status.status,) = _struct_B.unpack(str[start:end]) 00306 start = end 00307 end += 4 00308 (length,) = _struct_I.unpack(str[start:end]) 00309 start = end 00310 end += length 00311 self.status.text = str[start:end] 00312 start = end 00313 end += 4 00314 (self.result.result.value,) = _struct_i.unpack(str[start:end]) 00315 return self 00316 except struct.error as e: 00317 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00318 00319 _struct_I = roslib.message.struct_I 00320 _struct_i = struct.Struct("<i") 00321 _struct_3I = struct.Struct("<3I") 00322 _struct_B = struct.Struct("<B") 00323 _struct_2I = struct.Struct("<2I")