$search
00001 """autogenerated by genmsg_py from GetConfigRequest.msg. Do not edit.""" 00002 import roslib.message 00003 import struct 00004 00005 00006 class GetConfigRequest(roslib.message.Message): 00007 _md5sum = "eb04b7504512676dca105ab8842899a4" 00008 _type = "photo/GetConfigRequest" 00009 _has_header = False #flag to mark the presence of a Header object 00010 _full_text = """string param 00011 00012 """ 00013 __slots__ = ['param'] 00014 _slot_types = ['string'] 00015 00016 def __init__(self, *args, **kwds): 00017 """ 00018 Constructor. Any message fields that are implicitly/explicitly 00019 set to None will be assigned a default value. The recommend 00020 use is keyword arguments as this is more robust to future message 00021 changes. You cannot mix in-order arguments and keyword arguments. 00022 00023 The available fields are: 00024 param 00025 00026 @param args: complete set of field values, in .msg order 00027 @param kwds: use keyword arguments corresponding to message field names 00028 to set specific fields. 00029 """ 00030 if args or kwds: 00031 super(GetConfigRequest, self).__init__(*args, **kwds) 00032 #message fields cannot be None, assign default values for those that are 00033 if self.param is None: 00034 self.param = '' 00035 else: 00036 self.param = '' 00037 00038 def _get_types(self): 00039 """ 00040 internal API method 00041 """ 00042 return self._slot_types 00043 00044 def serialize(self, buff): 00045 """ 00046 serialize message into buffer 00047 @param buff: buffer 00048 @type buff: StringIO 00049 """ 00050 try: 00051 _x = self.param 00052 length = len(_x) 00053 buff.write(struct.pack('<I%ss'%length, length, _x)) 00054 except struct.error as se: self._check_types(se) 00055 except TypeError as te: self._check_types(te) 00056 00057 def deserialize(self, str): 00058 """ 00059 unpack serialized message in str into this message instance 00060 @param str: byte array of serialized message 00061 @type str: str 00062 """ 00063 try: 00064 end = 0 00065 start = end 00066 end += 4 00067 (length,) = _struct_I.unpack(str[start:end]) 00068 start = end 00069 end += length 00070 self.param = str[start:end] 00071 return self 00072 except struct.error as e: 00073 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00074 00075 00076 def serialize_numpy(self, buff, numpy): 00077 """ 00078 serialize message with numpy array types into buffer 00079 @param buff: buffer 00080 @type buff: StringIO 00081 @param numpy: numpy python module 00082 @type numpy module 00083 """ 00084 try: 00085 _x = self.param 00086 length = len(_x) 00087 buff.write(struct.pack('<I%ss'%length, length, _x)) 00088 except struct.error as se: self._check_types(se) 00089 except TypeError as te: self._check_types(te) 00090 00091 def deserialize_numpy(self, str, numpy): 00092 """ 00093 unpack serialized message in str into this message instance using numpy for array types 00094 @param str: byte array of serialized message 00095 @type str: str 00096 @param numpy: numpy python module 00097 @type numpy: module 00098 """ 00099 try: 00100 end = 0 00101 start = end 00102 end += 4 00103 (length,) = _struct_I.unpack(str[start:end]) 00104 start = end 00105 end += length 00106 self.param = str[start:end] 00107 return self 00108 except struct.error as e: 00109 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00110 00111 _struct_I = roslib.message.struct_I 00112 """autogenerated by genmsg_py from GetConfigResponse.msg. Do not edit.""" 00113 import roslib.message 00114 import struct 00115 00116 00117 class GetConfigResponse(roslib.message.Message): 00118 _md5sum = "64e58419496c7248b4ef25731f88b8c3" 00119 _type = "photo/GetConfigResponse" 00120 _has_header = False #flag to mark the presence of a Header object 00121 _full_text = """string value 00122 00123 """ 00124 __slots__ = ['value'] 00125 _slot_types = ['string'] 00126 00127 def __init__(self, *args, **kwds): 00128 """ 00129 Constructor. Any message fields that are implicitly/explicitly 00130 set to None will be assigned a default value. The recommend 00131 use is keyword arguments as this is more robust to future message 00132 changes. You cannot mix in-order arguments and keyword arguments. 00133 00134 The available fields are: 00135 value 00136 00137 @param args: complete set of field values, in .msg order 00138 @param kwds: use keyword arguments corresponding to message field names 00139 to set specific fields. 00140 """ 00141 if args or kwds: 00142 super(GetConfigResponse, self).__init__(*args, **kwds) 00143 #message fields cannot be None, assign default values for those that are 00144 if self.value is None: 00145 self.value = '' 00146 else: 00147 self.value = '' 00148 00149 def _get_types(self): 00150 """ 00151 internal API method 00152 """ 00153 return self._slot_types 00154 00155 def serialize(self, buff): 00156 """ 00157 serialize message into buffer 00158 @param buff: buffer 00159 @type buff: StringIO 00160 """ 00161 try: 00162 _x = self.value 00163 length = len(_x) 00164 buff.write(struct.pack('<I%ss'%length, length, _x)) 00165 except struct.error as se: self._check_types(se) 00166 except TypeError as te: self._check_types(te) 00167 00168 def deserialize(self, str): 00169 """ 00170 unpack serialized message in str into this message instance 00171 @param str: byte array of serialized message 00172 @type str: str 00173 """ 00174 try: 00175 end = 0 00176 start = end 00177 end += 4 00178 (length,) = _struct_I.unpack(str[start:end]) 00179 start = end 00180 end += length 00181 self.value = str[start:end] 00182 return self 00183 except struct.error as e: 00184 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00185 00186 00187 def serialize_numpy(self, buff, numpy): 00188 """ 00189 serialize message with numpy array types into buffer 00190 @param buff: buffer 00191 @type buff: StringIO 00192 @param numpy: numpy python module 00193 @type numpy module 00194 """ 00195 try: 00196 _x = self.value 00197 length = len(_x) 00198 buff.write(struct.pack('<I%ss'%length, length, _x)) 00199 except struct.error as se: self._check_types(se) 00200 except TypeError as te: self._check_types(te) 00201 00202 def deserialize_numpy(self, str, numpy): 00203 """ 00204 unpack serialized message in str into this message instance using numpy for array types 00205 @param str: byte array of serialized message 00206 @type str: str 00207 @param numpy: numpy python module 00208 @type numpy: module 00209 """ 00210 try: 00211 end = 0 00212 start = end 00213 end += 4 00214 (length,) = _struct_I.unpack(str[start:end]) 00215 start = end 00216 end += length 00217 self.value = str[start:end] 00218 return self 00219 except struct.error as e: 00220 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00221 00222 _struct_I = roslib.message.struct_I 00223 class GetConfig(roslib.message.ServiceDefinition): 00224 _type = 'photo/GetConfig' 00225 _md5sum = '2017f3298983627814c079c3b10ca05d' 00226 _request_class = GetConfigRequest 00227 _response_class = GetConfigResponse