$search
00001 """autogenerated by genmsg_py from GetAppDetailsRequest.msg. Do not edit.""" 00002 import roslib.message 00003 import struct 00004 00005 00006 class GetAppDetailsRequest(roslib.message.Message): 00007 _md5sum = "c1f3d28f1b044c871e6eff2e9fc3c667" 00008 _type = "app_manager/GetAppDetailsRequest" 00009 _has_header = False #flag to mark the presence of a Header object 00010 _full_text = """ 00011 string name 00012 00013 """ 00014 __slots__ = ['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 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(GetAppDetailsRequest, self).__init__(*args, **kwds) 00033 #message fields cannot be None, assign default values for those that are 00034 if self.name is None: 00035 self.name = '' 00036 else: 00037 self.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.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.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.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.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 GetAppDetailsResponse.msg. Do not edit.""" 00114 import roslib.message 00115 import struct 00116 00117 import app_manager.msg 00118 00119 class GetAppDetailsResponse(roslib.message.Message): 00120 _md5sum = "404cd76612a719d24ac22fba2d495de8" 00121 _type = "app_manager/GetAppDetailsResponse" 00122 _has_header = False #flag to mark the presence of a Header object 00123 _full_text = """ExchangeApp app 00124 00125 00126 00127 ================================================================================ 00128 MSG: app_manager/ExchangeApp 00129 # app name 00130 string name 00131 # user-friendly display name of application 00132 string display_name 00133 # the version of the package currently installed 00134 string version 00135 # latest version of the package avaliable 00136 string latest_version 00137 # the detailed description of the app 00138 string description 00139 # icon for showing app 00140 Icon icon 00141 # hidden apps are not show - used for cases where multiple apps are in a deb 00142 bool hidden 00143 ================================================================================ 00144 MSG: app_manager/Icon 00145 # Image data format. "jpeg" or "png" 00146 string format 00147 00148 # Image data. 00149 uint8[] data 00150 00151 """ 00152 __slots__ = ['app'] 00153 _slot_types = ['app_manager/ExchangeApp'] 00154 00155 def __init__(self, *args, **kwds): 00156 """ 00157 Constructor. Any message fields that are implicitly/explicitly 00158 set to None will be assigned a default value. The recommend 00159 use is keyword arguments as this is more robust to future message 00160 changes. You cannot mix in-order arguments and keyword arguments. 00161 00162 The available fields are: 00163 app 00164 00165 @param args: complete set of field values, in .msg order 00166 @param kwds: use keyword arguments corresponding to message field names 00167 to set specific fields. 00168 """ 00169 if args or kwds: 00170 super(GetAppDetailsResponse, self).__init__(*args, **kwds) 00171 #message fields cannot be None, assign default values for those that are 00172 if self.app is None: 00173 self.app = app_manager.msg.ExchangeApp() 00174 else: 00175 self.app = app_manager.msg.ExchangeApp() 00176 00177 def _get_types(self): 00178 """ 00179 internal API method 00180 """ 00181 return self._slot_types 00182 00183 def serialize(self, buff): 00184 """ 00185 serialize message into buffer 00186 @param buff: buffer 00187 @type buff: StringIO 00188 """ 00189 try: 00190 _x = self.app.name 00191 length = len(_x) 00192 buff.write(struct.pack('<I%ss'%length, length, _x)) 00193 _x = self.app.display_name 00194 length = len(_x) 00195 buff.write(struct.pack('<I%ss'%length, length, _x)) 00196 _x = self.app.version 00197 length = len(_x) 00198 buff.write(struct.pack('<I%ss'%length, length, _x)) 00199 _x = self.app.latest_version 00200 length = len(_x) 00201 buff.write(struct.pack('<I%ss'%length, length, _x)) 00202 _x = self.app.description 00203 length = len(_x) 00204 buff.write(struct.pack('<I%ss'%length, length, _x)) 00205 _x = self.app.icon.format 00206 length = len(_x) 00207 buff.write(struct.pack('<I%ss'%length, length, _x)) 00208 _x = self.app.icon.data 00209 length = len(_x) 00210 # - if encoded as a list instead, serialize as bytes instead of string 00211 if type(_x) in [list, tuple]: 00212 buff.write(struct.pack('<I%sB'%length, length, *_x)) 00213 else: 00214 buff.write(struct.pack('<I%ss'%length, length, _x)) 00215 buff.write(_struct_B.pack(self.app.hidden)) 00216 except struct.error as se: self._check_types(se) 00217 except TypeError as te: self._check_types(te) 00218 00219 def deserialize(self, str): 00220 """ 00221 unpack serialized message in str into this message instance 00222 @param str: byte array of serialized message 00223 @type str: str 00224 """ 00225 try: 00226 if self.app is None: 00227 self.app = app_manager.msg.ExchangeApp() 00228 end = 0 00229 start = end 00230 end += 4 00231 (length,) = _struct_I.unpack(str[start:end]) 00232 start = end 00233 end += length 00234 self.app.name = str[start:end] 00235 start = end 00236 end += 4 00237 (length,) = _struct_I.unpack(str[start:end]) 00238 start = end 00239 end += length 00240 self.app.display_name = str[start:end] 00241 start = end 00242 end += 4 00243 (length,) = _struct_I.unpack(str[start:end]) 00244 start = end 00245 end += length 00246 self.app.version = 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.app.latest_version = str[start:end] 00253 start = end 00254 end += 4 00255 (length,) = _struct_I.unpack(str[start:end]) 00256 start = end 00257 end += length 00258 self.app.description = str[start:end] 00259 start = end 00260 end += 4 00261 (length,) = _struct_I.unpack(str[start:end]) 00262 start = end 00263 end += length 00264 self.app.icon.format = str[start:end] 00265 start = end 00266 end += 4 00267 (length,) = _struct_I.unpack(str[start:end]) 00268 start = end 00269 end += length 00270 self.app.icon.data = str[start:end] 00271 start = end 00272 end += 1 00273 (self.app.hidden,) = _struct_B.unpack(str[start:end]) 00274 self.app.hidden = bool(self.app.hidden) 00275 return self 00276 except struct.error as e: 00277 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00278 00279 00280 def serialize_numpy(self, buff, numpy): 00281 """ 00282 serialize message with numpy array types into buffer 00283 @param buff: buffer 00284 @type buff: StringIO 00285 @param numpy: numpy python module 00286 @type numpy module 00287 """ 00288 try: 00289 _x = self.app.name 00290 length = len(_x) 00291 buff.write(struct.pack('<I%ss'%length, length, _x)) 00292 _x = self.app.display_name 00293 length = len(_x) 00294 buff.write(struct.pack('<I%ss'%length, length, _x)) 00295 _x = self.app.version 00296 length = len(_x) 00297 buff.write(struct.pack('<I%ss'%length, length, _x)) 00298 _x = self.app.latest_version 00299 length = len(_x) 00300 buff.write(struct.pack('<I%ss'%length, length, _x)) 00301 _x = self.app.description 00302 length = len(_x) 00303 buff.write(struct.pack('<I%ss'%length, length, _x)) 00304 _x = self.app.icon.format 00305 length = len(_x) 00306 buff.write(struct.pack('<I%ss'%length, length, _x)) 00307 _x = self.app.icon.data 00308 length = len(_x) 00309 # - if encoded as a list instead, serialize as bytes instead of string 00310 if type(_x) in [list, tuple]: 00311 buff.write(struct.pack('<I%sB'%length, length, *_x)) 00312 else: 00313 buff.write(struct.pack('<I%ss'%length, length, _x)) 00314 buff.write(_struct_B.pack(self.app.hidden)) 00315 except struct.error as se: self._check_types(se) 00316 except TypeError as te: self._check_types(te) 00317 00318 def deserialize_numpy(self, str, numpy): 00319 """ 00320 unpack serialized message in str into this message instance using numpy for array types 00321 @param str: byte array of serialized message 00322 @type str: str 00323 @param numpy: numpy python module 00324 @type numpy: module 00325 """ 00326 try: 00327 if self.app is None: 00328 self.app = app_manager.msg.ExchangeApp() 00329 end = 0 00330 start = end 00331 end += 4 00332 (length,) = _struct_I.unpack(str[start:end]) 00333 start = end 00334 end += length 00335 self.app.name = str[start:end] 00336 start = end 00337 end += 4 00338 (length,) = _struct_I.unpack(str[start:end]) 00339 start = end 00340 end += length 00341 self.app.display_name = str[start:end] 00342 start = end 00343 end += 4 00344 (length,) = _struct_I.unpack(str[start:end]) 00345 start = end 00346 end += length 00347 self.app.version = str[start:end] 00348 start = end 00349 end += 4 00350 (length,) = _struct_I.unpack(str[start:end]) 00351 start = end 00352 end += length 00353 self.app.latest_version = str[start:end] 00354 start = end 00355 end += 4 00356 (length,) = _struct_I.unpack(str[start:end]) 00357 start = end 00358 end += length 00359 self.app.description = str[start:end] 00360 start = end 00361 end += 4 00362 (length,) = _struct_I.unpack(str[start:end]) 00363 start = end 00364 end += length 00365 self.app.icon.format = str[start:end] 00366 start = end 00367 end += 4 00368 (length,) = _struct_I.unpack(str[start:end]) 00369 start = end 00370 end += length 00371 self.app.icon.data = str[start:end] 00372 start = end 00373 end += 1 00374 (self.app.hidden,) = _struct_B.unpack(str[start:end]) 00375 self.app.hidden = bool(self.app.hidden) 00376 return self 00377 except struct.error as e: 00378 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00379 00380 _struct_I = roslib.message.struct_I 00381 _struct_B = struct.Struct("<B") 00382 class GetAppDetails(roslib.message.ServiceDefinition): 00383 _type = 'app_manager/GetAppDetails' 00384 _md5sum = '982707be65dd9bb38c19f6e18cb18db5' 00385 _request_class = GetAppDetailsRequest 00386 _response_class = GetAppDetailsResponse