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


hrl_phri_2011
Author(s): Kelsey Hawkins
autogenerated on Wed Nov 27 2013 12:22:39