$search
00001 """autogenerated by genmsg_py from ScanBasePoseRequest.msg. Do not edit.""" 00002 import roslib.message 00003 import struct 00004 00005 import geometry_msgs.msg 00006 import srs_msgs.msg 00007 00008 class ScanBasePoseRequest(roslib.message.Message): 00009 _md5sum = "e9544004a6cbf3086f8e6192829b56f4" 00010 _type = "srs_symbolic_grounding/ScanBasePoseRequest" 00011 _has_header = False #flag to mark the presence of a Header object 00012 _full_text = """srs_msgs/SRSSpatialInfo parent_obj_geometry 00013 00014 ================================================================================ 00015 MSG: srs_msgs/SRSSpatialInfo 00016 # Point point 00017 # Orientation angles 00018 float32 l 00019 float32 w 00020 float32 h 00021 00022 geometry_msgs/Pose pose 00023 00024 ================================================================================ 00025 MSG: geometry_msgs/Pose 00026 # A representation of pose in free space, composed of postion and orientation. 00027 Point position 00028 Quaternion orientation 00029 00030 ================================================================================ 00031 MSG: geometry_msgs/Point 00032 # This contains the position of a point in free space 00033 float64 x 00034 float64 y 00035 float64 z 00036 00037 ================================================================================ 00038 MSG: geometry_msgs/Quaternion 00039 # This represents an orientation in free space in quaternion form. 00040 00041 float64 x 00042 float64 y 00043 float64 z 00044 float64 w 00045 00046 """ 00047 __slots__ = ['parent_obj_geometry'] 00048 _slot_types = ['srs_msgs/SRSSpatialInfo'] 00049 00050 def __init__(self, *args, **kwds): 00051 """ 00052 Constructor. Any message fields that are implicitly/explicitly 00053 set to None will be assigned a default value. The recommend 00054 use is keyword arguments as this is more robust to future message 00055 changes. You cannot mix in-order arguments and keyword arguments. 00056 00057 The available fields are: 00058 parent_obj_geometry 00059 00060 @param args: complete set of field values, in .msg order 00061 @param kwds: use keyword arguments corresponding to message field names 00062 to set specific fields. 00063 """ 00064 if args or kwds: 00065 super(ScanBasePoseRequest, self).__init__(*args, **kwds) 00066 #message fields cannot be None, assign default values for those that are 00067 if self.parent_obj_geometry is None: 00068 self.parent_obj_geometry = srs_msgs.msg.SRSSpatialInfo() 00069 else: 00070 self.parent_obj_geometry = srs_msgs.msg.SRSSpatialInfo() 00071 00072 def _get_types(self): 00073 """ 00074 internal API method 00075 """ 00076 return self._slot_types 00077 00078 def serialize(self, buff): 00079 """ 00080 serialize message into buffer 00081 @param buff: buffer 00082 @type buff: StringIO 00083 """ 00084 try: 00085 _x = self 00086 buff.write(_struct_3f7d.pack(_x.parent_obj_geometry.l, _x.parent_obj_geometry.w, _x.parent_obj_geometry.h, _x.parent_obj_geometry.pose.position.x, _x.parent_obj_geometry.pose.position.y, _x.parent_obj_geometry.pose.position.z, _x.parent_obj_geometry.pose.orientation.x, _x.parent_obj_geometry.pose.orientation.y, _x.parent_obj_geometry.pose.orientation.z, _x.parent_obj_geometry.pose.orientation.w)) 00087 except struct.error as se: self._check_types(se) 00088 except TypeError as te: self._check_types(te) 00089 00090 def deserialize(self, str): 00091 """ 00092 unpack serialized message in str into this message instance 00093 @param str: byte array of serialized message 00094 @type str: str 00095 """ 00096 try: 00097 if self.parent_obj_geometry is None: 00098 self.parent_obj_geometry = srs_msgs.msg.SRSSpatialInfo() 00099 end = 0 00100 _x = self 00101 start = end 00102 end += 68 00103 (_x.parent_obj_geometry.l, _x.parent_obj_geometry.w, _x.parent_obj_geometry.h, _x.parent_obj_geometry.pose.position.x, _x.parent_obj_geometry.pose.position.y, _x.parent_obj_geometry.pose.position.z, _x.parent_obj_geometry.pose.orientation.x, _x.parent_obj_geometry.pose.orientation.y, _x.parent_obj_geometry.pose.orientation.z, _x.parent_obj_geometry.pose.orientation.w,) = _struct_3f7d.unpack(str[start:end]) 00104 return self 00105 except struct.error as e: 00106 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00107 00108 00109 def serialize_numpy(self, buff, numpy): 00110 """ 00111 serialize message with numpy array types into buffer 00112 @param buff: buffer 00113 @type buff: StringIO 00114 @param numpy: numpy python module 00115 @type numpy module 00116 """ 00117 try: 00118 _x = self 00119 buff.write(_struct_3f7d.pack(_x.parent_obj_geometry.l, _x.parent_obj_geometry.w, _x.parent_obj_geometry.h, _x.parent_obj_geometry.pose.position.x, _x.parent_obj_geometry.pose.position.y, _x.parent_obj_geometry.pose.position.z, _x.parent_obj_geometry.pose.orientation.x, _x.parent_obj_geometry.pose.orientation.y, _x.parent_obj_geometry.pose.orientation.z, _x.parent_obj_geometry.pose.orientation.w)) 00120 except struct.error as se: self._check_types(se) 00121 except TypeError as te: self._check_types(te) 00122 00123 def deserialize_numpy(self, str, numpy): 00124 """ 00125 unpack serialized message in str into this message instance using numpy for array types 00126 @param str: byte array of serialized message 00127 @type str: str 00128 @param numpy: numpy python module 00129 @type numpy: module 00130 """ 00131 try: 00132 if self.parent_obj_geometry is None: 00133 self.parent_obj_geometry = srs_msgs.msg.SRSSpatialInfo() 00134 end = 0 00135 _x = self 00136 start = end 00137 end += 68 00138 (_x.parent_obj_geometry.l, _x.parent_obj_geometry.w, _x.parent_obj_geometry.h, _x.parent_obj_geometry.pose.position.x, _x.parent_obj_geometry.pose.position.y, _x.parent_obj_geometry.pose.position.z, _x.parent_obj_geometry.pose.orientation.x, _x.parent_obj_geometry.pose.orientation.y, _x.parent_obj_geometry.pose.orientation.z, _x.parent_obj_geometry.pose.orientation.w,) = _struct_3f7d.unpack(str[start:end]) 00139 return self 00140 except struct.error as e: 00141 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00142 00143 _struct_I = roslib.message.struct_I 00144 _struct_3f7d = struct.Struct("<3f7d") 00145 """autogenerated by genmsg_py from ScanBasePoseResponse.msg. Do not edit.""" 00146 import roslib.message 00147 import struct 00148 00149 import geometry_msgs.msg 00150 00151 class ScanBasePoseResponse(roslib.message.Message): 00152 _md5sum = "66b4de75c1cdba6b484a2621de9dc0d6" 00153 _type = "srs_symbolic_grounding/ScanBasePoseResponse" 00154 _has_header = False #flag to mark the presence of a Header object 00155 _full_text = """geometry_msgs/Pose2D[] scan_base_pose_list 00156 00157 00158 00159 00160 00161 ================================================================================ 00162 MSG: geometry_msgs/Pose2D 00163 # This expresses a position and orientation on a 2D manifold. 00164 00165 float64 x 00166 float64 y 00167 float64 theta 00168 """ 00169 __slots__ = ['scan_base_pose_list'] 00170 _slot_types = ['geometry_msgs/Pose2D[]'] 00171 00172 def __init__(self, *args, **kwds): 00173 """ 00174 Constructor. Any message fields that are implicitly/explicitly 00175 set to None will be assigned a default value. The recommend 00176 use is keyword arguments as this is more robust to future message 00177 changes. You cannot mix in-order arguments and keyword arguments. 00178 00179 The available fields are: 00180 scan_base_pose_list 00181 00182 @param args: complete set of field values, in .msg order 00183 @param kwds: use keyword arguments corresponding to message field names 00184 to set specific fields. 00185 """ 00186 if args or kwds: 00187 super(ScanBasePoseResponse, self).__init__(*args, **kwds) 00188 #message fields cannot be None, assign default values for those that are 00189 if self.scan_base_pose_list is None: 00190 self.scan_base_pose_list = [] 00191 else: 00192 self.scan_base_pose_list = [] 00193 00194 def _get_types(self): 00195 """ 00196 internal API method 00197 """ 00198 return self._slot_types 00199 00200 def serialize(self, buff): 00201 """ 00202 serialize message into buffer 00203 @param buff: buffer 00204 @type buff: StringIO 00205 """ 00206 try: 00207 length = len(self.scan_base_pose_list) 00208 buff.write(_struct_I.pack(length)) 00209 for val1 in self.scan_base_pose_list: 00210 _x = val1 00211 buff.write(_struct_3d.pack(_x.x, _x.y, _x.theta)) 00212 except struct.error as se: self._check_types(se) 00213 except TypeError as te: self._check_types(te) 00214 00215 def deserialize(self, str): 00216 """ 00217 unpack serialized message in str into this message instance 00218 @param str: byte array of serialized message 00219 @type str: str 00220 """ 00221 try: 00222 end = 0 00223 start = end 00224 end += 4 00225 (length,) = _struct_I.unpack(str[start:end]) 00226 self.scan_base_pose_list = [] 00227 for i in range(0, length): 00228 val1 = geometry_msgs.msg.Pose2D() 00229 _x = val1 00230 start = end 00231 end += 24 00232 (_x.x, _x.y, _x.theta,) = _struct_3d.unpack(str[start:end]) 00233 self.scan_base_pose_list.append(val1) 00234 return self 00235 except struct.error as e: 00236 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00237 00238 00239 def serialize_numpy(self, buff, numpy): 00240 """ 00241 serialize message with numpy array types into buffer 00242 @param buff: buffer 00243 @type buff: StringIO 00244 @param numpy: numpy python module 00245 @type numpy module 00246 """ 00247 try: 00248 length = len(self.scan_base_pose_list) 00249 buff.write(_struct_I.pack(length)) 00250 for val1 in self.scan_base_pose_list: 00251 _x = val1 00252 buff.write(_struct_3d.pack(_x.x, _x.y, _x.theta)) 00253 except struct.error as se: self._check_types(se) 00254 except TypeError as te: self._check_types(te) 00255 00256 def deserialize_numpy(self, str, numpy): 00257 """ 00258 unpack serialized message in str into this message instance using numpy for array types 00259 @param str: byte array of serialized message 00260 @type str: str 00261 @param numpy: numpy python module 00262 @type numpy: module 00263 """ 00264 try: 00265 end = 0 00266 start = end 00267 end += 4 00268 (length,) = _struct_I.unpack(str[start:end]) 00269 self.scan_base_pose_list = [] 00270 for i in range(0, length): 00271 val1 = geometry_msgs.msg.Pose2D() 00272 _x = val1 00273 start = end 00274 end += 24 00275 (_x.x, _x.y, _x.theta,) = _struct_3d.unpack(str[start:end]) 00276 self.scan_base_pose_list.append(val1) 00277 return self 00278 except struct.error as e: 00279 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00280 00281 _struct_I = roslib.message.struct_I 00282 _struct_3d = struct.Struct("<3d") 00283 class ScanBasePose(roslib.message.ServiceDefinition): 00284 _type = 'srs_symbolic_grounding/ScanBasePose' 00285 _md5sum = '0b68fdc0a9a83294fed2acbcecc407b6' 00286 _request_class = ScanBasePoseRequest 00287 _response_class = ScanBasePoseResponse