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