_MergeTracks.py
Go to the documentation of this file.
00001 """autogenerated by genpy from sba/MergeTracksRequest.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 MergeTracksRequest(genpy.Message):
00009   _md5sum = "dd1ba0ef5aa44cb449cd7e46ef837560"
00010   _type = "sba/MergeTracksRequest"
00011   _has_header = False #flag to mark the presence of a Header object
00012   _full_text = """
00013 int32 trackid0
00014 int32 trackid1
00015 
00016 """
00017   __slots__ = ['trackid0','trackid1']
00018   _slot_types = ['int32','int32']
00019 
00020   def __init__(self, *args, **kwds):
00021     """
00022     Constructor. Any message fields that are implicitly/explicitly
00023     set to None will be assigned a default value. The recommend
00024     use is keyword arguments as this is more robust to future message
00025     changes.  You cannot mix in-order arguments and keyword arguments.
00026 
00027     The available fields are:
00028        trackid0,trackid1
00029 
00030     :param args: complete set of field values, in .msg order
00031     :param kwds: use keyword arguments corresponding to message field names
00032     to set specific fields.
00033     """
00034     if args or kwds:
00035       super(MergeTracksRequest, self).__init__(*args, **kwds)
00036       #message fields cannot be None, assign default values for those that are
00037       if self.trackid0 is None:
00038         self.trackid0 = 0
00039       if self.trackid1 is None:
00040         self.trackid1 = 0
00041     else:
00042       self.trackid0 = 0
00043       self.trackid1 = 0
00044 
00045   def _get_types(self):
00046     """
00047     internal API method
00048     """
00049     return self._slot_types
00050 
00051   def serialize(self, buff):
00052     """
00053     serialize message into buffer
00054     :param buff: buffer, ``StringIO``
00055     """
00056     try:
00057       _x = self
00058       buff.write(_struct_2i.pack(_x.trackid0, _x.trackid1))
00059     except struct.error as se: self._check_types(se)
00060     except TypeError as te: self._check_types(te)
00061 
00062   def deserialize(self, str):
00063     """
00064     unpack serialized message in str into this message instance
00065     :param str: byte array of serialized message, ``str``
00066     """
00067     try:
00068       end = 0
00069       _x = self
00070       start = end
00071       end += 8
00072       (_x.trackid0, _x.trackid1,) = _struct_2i.unpack(str[start:end])
00073       return self
00074     except struct.error as e:
00075       raise genpy.DeserializationError(e) #most likely buffer underfill
00076 
00077 
00078   def serialize_numpy(self, buff, numpy):
00079     """
00080     serialize message with numpy array types into buffer
00081     :param buff: buffer, ``StringIO``
00082     :param numpy: numpy python module
00083     """
00084     try:
00085       _x = self
00086       buff.write(_struct_2i.pack(_x.trackid0, _x.trackid1))
00087     except struct.error as se: self._check_types(se)
00088     except TypeError as te: self._check_types(te)
00089 
00090   def deserialize_numpy(self, str, numpy):
00091     """
00092     unpack serialized message in str into this message instance using numpy for array types
00093     :param str: byte array of serialized message, ``str``
00094     :param numpy: numpy python module
00095     """
00096     try:
00097       end = 0
00098       _x = self
00099       start = end
00100       end += 8
00101       (_x.trackid0, _x.trackid1,) = _struct_2i.unpack(str[start:end])
00102       return self
00103     except struct.error as e:
00104       raise genpy.DeserializationError(e) #most likely buffer underfill
00105 
00106 _struct_I = genpy.struct_I
00107 _struct_2i = struct.Struct("<2i")
00108 """autogenerated by genpy from sba/MergeTracksResponse.msg. Do not edit."""
00109 import sys
00110 python3 = True if sys.hexversion > 0x03000000 else False
00111 import genpy
00112 import struct
00113 
00114 
00115 class MergeTracksResponse(genpy.Message):
00116   _md5sum = "49f7108534259660e3e6bcd8549c2756"
00117   _type = "sba/MergeTracksResponse"
00118   _has_header = False #flag to mark the presence of a Header object
00119   _full_text = """
00120 int32 trackid
00121 
00122 
00123 """
00124   __slots__ = ['trackid']
00125   _slot_types = ['int32']
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        trackid
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(MergeTracksResponse, self).__init__(*args, **kwds)
00143       #message fields cannot be None, assign default values for those that are
00144       if self.trackid is None:
00145         self.trackid = 0
00146     else:
00147       self.trackid = 0
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, ``StringIO``
00159     """
00160     try:
00161       buff.write(_struct_i.pack(self.trackid))
00162     except struct.error as se: self._check_types(se)
00163     except TypeError as te: self._check_types(te)
00164 
00165   def deserialize(self, str):
00166     """
00167     unpack serialized message in str into this message instance
00168     :param str: byte array of serialized message, ``str``
00169     """
00170     try:
00171       end = 0
00172       start = end
00173       end += 4
00174       (self.trackid,) = _struct_i.unpack(str[start:end])
00175       return self
00176     except struct.error as e:
00177       raise genpy.DeserializationError(e) #most likely buffer underfill
00178 
00179 
00180   def serialize_numpy(self, buff, numpy):
00181     """
00182     serialize message with numpy array types into buffer
00183     :param buff: buffer, ``StringIO``
00184     :param numpy: numpy python module
00185     """
00186     try:
00187       buff.write(_struct_i.pack(self.trackid))
00188     except struct.error as se: self._check_types(se)
00189     except TypeError as te: self._check_types(te)
00190 
00191   def deserialize_numpy(self, str, numpy):
00192     """
00193     unpack serialized message in str into this message instance using numpy for array types
00194     :param str: byte array of serialized message, ``str``
00195     :param numpy: numpy python module
00196     """
00197     try:
00198       end = 0
00199       start = end
00200       end += 4
00201       (self.trackid,) = _struct_i.unpack(str[start:end])
00202       return self
00203     except struct.error as e:
00204       raise genpy.DeserializationError(e) #most likely buffer underfill
00205 
00206 _struct_I = genpy.struct_I
00207 _struct_i = struct.Struct("<i")
00208 class MergeTracks(object):
00209   _type          = 'sba/MergeTracks'
00210   _md5sum = '2f187ca4cd18b91f5e3cc15a747f1068'
00211   _request_class  = MergeTracksRequest
00212   _response_class = MergeTracksResponse


sba
Author(s): Kurt Konolige, Helen Oleynikova
autogenerated on Thu Jan 2 2014 12:12:08