$search
00001 """autogenerated by genmsg_py from MoveBaseActionResult.msg. Do not edit.""" 00002 import roslib.message 00003 import struct 00004 00005 import move_base_msgs.msg 00006 import roslib.rostime 00007 import actionlib_msgs.msg 00008 import std_msgs.msg 00009 00010 class MoveBaseActionResult(roslib.message.Message): 00011 _md5sum = "1eb06eeff08fa7ea874431638cb52332" 00012 _type = "move_base_msgs/MoveBaseActionResult" 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 MoveBaseResult 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: move_base_msgs/MoveBaseResult 00079 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== 00080 00081 """ 00082 __slots__ = ['header','status','result'] 00083 _slot_types = ['Header','actionlib_msgs/GoalStatus','move_base_msgs/MoveBaseResult'] 00084 00085 def __init__(self, *args, **kwds): 00086 """ 00087 Constructor. Any message fields that are implicitly/explicitly 00088 set to None will be assigned a default value. The recommend 00089 use is keyword arguments as this is more robust to future message 00090 changes. You cannot mix in-order arguments and keyword arguments. 00091 00092 The available fields are: 00093 header,status,result 00094 00095 @param args: complete set of field values, in .msg order 00096 @param kwds: use keyword arguments corresponding to message field names 00097 to set specific fields. 00098 """ 00099 if args or kwds: 00100 super(MoveBaseActionResult, self).__init__(*args, **kwds) 00101 #message fields cannot be None, assign default values for those that are 00102 if self.header is None: 00103 self.header = std_msgs.msg._Header.Header() 00104 if self.status is None: 00105 self.status = actionlib_msgs.msg.GoalStatus() 00106 if self.result is None: 00107 self.result = move_base_msgs.msg.MoveBaseResult() 00108 else: 00109 self.header = std_msgs.msg._Header.Header() 00110 self.status = actionlib_msgs.msg.GoalStatus() 00111 self.result = move_base_msgs.msg.MoveBaseResult() 00112 00113 def _get_types(self): 00114 """ 00115 internal API method 00116 """ 00117 return self._slot_types 00118 00119 def serialize(self, buff): 00120 """ 00121 serialize message into buffer 00122 @param buff: buffer 00123 @type buff: StringIO 00124 """ 00125 try: 00126 _x = self 00127 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs)) 00128 _x = self.header.frame_id 00129 length = len(_x) 00130 buff.write(struct.pack('<I%ss'%length, length, _x)) 00131 _x = self 00132 buff.write(_struct_2I.pack(_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs)) 00133 _x = self.status.goal_id.id 00134 length = len(_x) 00135 buff.write(struct.pack('<I%ss'%length, length, _x)) 00136 buff.write(_struct_B.pack(self.status.status)) 00137 _x = self.status.text 00138 length = len(_x) 00139 buff.write(struct.pack('<I%ss'%length, length, _x)) 00140 except struct.error as se: self._check_types(se) 00141 except TypeError as te: self._check_types(te) 00142 00143 def deserialize(self, str): 00144 """ 00145 unpack serialized message in str into this message instance 00146 @param str: byte array of serialized message 00147 @type str: str 00148 """ 00149 try: 00150 if self.header is None: 00151 self.header = std_msgs.msg._Header.Header() 00152 if self.status is None: 00153 self.status = actionlib_msgs.msg.GoalStatus() 00154 if self.result is None: 00155 self.result = move_base_msgs.msg.MoveBaseResult() 00156 end = 0 00157 _x = self 00158 start = end 00159 end += 12 00160 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00161 start = end 00162 end += 4 00163 (length,) = _struct_I.unpack(str[start:end]) 00164 start = end 00165 end += length 00166 self.header.frame_id = str[start:end] 00167 _x = self 00168 start = end 00169 end += 8 00170 (_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end]) 00171 start = end 00172 end += 4 00173 (length,) = _struct_I.unpack(str[start:end]) 00174 start = end 00175 end += length 00176 self.status.goal_id.id = str[start:end] 00177 start = end 00178 end += 1 00179 (self.status.status,) = _struct_B.unpack(str[start:end]) 00180 start = end 00181 end += 4 00182 (length,) = _struct_I.unpack(str[start:end]) 00183 start = end 00184 end += length 00185 self.status.text = str[start:end] 00186 return self 00187 except struct.error as e: 00188 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00189 00190 00191 def serialize_numpy(self, buff, numpy): 00192 """ 00193 serialize message with numpy array types into buffer 00194 @param buff: buffer 00195 @type buff: StringIO 00196 @param numpy: numpy python module 00197 @type numpy module 00198 """ 00199 try: 00200 _x = self 00201 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs)) 00202 _x = self.header.frame_id 00203 length = len(_x) 00204 buff.write(struct.pack('<I%ss'%length, length, _x)) 00205 _x = self 00206 buff.write(_struct_2I.pack(_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs)) 00207 _x = self.status.goal_id.id 00208 length = len(_x) 00209 buff.write(struct.pack('<I%ss'%length, length, _x)) 00210 buff.write(_struct_B.pack(self.status.status)) 00211 _x = self.status.text 00212 length = len(_x) 00213 buff.write(struct.pack('<I%ss'%length, length, _x)) 00214 except struct.error as se: self._check_types(se) 00215 except TypeError as te: self._check_types(te) 00216 00217 def deserialize_numpy(self, str, numpy): 00218 """ 00219 unpack serialized message in str into this message instance using numpy for array types 00220 @param str: byte array of serialized message 00221 @type str: str 00222 @param numpy: numpy python module 00223 @type numpy: module 00224 """ 00225 try: 00226 if self.header is None: 00227 self.header = std_msgs.msg._Header.Header() 00228 if self.status is None: 00229 self.status = actionlib_msgs.msg.GoalStatus() 00230 if self.result is None: 00231 self.result = move_base_msgs.msg.MoveBaseResult() 00232 end = 0 00233 _x = self 00234 start = end 00235 end += 12 00236 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00237 start = end 00238 end += 4 00239 (length,) = _struct_I.unpack(str[start:end]) 00240 start = end 00241 end += length 00242 self.header.frame_id = str[start:end] 00243 _x = self 00244 start = end 00245 end += 8 00246 (_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end]) 00247 start = end 00248 end += 4 00249 (length,) = _struct_I.unpack(str[start:end]) 00250 start = end 00251 end += length 00252 self.status.goal_id.id = str[start:end] 00253 start = end 00254 end += 1 00255 (self.status.status,) = _struct_B.unpack(str[start:end]) 00256 start = end 00257 end += 4 00258 (length,) = _struct_I.unpack(str[start:end]) 00259 start = end 00260 end += length 00261 self.status.text = str[start:end] 00262 return self 00263 except struct.error as e: 00264 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00265 00266 _struct_I = roslib.message.struct_I 00267 _struct_3I = struct.Struct("<3I") 00268 _struct_B = struct.Struct("<B") 00269 _struct_2I = struct.Struct("<2I")