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