$search
00001 """autogenerated by genmsg_py from MoveBaseActionGoal.msg. Do not edit.""" 00002 import roslib.message 00003 import struct 00004 00005 import geometry_msgs.msg 00006 import move_base_msgs.msg 00007 import roslib.rostime 00008 import actionlib_msgs.msg 00009 import std_msgs.msg 00010 00011 class MoveBaseActionGoal(roslib.message.Message): 00012 _md5sum = "660d6895a1b9a16dce51fbdd9a64a56b" 00013 _type = "move_base_msgs/MoveBaseActionGoal" 00014 _has_header = True #flag to mark the presence of a Header object 00015 _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== 00016 00017 Header header 00018 actionlib_msgs/GoalID goal_id 00019 MoveBaseGoal goal 00020 00021 ================================================================================ 00022 MSG: std_msgs/Header 00023 # Standard metadata for higher-level stamped data types. 00024 # This is generally used to communicate timestamped data 00025 # in a particular coordinate frame. 00026 # 00027 # sequence ID: consecutively increasing ID 00028 uint32 seq 00029 #Two-integer timestamp that is expressed as: 00030 # * stamp.secs: seconds (stamp_secs) since epoch 00031 # * stamp.nsecs: nanoseconds since stamp_secs 00032 # time-handling sugar is provided by the client library 00033 time stamp 00034 #Frame this data is associated with 00035 # 0: no frame 00036 # 1: global frame 00037 string frame_id 00038 00039 ================================================================================ 00040 MSG: actionlib_msgs/GoalID 00041 # The stamp should store the time at which this goal was requested. 00042 # It is used by an action server when it tries to preempt all 00043 # goals that were requested before a certain time 00044 time stamp 00045 00046 # The id provides a way to associate feedback and 00047 # result message with specific goal requests. The id 00048 # specified must be unique. 00049 string id 00050 00051 00052 ================================================================================ 00053 MSG: move_base_msgs/MoveBaseGoal 00054 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== 00055 geometry_msgs/PoseStamped target_pose 00056 00057 ================================================================================ 00058 MSG: geometry_msgs/PoseStamped 00059 # A Pose with reference coordinate frame and timestamp 00060 Header header 00061 Pose pose 00062 00063 ================================================================================ 00064 MSG: geometry_msgs/Pose 00065 # A representation of pose in free space, composed of postion and orientation. 00066 Point position 00067 Quaternion orientation 00068 00069 ================================================================================ 00070 MSG: geometry_msgs/Point 00071 # This contains the position of a point in free space 00072 float64 x 00073 float64 y 00074 float64 z 00075 00076 ================================================================================ 00077 MSG: geometry_msgs/Quaternion 00078 # This represents an orientation in free space in quaternion form. 00079 00080 float64 x 00081 float64 y 00082 float64 z 00083 float64 w 00084 00085 """ 00086 __slots__ = ['header','goal_id','goal'] 00087 _slot_types = ['Header','actionlib_msgs/GoalID','move_base_msgs/MoveBaseGoal'] 00088 00089 def __init__(self, *args, **kwds): 00090 """ 00091 Constructor. Any message fields that are implicitly/explicitly 00092 set to None will be assigned a default value. The recommend 00093 use is keyword arguments as this is more robust to future message 00094 changes. You cannot mix in-order arguments and keyword arguments. 00095 00096 The available fields are: 00097 header,goal_id,goal 00098 00099 @param args: complete set of field values, in .msg order 00100 @param kwds: use keyword arguments corresponding to message field names 00101 to set specific fields. 00102 """ 00103 if args or kwds: 00104 super(MoveBaseActionGoal, self).__init__(*args, **kwds) 00105 #message fields cannot be None, assign default values for those that are 00106 if self.header is None: 00107 self.header = std_msgs.msg._Header.Header() 00108 if self.goal_id is None: 00109 self.goal_id = actionlib_msgs.msg.GoalID() 00110 if self.goal is None: 00111 self.goal = move_base_msgs.msg.MoveBaseGoal() 00112 else: 00113 self.header = std_msgs.msg._Header.Header() 00114 self.goal_id = actionlib_msgs.msg.GoalID() 00115 self.goal = move_base_msgs.msg.MoveBaseGoal() 00116 00117 def _get_types(self): 00118 """ 00119 internal API method 00120 """ 00121 return self._slot_types 00122 00123 def serialize(self, buff): 00124 """ 00125 serialize message into buffer 00126 @param buff: buffer 00127 @type buff: StringIO 00128 """ 00129 try: 00130 _x = self 00131 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs)) 00132 _x = self.header.frame_id 00133 length = len(_x) 00134 buff.write(struct.pack('<I%ss'%length, length, _x)) 00135 _x = self 00136 buff.write(_struct_2I.pack(_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs)) 00137 _x = self.goal_id.id 00138 length = len(_x) 00139 buff.write(struct.pack('<I%ss'%length, length, _x)) 00140 _x = self 00141 buff.write(_struct_3I.pack(_x.goal.target_pose.header.seq, _x.goal.target_pose.header.stamp.secs, _x.goal.target_pose.header.stamp.nsecs)) 00142 _x = self.goal.target_pose.header.frame_id 00143 length = len(_x) 00144 buff.write(struct.pack('<I%ss'%length, length, _x)) 00145 _x = self 00146 buff.write(_struct_7d.pack(_x.goal.target_pose.pose.position.x, _x.goal.target_pose.pose.position.y, _x.goal.target_pose.pose.position.z, _x.goal.target_pose.pose.orientation.x, _x.goal.target_pose.pose.orientation.y, _x.goal.target_pose.pose.orientation.z, _x.goal.target_pose.pose.orientation.w)) 00147 except struct.error as se: self._check_types(se) 00148 except TypeError as te: self._check_types(te) 00149 00150 def deserialize(self, str): 00151 """ 00152 unpack serialized message in str into this message instance 00153 @param str: byte array of serialized message 00154 @type str: str 00155 """ 00156 try: 00157 if self.header is None: 00158 self.header = std_msgs.msg._Header.Header() 00159 if self.goal_id is None: 00160 self.goal_id = actionlib_msgs.msg.GoalID() 00161 if self.goal is None: 00162 self.goal = move_base_msgs.msg.MoveBaseGoal() 00163 end = 0 00164 _x = self 00165 start = end 00166 end += 12 00167 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00168 start = end 00169 end += 4 00170 (length,) = _struct_I.unpack(str[start:end]) 00171 start = end 00172 end += length 00173 self.header.frame_id = str[start:end] 00174 _x = self 00175 start = end 00176 end += 8 00177 (_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end]) 00178 start = end 00179 end += 4 00180 (length,) = _struct_I.unpack(str[start:end]) 00181 start = end 00182 end += length 00183 self.goal_id.id = str[start:end] 00184 _x = self 00185 start = end 00186 end += 12 00187 (_x.goal.target_pose.header.seq, _x.goal.target_pose.header.stamp.secs, _x.goal.target_pose.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00188 start = end 00189 end += 4 00190 (length,) = _struct_I.unpack(str[start:end]) 00191 start = end 00192 end += length 00193 self.goal.target_pose.header.frame_id = str[start:end] 00194 _x = self 00195 start = end 00196 end += 56 00197 (_x.goal.target_pose.pose.position.x, _x.goal.target_pose.pose.position.y, _x.goal.target_pose.pose.position.z, _x.goal.target_pose.pose.orientation.x, _x.goal.target_pose.pose.orientation.y, _x.goal.target_pose.pose.orientation.z, _x.goal.target_pose.pose.orientation.w,) = _struct_7d.unpack(str[start:end]) 00198 return self 00199 except struct.error as e: 00200 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00201 00202 00203 def serialize_numpy(self, buff, numpy): 00204 """ 00205 serialize message with numpy array types into buffer 00206 @param buff: buffer 00207 @type buff: StringIO 00208 @param numpy: numpy python module 00209 @type numpy module 00210 """ 00211 try: 00212 _x = self 00213 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs)) 00214 _x = self.header.frame_id 00215 length = len(_x) 00216 buff.write(struct.pack('<I%ss'%length, length, _x)) 00217 _x = self 00218 buff.write(_struct_2I.pack(_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs)) 00219 _x = self.goal_id.id 00220 length = len(_x) 00221 buff.write(struct.pack('<I%ss'%length, length, _x)) 00222 _x = self 00223 buff.write(_struct_3I.pack(_x.goal.target_pose.header.seq, _x.goal.target_pose.header.stamp.secs, _x.goal.target_pose.header.stamp.nsecs)) 00224 _x = self.goal.target_pose.header.frame_id 00225 length = len(_x) 00226 buff.write(struct.pack('<I%ss'%length, length, _x)) 00227 _x = self 00228 buff.write(_struct_7d.pack(_x.goal.target_pose.pose.position.x, _x.goal.target_pose.pose.position.y, _x.goal.target_pose.pose.position.z, _x.goal.target_pose.pose.orientation.x, _x.goal.target_pose.pose.orientation.y, _x.goal.target_pose.pose.orientation.z, _x.goal.target_pose.pose.orientation.w)) 00229 except struct.error as se: self._check_types(se) 00230 except TypeError as te: self._check_types(te) 00231 00232 def deserialize_numpy(self, str, numpy): 00233 """ 00234 unpack serialized message in str into this message instance using numpy for array types 00235 @param str: byte array of serialized message 00236 @type str: str 00237 @param numpy: numpy python module 00238 @type numpy: module 00239 """ 00240 try: 00241 if self.header is None: 00242 self.header = std_msgs.msg._Header.Header() 00243 if self.goal_id is None: 00244 self.goal_id = actionlib_msgs.msg.GoalID() 00245 if self.goal is None: 00246 self.goal = move_base_msgs.msg.MoveBaseGoal() 00247 end = 0 00248 _x = self 00249 start = end 00250 end += 12 00251 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00252 start = end 00253 end += 4 00254 (length,) = _struct_I.unpack(str[start:end]) 00255 start = end 00256 end += length 00257 self.header.frame_id = str[start:end] 00258 _x = self 00259 start = end 00260 end += 8 00261 (_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end]) 00262 start = end 00263 end += 4 00264 (length,) = _struct_I.unpack(str[start:end]) 00265 start = end 00266 end += length 00267 self.goal_id.id = str[start:end] 00268 _x = self 00269 start = end 00270 end += 12 00271 (_x.goal.target_pose.header.seq, _x.goal.target_pose.header.stamp.secs, _x.goal.target_pose.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00272 start = end 00273 end += 4 00274 (length,) = _struct_I.unpack(str[start:end]) 00275 start = end 00276 end += length 00277 self.goal.target_pose.header.frame_id = str[start:end] 00278 _x = self 00279 start = end 00280 end += 56 00281 (_x.goal.target_pose.pose.position.x, _x.goal.target_pose.pose.position.y, _x.goal.target_pose.pose.position.z, _x.goal.target_pose.pose.orientation.x, _x.goal.target_pose.pose.orientation.y, _x.goal.target_pose.pose.orientation.z, _x.goal.target_pose.pose.orientation.w,) = _struct_7d.unpack(str[start:end]) 00282 return self 00283 except struct.error as e: 00284 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00285 00286 _struct_I = roslib.message.struct_I 00287 _struct_3I = struct.Struct("<3I") 00288 _struct_7d = struct.Struct("<7d") 00289 _struct_2I = struct.Struct("<2I")