_LookupTransformActionGoal.py
Go to the documentation of this file.
00001 """autogenerated by genpy from tf2_msgs/LookupTransformActionGoal.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 genpy
00008 import actionlib_msgs.msg
00009 import tf2_msgs.msg
00010 import std_msgs.msg
00011 
00012 class LookupTransformActionGoal(genpy.Message):
00013   _md5sum = "f2e7bcdb75c847978d0351a13e699da5"
00014   _type = "tf2_msgs/LookupTransformActionGoal"
00015   _has_header = True #flag to mark the presence of a Header object
00016   _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00017 
00018 Header header
00019 actionlib_msgs/GoalID goal_id
00020 LookupTransformGoal goal
00021 
00022 ================================================================================
00023 MSG: std_msgs/Header
00024 # Standard metadata for higher-level stamped data types.
00025 # This is generally used to communicate timestamped data 
00026 # in a particular coordinate frame.
00027 # 
00028 # sequence ID: consecutively increasing ID 
00029 uint32 seq
00030 #Two-integer timestamp that is expressed as:
00031 # * stamp.secs: seconds (stamp_secs) since epoch
00032 # * stamp.nsecs: nanoseconds since stamp_secs
00033 # time-handling sugar is provided by the client library
00034 time stamp
00035 #Frame this data is associated with
00036 # 0: no frame
00037 # 1: global frame
00038 string frame_id
00039 
00040 ================================================================================
00041 MSG: actionlib_msgs/GoalID
00042 # The stamp should store the time at which this goal was requested.
00043 # It is used by an action server when it tries to preempt all
00044 # goals that were requested before a certain time
00045 time stamp
00046 
00047 # The id provides a way to associate feedback and
00048 # result message with specific goal requests. The id
00049 # specified must be unique.
00050 string id
00051 
00052 
00053 ================================================================================
00054 MSG: tf2_msgs/LookupTransformGoal
00055 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00056 #Simple API
00057 string target_frame
00058 string source_frame
00059 time source_time
00060 duration timeout
00061 
00062 #Advanced API
00063 time target_time
00064 string fixed_frame
00065 
00066 #Whether or not to use the advanced API
00067 bool advanced
00068 
00069 
00070 """
00071   __slots__ = ['header','goal_id','goal']
00072   _slot_types = ['std_msgs/Header','actionlib_msgs/GoalID','tf2_msgs/LookupTransformGoal']
00073 
00074   def __init__(self, *args, **kwds):
00075     """
00076     Constructor. Any message fields that are implicitly/explicitly
00077     set to None will be assigned a default value. The recommend
00078     use is keyword arguments as this is more robust to future message
00079     changes.  You cannot mix in-order arguments and keyword arguments.
00080 
00081     The available fields are:
00082        header,goal_id,goal
00083 
00084     :param args: complete set of field values, in .msg order
00085     :param kwds: use keyword arguments corresponding to message field names
00086     to set specific fields.
00087     """
00088     if args or kwds:
00089       super(LookupTransformActionGoal, self).__init__(*args, **kwds)
00090       #message fields cannot be None, assign default values for those that are
00091       if self.header is None:
00092         self.header = std_msgs.msg.Header()
00093       if self.goal_id is None:
00094         self.goal_id = actionlib_msgs.msg.GoalID()
00095       if self.goal is None:
00096         self.goal = tf2_msgs.msg.LookupTransformGoal()
00097     else:
00098       self.header = std_msgs.msg.Header()
00099       self.goal_id = actionlib_msgs.msg.GoalID()
00100       self.goal = tf2_msgs.msg.LookupTransformGoal()
00101 
00102   def _get_types(self):
00103     """
00104     internal API method
00105     """
00106     return self._slot_types
00107 
00108   def serialize(self, buff):
00109     """
00110     serialize message into buffer
00111     :param buff: buffer, ``StringIO``
00112     """
00113     try:
00114       _x = self
00115       buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs))
00116       _x = self.header.frame_id
00117       length = len(_x)
00118       if python3 or type(_x) == unicode:
00119         _x = _x.encode('utf-8')
00120         length = len(_x)
00121       buff.write(struct.pack('<I%ss'%length, length, _x))
00122       _x = self
00123       buff.write(_struct_2I.pack(_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs))
00124       _x = self.goal_id.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.goal.target_frame
00131       length = len(_x)
00132       if python3 or type(_x) == unicode:
00133         _x = _x.encode('utf-8')
00134         length = len(_x)
00135       buff.write(struct.pack('<I%ss'%length, length, _x))
00136       _x = self.goal.source_frame
00137       length = len(_x)
00138       if python3 or type(_x) == unicode:
00139         _x = _x.encode('utf-8')
00140         length = len(_x)
00141       buff.write(struct.pack('<I%ss'%length, length, _x))
00142       _x = self
00143       buff.write(_struct_2I2i2I.pack(_x.goal.source_time.secs, _x.goal.source_time.nsecs, _x.goal.timeout.secs, _x.goal.timeout.nsecs, _x.goal.target_time.secs, _x.goal.target_time.nsecs))
00144       _x = self.goal.fixed_frame
00145       length = len(_x)
00146       if python3 or type(_x) == unicode:
00147         _x = _x.encode('utf-8')
00148         length = len(_x)
00149       buff.write(struct.pack('<I%ss'%length, length, _x))
00150       buff.write(_struct_B.pack(self.goal.advanced))
00151     except struct.error as se: self._check_types(se)
00152     except TypeError as te: self._check_types(te)
00153 
00154   def deserialize(self, str):
00155     """
00156     unpack serialized message in str into this message instance
00157     :param str: byte array of serialized message, ``str``
00158     """
00159     try:
00160       if self.header is None:
00161         self.header = std_msgs.msg.Header()
00162       if self.goal_id is None:
00163         self.goal_id = actionlib_msgs.msg.GoalID()
00164       if self.goal is None:
00165         self.goal = tf2_msgs.msg.LookupTransformGoal()
00166       end = 0
00167       _x = self
00168       start = end
00169       end += 12
00170       (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00171       start = end
00172       end += 4
00173       (length,) = _struct_I.unpack(str[start:end])
00174       start = end
00175       end += length
00176       if python3:
00177         self.header.frame_id = str[start:end].decode('utf-8')
00178       else:
00179         self.header.frame_id = str[start:end]
00180       _x = self
00181       start = end
00182       end += 8
00183       (_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00184       start = end
00185       end += 4
00186       (length,) = _struct_I.unpack(str[start:end])
00187       start = end
00188       end += length
00189       if python3:
00190         self.goal_id.id = str[start:end].decode('utf-8')
00191       else:
00192         self.goal_id.id = str[start:end]
00193       start = end
00194       end += 4
00195       (length,) = _struct_I.unpack(str[start:end])
00196       start = end
00197       end += length
00198       if python3:
00199         self.goal.target_frame = str[start:end].decode('utf-8')
00200       else:
00201         self.goal.target_frame = str[start:end]
00202       start = end
00203       end += 4
00204       (length,) = _struct_I.unpack(str[start:end])
00205       start = end
00206       end += length
00207       if python3:
00208         self.goal.source_frame = str[start:end].decode('utf-8')
00209       else:
00210         self.goal.source_frame = str[start:end]
00211       _x = self
00212       start = end
00213       end += 24
00214       (_x.goal.source_time.secs, _x.goal.source_time.nsecs, _x.goal.timeout.secs, _x.goal.timeout.nsecs, _x.goal.target_time.secs, _x.goal.target_time.nsecs,) = _struct_2I2i2I.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.goal.fixed_frame = str[start:end].decode('utf-8')
00222       else:
00223         self.goal.fixed_frame = str[start:end]
00224       start = end
00225       end += 1
00226       (self.goal.advanced,) = _struct_B.unpack(str[start:end])
00227       self.goal.advanced = bool(self.goal.advanced)
00228       return self
00229     except struct.error as e:
00230       raise genpy.DeserializationError(e) #most likely buffer underfill
00231 
00232 
00233   def serialize_numpy(self, buff, numpy):
00234     """
00235     serialize message with numpy array types into buffer
00236     :param buff: buffer, ``StringIO``
00237     :param numpy: numpy python module
00238     """
00239     try:
00240       _x = self
00241       buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs))
00242       _x = self.header.frame_id
00243       length = len(_x)
00244       if python3 or type(_x) == unicode:
00245         _x = _x.encode('utf-8')
00246         length = len(_x)
00247       buff.write(struct.pack('<I%ss'%length, length, _x))
00248       _x = self
00249       buff.write(_struct_2I.pack(_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs))
00250       _x = self.goal_id.id
00251       length = len(_x)
00252       if python3 or type(_x) == unicode:
00253         _x = _x.encode('utf-8')
00254         length = len(_x)
00255       buff.write(struct.pack('<I%ss'%length, length, _x))
00256       _x = self.goal.target_frame
00257       length = len(_x)
00258       if python3 or type(_x) == unicode:
00259         _x = _x.encode('utf-8')
00260         length = len(_x)
00261       buff.write(struct.pack('<I%ss'%length, length, _x))
00262       _x = self.goal.source_frame
00263       length = len(_x)
00264       if python3 or type(_x) == unicode:
00265         _x = _x.encode('utf-8')
00266         length = len(_x)
00267       buff.write(struct.pack('<I%ss'%length, length, _x))
00268       _x = self
00269       buff.write(_struct_2I2i2I.pack(_x.goal.source_time.secs, _x.goal.source_time.nsecs, _x.goal.timeout.secs, _x.goal.timeout.nsecs, _x.goal.target_time.secs, _x.goal.target_time.nsecs))
00270       _x = self.goal.fixed_frame
00271       length = len(_x)
00272       if python3 or type(_x) == unicode:
00273         _x = _x.encode('utf-8')
00274         length = len(_x)
00275       buff.write(struct.pack('<I%ss'%length, length, _x))
00276       buff.write(_struct_B.pack(self.goal.advanced))
00277     except struct.error as se: self._check_types(se)
00278     except TypeError as te: self._check_types(te)
00279 
00280   def deserialize_numpy(self, str, numpy):
00281     """
00282     unpack serialized message in str into this message instance using numpy for array types
00283     :param str: byte array of serialized message, ``str``
00284     :param numpy: numpy python module
00285     """
00286     try:
00287       if self.header is None:
00288         self.header = std_msgs.msg.Header()
00289       if self.goal_id is None:
00290         self.goal_id = actionlib_msgs.msg.GoalID()
00291       if self.goal is None:
00292         self.goal = tf2_msgs.msg.LookupTransformGoal()
00293       end = 0
00294       _x = self
00295       start = end
00296       end += 12
00297       (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00298       start = end
00299       end += 4
00300       (length,) = _struct_I.unpack(str[start:end])
00301       start = end
00302       end += length
00303       if python3:
00304         self.header.frame_id = str[start:end].decode('utf-8')
00305       else:
00306         self.header.frame_id = str[start:end]
00307       _x = self
00308       start = end
00309       end += 8
00310       (_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00311       start = end
00312       end += 4
00313       (length,) = _struct_I.unpack(str[start:end])
00314       start = end
00315       end += length
00316       if python3:
00317         self.goal_id.id = str[start:end].decode('utf-8')
00318       else:
00319         self.goal_id.id = str[start:end]
00320       start = end
00321       end += 4
00322       (length,) = _struct_I.unpack(str[start:end])
00323       start = end
00324       end += length
00325       if python3:
00326         self.goal.target_frame = str[start:end].decode('utf-8')
00327       else:
00328         self.goal.target_frame = str[start:end]
00329       start = end
00330       end += 4
00331       (length,) = _struct_I.unpack(str[start:end])
00332       start = end
00333       end += length
00334       if python3:
00335         self.goal.source_frame = str[start:end].decode('utf-8')
00336       else:
00337         self.goal.source_frame = str[start:end]
00338       _x = self
00339       start = end
00340       end += 24
00341       (_x.goal.source_time.secs, _x.goal.source_time.nsecs, _x.goal.timeout.secs, _x.goal.timeout.nsecs, _x.goal.target_time.secs, _x.goal.target_time.nsecs,) = _struct_2I2i2I.unpack(str[start:end])
00342       start = end
00343       end += 4
00344       (length,) = _struct_I.unpack(str[start:end])
00345       start = end
00346       end += length
00347       if python3:
00348         self.goal.fixed_frame = str[start:end].decode('utf-8')
00349       else:
00350         self.goal.fixed_frame = str[start:end]
00351       start = end
00352       end += 1
00353       (self.goal.advanced,) = _struct_B.unpack(str[start:end])
00354       self.goal.advanced = bool(self.goal.advanced)
00355       return self
00356     except struct.error as e:
00357       raise genpy.DeserializationError(e) #most likely buffer underfill
00358 
00359 _struct_I = genpy.struct_I
00360 _struct_3I = struct.Struct("<3I")
00361 _struct_B = struct.Struct("<B")
00362 _struct_2I = struct.Struct("<2I")
00363 _struct_2I2i2I = struct.Struct("<2I2i2I")
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends


tf2_msgs
Author(s): Eitan Marder-Eppstein
autogenerated on Mon Aug 19 2013 10:26:46