_GetSerialNumber.py
Go to the documentation of this file.
00001 """autogenerated by genpy from corobot_srvs/GetSerialNumberRequest.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 GetSerialNumberRequest(genpy.Message):
00009   _md5sum = "d41d8cd98f00b204e9800998ecf8427e"
00010   _type = "corobot_srvs/GetSerialNumberRequest"
00011   _has_header = False #flag to mark the presence of a Header object
00012   _full_text = """
00013 
00014 
00015 
00016 
00017 
00018 
00019 
00020 """
00021   __slots__ = []
00022   _slot_types = []
00023 
00024   def __init__(self, *args, **kwds):
00025     """
00026     Constructor. Any message fields that are implicitly/explicitly
00027     set to None will be assigned a default value. The recommend
00028     use is keyword arguments as this is more robust to future message
00029     changes.  You cannot mix in-order arguments and keyword arguments.
00030 
00031     The available fields are:
00032        
00033 
00034     :param args: complete set of field values, in .msg order
00035     :param kwds: use keyword arguments corresponding to message field names
00036     to set specific fields.
00037     """
00038     if args or kwds:
00039       super(GetSerialNumberRequest, self).__init__(*args, **kwds)
00040 
00041   def _get_types(self):
00042     """
00043     internal API method
00044     """
00045     return self._slot_types
00046 
00047   def serialize(self, buff):
00048     """
00049     serialize message into buffer
00050     :param buff: buffer, ``StringIO``
00051     """
00052     try:
00053       pass
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, ``str``
00061     """
00062     try:
00063       end = 0
00064       return self
00065     except struct.error as e:
00066       raise genpy.DeserializationError(e) #most likely buffer underfill
00067 
00068 
00069   def serialize_numpy(self, buff, numpy):
00070     """
00071     serialize message with numpy array types into buffer
00072     :param buff: buffer, ``StringIO``
00073     :param numpy: numpy python module
00074     """
00075     try:
00076       pass
00077     except struct.error as se: self._check_types(se)
00078     except TypeError as te: self._check_types(te)
00079 
00080   def deserialize_numpy(self, str, numpy):
00081     """
00082     unpack serialized message in str into this message instance using numpy for array types
00083     :param str: byte array of serialized message, ``str``
00084     :param numpy: numpy python module
00085     """
00086     try:
00087       end = 0
00088       return self
00089     except struct.error as e:
00090       raise genpy.DeserializationError(e) #most likely buffer underfill
00091 
00092 _struct_I = genpy.struct_I
00093 """autogenerated by genpy from corobot_srvs/GetSerialNumberResponse.msg. Do not edit."""
00094 import sys
00095 python3 = True if sys.hexversion > 0x03000000 else False
00096 import genpy
00097 import struct
00098 
00099 
00100 class GetSerialNumberResponse(genpy.Message):
00101   _md5sum = "cfaceb90a5d2bcce65c527a346ecb23f"
00102   _type = "corobot_srvs/GetSerialNumberResponse"
00103   _has_header = False #flag to mark the presence of a Header object
00104   _full_text = """
00105 int8 serialNumber
00106 
00107 
00108 """
00109   __slots__ = ['serialNumber']
00110   _slot_types = ['int8']
00111 
00112   def __init__(self, *args, **kwds):
00113     """
00114     Constructor. Any message fields that are implicitly/explicitly
00115     set to None will be assigned a default value. The recommend
00116     use is keyword arguments as this is more robust to future message
00117     changes.  You cannot mix in-order arguments and keyword arguments.
00118 
00119     The available fields are:
00120        serialNumber
00121 
00122     :param args: complete set of field values, in .msg order
00123     :param kwds: use keyword arguments corresponding to message field names
00124     to set specific fields.
00125     """
00126     if args or kwds:
00127       super(GetSerialNumberResponse, self).__init__(*args, **kwds)
00128       #message fields cannot be None, assign default values for those that are
00129       if self.serialNumber is None:
00130         self.serialNumber = 0
00131     else:
00132       self.serialNumber = 0
00133 
00134   def _get_types(self):
00135     """
00136     internal API method
00137     """
00138     return self._slot_types
00139 
00140   def serialize(self, buff):
00141     """
00142     serialize message into buffer
00143     :param buff: buffer, ``StringIO``
00144     """
00145     try:
00146       buff.write(_struct_b.pack(self.serialNumber))
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, ``str``
00154     """
00155     try:
00156       end = 0
00157       start = end
00158       end += 1
00159       (self.serialNumber,) = _struct_b.unpack(str[start:end])
00160       return self
00161     except struct.error as e:
00162       raise genpy.DeserializationError(e) #most likely buffer underfill
00163 
00164 
00165   def serialize_numpy(self, buff, numpy):
00166     """
00167     serialize message with numpy array types into buffer
00168     :param buff: buffer, ``StringIO``
00169     :param numpy: numpy python module
00170     """
00171     try:
00172       buff.write(_struct_b.pack(self.serialNumber))
00173     except struct.error as se: self._check_types(se)
00174     except TypeError as te: self._check_types(te)
00175 
00176   def deserialize_numpy(self, str, numpy):
00177     """
00178     unpack serialized message in str into this message instance using numpy for array types
00179     :param str: byte array of serialized message, ``str``
00180     :param numpy: numpy python module
00181     """
00182     try:
00183       end = 0
00184       start = end
00185       end += 1
00186       (self.serialNumber,) = _struct_b.unpack(str[start:end])
00187       return self
00188     except struct.error as e:
00189       raise genpy.DeserializationError(e) #most likely buffer underfill
00190 
00191 _struct_I = genpy.struct_I
00192 _struct_b = struct.Struct("<b")
00193 class GetSerialNumber(object):
00194   _type          = 'corobot_srvs/GetSerialNumber'
00195   _md5sum = 'cfaceb90a5d2bcce65c527a346ecb23f'
00196   _request_class  = GetSerialNumberRequest
00197   _response_class = GetSerialNumberResponse


corobot_srvs
Author(s): Morgan Cormier/mcormier@coroware.com
autogenerated on Tue Jan 7 2014 11:38:11