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


collider
Author(s): Adam Harmat, Gil E. Jones, Kai M. Wurm, Armin Hornung. Maintained by Gil E. Jones
autogenerated on Thu Dec 12 2013 11:07:38