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


particle_plume
Author(s): Gonçalo Cabrita and Pedro Sousa
autogenerated on Mon Jan 6 2014 11:27:46