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


cob_base_drive_chain
Author(s): Christian Connette
autogenerated on Fri Mar 1 2013 17:48:55