_HeadLookAction.py
Go to the documentation of this file.
00001 """autogenerated by genpy from move_arm_head_monitor/HeadLookAction.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 move_arm_head_monitor.msg
00008 import genpy
00009 import actionlib_msgs.msg
00010 import std_msgs.msg
00011 
00012 class HeadLookAction(genpy.Message):
00013   _md5sum = "69da16a00a0c11ceee16f92967c6664b"
00014   _type = "move_arm_head_monitor/HeadLookAction"
00015   _has_header = False #flag to mark the presence of a Header object
00016   _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00017 
00018 HeadLookActionGoal action_goal
00019 HeadLookActionResult action_result
00020 HeadLookActionFeedback action_feedback
00021 
00022 ================================================================================
00023 MSG: move_arm_head_monitor/HeadLookActionGoal
00024 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00025 
00026 Header header
00027 actionlib_msgs/GoalID goal_id
00028 HeadLookGoal goal
00029 
00030 ================================================================================
00031 MSG: std_msgs/Header
00032 # Standard metadata for higher-level stamped data types.
00033 # This is generally used to communicate timestamped data 
00034 # in a particular coordinate frame.
00035 # 
00036 # sequence ID: consecutively increasing ID 
00037 uint32 seq
00038 #Two-integer timestamp that is expressed as:
00039 # * stamp.secs: seconds (stamp_secs) since epoch
00040 # * stamp.nsecs: nanoseconds since stamp_secs
00041 # time-handling sugar is provided by the client library
00042 time stamp
00043 #Frame this data is associated with
00044 # 0: no frame
00045 # 1: global frame
00046 string frame_id
00047 
00048 ================================================================================
00049 MSG: actionlib_msgs/GoalID
00050 # The stamp should store the time at which this goal was requested.
00051 # It is used by an action server when it tries to preempt all
00052 # goals that were requested before a certain time
00053 time stamp
00054 
00055 # The id provides a way to associate feedback and
00056 # result message with specific goal requests. The id
00057 # specified must be unique.
00058 string id
00059 
00060 
00061 ================================================================================
00062 MSG: move_arm_head_monitor/HeadLookGoal
00063 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00064 #goal definition
00065 time target_time
00066 string target_link
00067 float32 target_x
00068 float32 target_y
00069 float32 target_z
00070 
00071 ================================================================================
00072 MSG: move_arm_head_monitor/HeadLookActionResult
00073 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00074 
00075 Header header
00076 actionlib_msgs/GoalStatus status
00077 HeadLookResult result
00078 
00079 ================================================================================
00080 MSG: actionlib_msgs/GoalStatus
00081 GoalID goal_id
00082 uint8 status
00083 uint8 PENDING         = 0   # The goal has yet to be processed by the action server
00084 uint8 ACTIVE          = 1   # The goal is currently being processed by the action server
00085 uint8 PREEMPTED       = 2   # The goal received a cancel request after it started executing
00086                             #   and has since completed its execution (Terminal State)
00087 uint8 SUCCEEDED       = 3   # The goal was achieved successfully by the action server (Terminal State)
00088 uint8 ABORTED         = 4   # The goal was aborted during execution by the action server due
00089                             #    to some failure (Terminal State)
00090 uint8 REJECTED        = 5   # The goal was rejected by the action server without being processed,
00091                             #    because the goal was unattainable or invalid (Terminal State)
00092 uint8 PREEMPTING      = 6   # The goal received a cancel request after it started executing
00093                             #    and has not yet completed execution
00094 uint8 RECALLING       = 7   # The goal received a cancel request before it started executing,
00095                             #    but the action server has not yet confirmed that the goal is canceled
00096 uint8 RECALLED        = 8   # The goal received a cancel request before it started executing
00097                             #    and was successfully cancelled (Terminal State)
00098 uint8 LOST            = 9   # An action client can determine that a goal is LOST. This should not be
00099                             #    sent over the wire by an action server
00100 
00101 #Allow for the user to associate a string with GoalStatus for debugging
00102 string text
00103 
00104 
00105 ================================================================================
00106 MSG: move_arm_head_monitor/HeadLookResult
00107 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00108 #result definition
00109 actionlib_msgs/GoalStatus resultStatus
00110 
00111 ================================================================================
00112 MSG: move_arm_head_monitor/HeadLookActionFeedback
00113 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00114 
00115 Header header
00116 actionlib_msgs/GoalStatus status
00117 HeadLookFeedback feedback
00118 
00119 ================================================================================
00120 MSG: move_arm_head_monitor/HeadLookFeedback
00121 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00122 #feedback
00123 actionlib_msgs/GoalStatus feedbackStatus
00124 
00125 
00126 """
00127   __slots__ = ['action_goal','action_result','action_feedback']
00128   _slot_types = ['move_arm_head_monitor/HeadLookActionGoal','move_arm_head_monitor/HeadLookActionResult','move_arm_head_monitor/HeadLookActionFeedback']
00129 
00130   def __init__(self, *args, **kwds):
00131     """
00132     Constructor. Any message fields that are implicitly/explicitly
00133     set to None will be assigned a default value. The recommend
00134     use is keyword arguments as this is more robust to future message
00135     changes.  You cannot mix in-order arguments and keyword arguments.
00136 
00137     The available fields are:
00138        action_goal,action_result,action_feedback
00139 
00140     :param args: complete set of field values, in .msg order
00141     :param kwds: use keyword arguments corresponding to message field names
00142     to set specific fields.
00143     """
00144     if args or kwds:
00145       super(HeadLookAction, self).__init__(*args, **kwds)
00146       #message fields cannot be None, assign default values for those that are
00147       if self.action_goal is None:
00148         self.action_goal = move_arm_head_monitor.msg.HeadLookActionGoal()
00149       if self.action_result is None:
00150         self.action_result = move_arm_head_monitor.msg.HeadLookActionResult()
00151       if self.action_feedback is None:
00152         self.action_feedback = move_arm_head_monitor.msg.HeadLookActionFeedback()
00153     else:
00154       self.action_goal = move_arm_head_monitor.msg.HeadLookActionGoal()
00155       self.action_result = move_arm_head_monitor.msg.HeadLookActionResult()
00156       self.action_feedback = move_arm_head_monitor.msg.HeadLookActionFeedback()
00157 
00158   def _get_types(self):
00159     """
00160     internal API method
00161     """
00162     return self._slot_types
00163 
00164   def serialize(self, buff):
00165     """
00166     serialize message into buffer
00167     :param buff: buffer, ``StringIO``
00168     """
00169     try:
00170       _x = self
00171       buff.write(_struct_3I.pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
00172       _x = self.action_goal.header.frame_id
00173       length = len(_x)
00174       if python3 or type(_x) == unicode:
00175         _x = _x.encode('utf-8')
00176         length = len(_x)
00177       buff.write(struct.pack('<I%ss'%length, length, _x))
00178       _x = self
00179       buff.write(_struct_2I.pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
00180       _x = self.action_goal.goal_id.id
00181       length = len(_x)
00182       if python3 or type(_x) == unicode:
00183         _x = _x.encode('utf-8')
00184         length = len(_x)
00185       buff.write(struct.pack('<I%ss'%length, length, _x))
00186       _x = self
00187       buff.write(_struct_2I.pack(_x.action_goal.goal.target_time.secs, _x.action_goal.goal.target_time.nsecs))
00188       _x = self.action_goal.goal.target_link
00189       length = len(_x)
00190       if python3 or type(_x) == unicode:
00191         _x = _x.encode('utf-8')
00192         length = len(_x)
00193       buff.write(struct.pack('<I%ss'%length, length, _x))
00194       _x = self
00195       buff.write(_struct_3f3I.pack(_x.action_goal.goal.target_x, _x.action_goal.goal.target_y, _x.action_goal.goal.target_z, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
00196       _x = self.action_result.header.frame_id
00197       length = len(_x)
00198       if python3 or type(_x) == unicode:
00199         _x = _x.encode('utf-8')
00200         length = len(_x)
00201       buff.write(struct.pack('<I%ss'%length, length, _x))
00202       _x = self
00203       buff.write(_struct_2I.pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
00204       _x = self.action_result.status.goal_id.id
00205       length = len(_x)
00206       if python3 or type(_x) == unicode:
00207         _x = _x.encode('utf-8')
00208         length = len(_x)
00209       buff.write(struct.pack('<I%ss'%length, length, _x))
00210       buff.write(_struct_B.pack(self.action_result.status.status))
00211       _x = self.action_result.status.text
00212       length = len(_x)
00213       if python3 or type(_x) == unicode:
00214         _x = _x.encode('utf-8')
00215         length = len(_x)
00216       buff.write(struct.pack('<I%ss'%length, length, _x))
00217       _x = self
00218       buff.write(_struct_2I.pack(_x.action_result.result.resultStatus.goal_id.stamp.secs, _x.action_result.result.resultStatus.goal_id.stamp.nsecs))
00219       _x = self.action_result.result.resultStatus.goal_id.id
00220       length = len(_x)
00221       if python3 or type(_x) == unicode:
00222         _x = _x.encode('utf-8')
00223         length = len(_x)
00224       buff.write(struct.pack('<I%ss'%length, length, _x))
00225       buff.write(_struct_B.pack(self.action_result.result.resultStatus.status))
00226       _x = self.action_result.result.resultStatus.text
00227       length = len(_x)
00228       if python3 or type(_x) == unicode:
00229         _x = _x.encode('utf-8')
00230         length = len(_x)
00231       buff.write(struct.pack('<I%ss'%length, length, _x))
00232       _x = self
00233       buff.write(_struct_3I.pack(_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
00234       _x = self.action_feedback.header.frame_id
00235       length = len(_x)
00236       if python3 or type(_x) == unicode:
00237         _x = _x.encode('utf-8')
00238         length = len(_x)
00239       buff.write(struct.pack('<I%ss'%length, length, _x))
00240       _x = self
00241       buff.write(_struct_2I.pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
00242       _x = self.action_feedback.status.goal_id.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       buff.write(_struct_B.pack(self.action_feedback.status.status))
00249       _x = self.action_feedback.status.text
00250       length = len(_x)
00251       if python3 or type(_x) == unicode:
00252         _x = _x.encode('utf-8')
00253         length = len(_x)
00254       buff.write(struct.pack('<I%ss'%length, length, _x))
00255       _x = self
00256       buff.write(_struct_2I.pack(_x.action_feedback.feedback.feedbackStatus.goal_id.stamp.secs, _x.action_feedback.feedback.feedbackStatus.goal_id.stamp.nsecs))
00257       _x = self.action_feedback.feedback.feedbackStatus.goal_id.id
00258       length = len(_x)
00259       if python3 or type(_x) == unicode:
00260         _x = _x.encode('utf-8')
00261         length = len(_x)
00262       buff.write(struct.pack('<I%ss'%length, length, _x))
00263       buff.write(_struct_B.pack(self.action_feedback.feedback.feedbackStatus.status))
00264       _x = self.action_feedback.feedback.feedbackStatus.text
00265       length = len(_x)
00266       if python3 or type(_x) == unicode:
00267         _x = _x.encode('utf-8')
00268         length = len(_x)
00269       buff.write(struct.pack('<I%ss'%length, length, _x))
00270     except struct.error as se: self._check_types(se)
00271     except TypeError as te: self._check_types(te)
00272 
00273   def deserialize(self, str):
00274     """
00275     unpack serialized message in str into this message instance
00276     :param str: byte array of serialized message, ``str``
00277     """
00278     try:
00279       if self.action_goal is None:
00280         self.action_goal = move_arm_head_monitor.msg.HeadLookActionGoal()
00281       if self.action_result is None:
00282         self.action_result = move_arm_head_monitor.msg.HeadLookActionResult()
00283       if self.action_feedback is None:
00284         self.action_feedback = move_arm_head_monitor.msg.HeadLookActionFeedback()
00285       end = 0
00286       _x = self
00287       start = end
00288       end += 12
00289       (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00290       start = end
00291       end += 4
00292       (length,) = _struct_I.unpack(str[start:end])
00293       start = end
00294       end += length
00295       if python3:
00296         self.action_goal.header.frame_id = str[start:end].decode('utf-8')
00297       else:
00298         self.action_goal.header.frame_id = str[start:end]
00299       _x = self
00300       start = end
00301       end += 8
00302       (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00303       start = end
00304       end += 4
00305       (length,) = _struct_I.unpack(str[start:end])
00306       start = end
00307       end += length
00308       if python3:
00309         self.action_goal.goal_id.id = str[start:end].decode('utf-8')
00310       else:
00311         self.action_goal.goal_id.id = str[start:end]
00312       _x = self
00313       start = end
00314       end += 8
00315       (_x.action_goal.goal.target_time.secs, _x.action_goal.goal.target_time.nsecs,) = _struct_2I.unpack(str[start:end])
00316       start = end
00317       end += 4
00318       (length,) = _struct_I.unpack(str[start:end])
00319       start = end
00320       end += length
00321       if python3:
00322         self.action_goal.goal.target_link = str[start:end].decode('utf-8')
00323       else:
00324         self.action_goal.goal.target_link = str[start:end]
00325       _x = self
00326       start = end
00327       end += 24
00328       (_x.action_goal.goal.target_x, _x.action_goal.goal.target_y, _x.action_goal.goal.target_z, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _struct_3f3I.unpack(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.action_result.header.frame_id = str[start:end].decode('utf-8')
00336       else:
00337         self.action_result.header.frame_id = str[start:end]
00338       _x = self
00339       start = end
00340       end += 8
00341       (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _struct_2I.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.action_result.status.goal_id.id = str[start:end].decode('utf-8')
00349       else:
00350         self.action_result.status.goal_id.id = str[start:end]
00351       start = end
00352       end += 1
00353       (self.action_result.status.status,) = _struct_B.unpack(str[start:end])
00354       start = end
00355       end += 4
00356       (length,) = _struct_I.unpack(str[start:end])
00357       start = end
00358       end += length
00359       if python3:
00360         self.action_result.status.text = str[start:end].decode('utf-8')
00361       else:
00362         self.action_result.status.text = str[start:end]
00363       _x = self
00364       start = end
00365       end += 8
00366       (_x.action_result.result.resultStatus.goal_id.stamp.secs, _x.action_result.result.resultStatus.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00367       start = end
00368       end += 4
00369       (length,) = _struct_I.unpack(str[start:end])
00370       start = end
00371       end += length
00372       if python3:
00373         self.action_result.result.resultStatus.goal_id.id = str[start:end].decode('utf-8')
00374       else:
00375         self.action_result.result.resultStatus.goal_id.id = str[start:end]
00376       start = end
00377       end += 1
00378       (self.action_result.result.resultStatus.status,) = _struct_B.unpack(str[start:end])
00379       start = end
00380       end += 4
00381       (length,) = _struct_I.unpack(str[start:end])
00382       start = end
00383       end += length
00384       if python3:
00385         self.action_result.result.resultStatus.text = str[start:end].decode('utf-8')
00386       else:
00387         self.action_result.result.resultStatus.text = str[start:end]
00388       _x = self
00389       start = end
00390       end += 12
00391       (_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00392       start = end
00393       end += 4
00394       (length,) = _struct_I.unpack(str[start:end])
00395       start = end
00396       end += length
00397       if python3:
00398         self.action_feedback.header.frame_id = str[start:end].decode('utf-8')
00399       else:
00400         self.action_feedback.header.frame_id = str[start:end]
00401       _x = self
00402       start = end
00403       end += 8
00404       (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00405       start = end
00406       end += 4
00407       (length,) = _struct_I.unpack(str[start:end])
00408       start = end
00409       end += length
00410       if python3:
00411         self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8')
00412       else:
00413         self.action_feedback.status.goal_id.id = str[start:end]
00414       start = end
00415       end += 1
00416       (self.action_feedback.status.status,) = _struct_B.unpack(str[start:end])
00417       start = end
00418       end += 4
00419       (length,) = _struct_I.unpack(str[start:end])
00420       start = end
00421       end += length
00422       if python3:
00423         self.action_feedback.status.text = str[start:end].decode('utf-8')
00424       else:
00425         self.action_feedback.status.text = str[start:end]
00426       _x = self
00427       start = end
00428       end += 8
00429       (_x.action_feedback.feedback.feedbackStatus.goal_id.stamp.secs, _x.action_feedback.feedback.feedbackStatus.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00430       start = end
00431       end += 4
00432       (length,) = _struct_I.unpack(str[start:end])
00433       start = end
00434       end += length
00435       if python3:
00436         self.action_feedback.feedback.feedbackStatus.goal_id.id = str[start:end].decode('utf-8')
00437       else:
00438         self.action_feedback.feedback.feedbackStatus.goal_id.id = str[start:end]
00439       start = end
00440       end += 1
00441       (self.action_feedback.feedback.feedbackStatus.status,) = _struct_B.unpack(str[start:end])
00442       start = end
00443       end += 4
00444       (length,) = _struct_I.unpack(str[start:end])
00445       start = end
00446       end += length
00447       if python3:
00448         self.action_feedback.feedback.feedbackStatus.text = str[start:end].decode('utf-8')
00449       else:
00450         self.action_feedback.feedback.feedbackStatus.text = str[start:end]
00451       return self
00452     except struct.error as e:
00453       raise genpy.DeserializationError(e) #most likely buffer underfill
00454 
00455 
00456   def serialize_numpy(self, buff, numpy):
00457     """
00458     serialize message with numpy array types into buffer
00459     :param buff: buffer, ``StringIO``
00460     :param numpy: numpy python module
00461     """
00462     try:
00463       _x = self
00464       buff.write(_struct_3I.pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
00465       _x = self.action_goal.header.frame_id
00466       length = len(_x)
00467       if python3 or type(_x) == unicode:
00468         _x = _x.encode('utf-8')
00469         length = len(_x)
00470       buff.write(struct.pack('<I%ss'%length, length, _x))
00471       _x = self
00472       buff.write(_struct_2I.pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
00473       _x = self.action_goal.goal_id.id
00474       length = len(_x)
00475       if python3 or type(_x) == unicode:
00476         _x = _x.encode('utf-8')
00477         length = len(_x)
00478       buff.write(struct.pack('<I%ss'%length, length, _x))
00479       _x = self
00480       buff.write(_struct_2I.pack(_x.action_goal.goal.target_time.secs, _x.action_goal.goal.target_time.nsecs))
00481       _x = self.action_goal.goal.target_link
00482       length = len(_x)
00483       if python3 or type(_x) == unicode:
00484         _x = _x.encode('utf-8')
00485         length = len(_x)
00486       buff.write(struct.pack('<I%ss'%length, length, _x))
00487       _x = self
00488       buff.write(_struct_3f3I.pack(_x.action_goal.goal.target_x, _x.action_goal.goal.target_y, _x.action_goal.goal.target_z, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
00489       _x = self.action_result.header.frame_id
00490       length = len(_x)
00491       if python3 or type(_x) == unicode:
00492         _x = _x.encode('utf-8')
00493         length = len(_x)
00494       buff.write(struct.pack('<I%ss'%length, length, _x))
00495       _x = self
00496       buff.write(_struct_2I.pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
00497       _x = self.action_result.status.goal_id.id
00498       length = len(_x)
00499       if python3 or type(_x) == unicode:
00500         _x = _x.encode('utf-8')
00501         length = len(_x)
00502       buff.write(struct.pack('<I%ss'%length, length, _x))
00503       buff.write(_struct_B.pack(self.action_result.status.status))
00504       _x = self.action_result.status.text
00505       length = len(_x)
00506       if python3 or type(_x) == unicode:
00507         _x = _x.encode('utf-8')
00508         length = len(_x)
00509       buff.write(struct.pack('<I%ss'%length, length, _x))
00510       _x = self
00511       buff.write(_struct_2I.pack(_x.action_result.result.resultStatus.goal_id.stamp.secs, _x.action_result.result.resultStatus.goal_id.stamp.nsecs))
00512       _x = self.action_result.result.resultStatus.goal_id.id
00513       length = len(_x)
00514       if python3 or type(_x) == unicode:
00515         _x = _x.encode('utf-8')
00516         length = len(_x)
00517       buff.write(struct.pack('<I%ss'%length, length, _x))
00518       buff.write(_struct_B.pack(self.action_result.result.resultStatus.status))
00519       _x = self.action_result.result.resultStatus.text
00520       length = len(_x)
00521       if python3 or type(_x) == unicode:
00522         _x = _x.encode('utf-8')
00523         length = len(_x)
00524       buff.write(struct.pack('<I%ss'%length, length, _x))
00525       _x = self
00526       buff.write(_struct_3I.pack(_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
00527       _x = self.action_feedback.header.frame_id
00528       length = len(_x)
00529       if python3 or type(_x) == unicode:
00530         _x = _x.encode('utf-8')
00531         length = len(_x)
00532       buff.write(struct.pack('<I%ss'%length, length, _x))
00533       _x = self
00534       buff.write(_struct_2I.pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
00535       _x = self.action_feedback.status.goal_id.id
00536       length = len(_x)
00537       if python3 or type(_x) == unicode:
00538         _x = _x.encode('utf-8')
00539         length = len(_x)
00540       buff.write(struct.pack('<I%ss'%length, length, _x))
00541       buff.write(_struct_B.pack(self.action_feedback.status.status))
00542       _x = self.action_feedback.status.text
00543       length = len(_x)
00544       if python3 or type(_x) == unicode:
00545         _x = _x.encode('utf-8')
00546         length = len(_x)
00547       buff.write(struct.pack('<I%ss'%length, length, _x))
00548       _x = self
00549       buff.write(_struct_2I.pack(_x.action_feedback.feedback.feedbackStatus.goal_id.stamp.secs, _x.action_feedback.feedback.feedbackStatus.goal_id.stamp.nsecs))
00550       _x = self.action_feedback.feedback.feedbackStatus.goal_id.id
00551       length = len(_x)
00552       if python3 or type(_x) == unicode:
00553         _x = _x.encode('utf-8')
00554         length = len(_x)
00555       buff.write(struct.pack('<I%ss'%length, length, _x))
00556       buff.write(_struct_B.pack(self.action_feedback.feedback.feedbackStatus.status))
00557       _x = self.action_feedback.feedback.feedbackStatus.text
00558       length = len(_x)
00559       if python3 or type(_x) == unicode:
00560         _x = _x.encode('utf-8')
00561         length = len(_x)
00562       buff.write(struct.pack('<I%ss'%length, length, _x))
00563     except struct.error as se: self._check_types(se)
00564     except TypeError as te: self._check_types(te)
00565 
00566   def deserialize_numpy(self, str, numpy):
00567     """
00568     unpack serialized message in str into this message instance using numpy for array types
00569     :param str: byte array of serialized message, ``str``
00570     :param numpy: numpy python module
00571     """
00572     try:
00573       if self.action_goal is None:
00574         self.action_goal = move_arm_head_monitor.msg.HeadLookActionGoal()
00575       if self.action_result is None:
00576         self.action_result = move_arm_head_monitor.msg.HeadLookActionResult()
00577       if self.action_feedback is None:
00578         self.action_feedback = move_arm_head_monitor.msg.HeadLookActionFeedback()
00579       end = 0
00580       _x = self
00581       start = end
00582       end += 12
00583       (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00584       start = end
00585       end += 4
00586       (length,) = _struct_I.unpack(str[start:end])
00587       start = end
00588       end += length
00589       if python3:
00590         self.action_goal.header.frame_id = str[start:end].decode('utf-8')
00591       else:
00592         self.action_goal.header.frame_id = str[start:end]
00593       _x = self
00594       start = end
00595       end += 8
00596       (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00597       start = end
00598       end += 4
00599       (length,) = _struct_I.unpack(str[start:end])
00600       start = end
00601       end += length
00602       if python3:
00603         self.action_goal.goal_id.id = str[start:end].decode('utf-8')
00604       else:
00605         self.action_goal.goal_id.id = str[start:end]
00606       _x = self
00607       start = end
00608       end += 8
00609       (_x.action_goal.goal.target_time.secs, _x.action_goal.goal.target_time.nsecs,) = _struct_2I.unpack(str[start:end])
00610       start = end
00611       end += 4
00612       (length,) = _struct_I.unpack(str[start:end])
00613       start = end
00614       end += length
00615       if python3:
00616         self.action_goal.goal.target_link = str[start:end].decode('utf-8')
00617       else:
00618         self.action_goal.goal.target_link = str[start:end]
00619       _x = self
00620       start = end
00621       end += 24
00622       (_x.action_goal.goal.target_x, _x.action_goal.goal.target_y, _x.action_goal.goal.target_z, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _struct_3f3I.unpack(str[start:end])
00623       start = end
00624       end += 4
00625       (length,) = _struct_I.unpack(str[start:end])
00626       start = end
00627       end += length
00628       if python3:
00629         self.action_result.header.frame_id = str[start:end].decode('utf-8')
00630       else:
00631         self.action_result.header.frame_id = str[start:end]
00632       _x = self
00633       start = end
00634       end += 8
00635       (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00636       start = end
00637       end += 4
00638       (length,) = _struct_I.unpack(str[start:end])
00639       start = end
00640       end += length
00641       if python3:
00642         self.action_result.status.goal_id.id = str[start:end].decode('utf-8')
00643       else:
00644         self.action_result.status.goal_id.id = str[start:end]
00645       start = end
00646       end += 1
00647       (self.action_result.status.status,) = _struct_B.unpack(str[start:end])
00648       start = end
00649       end += 4
00650       (length,) = _struct_I.unpack(str[start:end])
00651       start = end
00652       end += length
00653       if python3:
00654         self.action_result.status.text = str[start:end].decode('utf-8')
00655       else:
00656         self.action_result.status.text = str[start:end]
00657       _x = self
00658       start = end
00659       end += 8
00660       (_x.action_result.result.resultStatus.goal_id.stamp.secs, _x.action_result.result.resultStatus.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00661       start = end
00662       end += 4
00663       (length,) = _struct_I.unpack(str[start:end])
00664       start = end
00665       end += length
00666       if python3:
00667         self.action_result.result.resultStatus.goal_id.id = str[start:end].decode('utf-8')
00668       else:
00669         self.action_result.result.resultStatus.goal_id.id = str[start:end]
00670       start = end
00671       end += 1
00672       (self.action_result.result.resultStatus.status,) = _struct_B.unpack(str[start:end])
00673       start = end
00674       end += 4
00675       (length,) = _struct_I.unpack(str[start:end])
00676       start = end
00677       end += length
00678       if python3:
00679         self.action_result.result.resultStatus.text = str[start:end].decode('utf-8')
00680       else:
00681         self.action_result.result.resultStatus.text = str[start:end]
00682       _x = self
00683       start = end
00684       end += 12
00685       (_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00686       start = end
00687       end += 4
00688       (length,) = _struct_I.unpack(str[start:end])
00689       start = end
00690       end += length
00691       if python3:
00692         self.action_feedback.header.frame_id = str[start:end].decode('utf-8')
00693       else:
00694         self.action_feedback.header.frame_id = str[start:end]
00695       _x = self
00696       start = end
00697       end += 8
00698       (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00699       start = end
00700       end += 4
00701       (length,) = _struct_I.unpack(str[start:end])
00702       start = end
00703       end += length
00704       if python3:
00705         self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8')
00706       else:
00707         self.action_feedback.status.goal_id.id = str[start:end]
00708       start = end
00709       end += 1
00710       (self.action_feedback.status.status,) = _struct_B.unpack(str[start:end])
00711       start = end
00712       end += 4
00713       (length,) = _struct_I.unpack(str[start:end])
00714       start = end
00715       end += length
00716       if python3:
00717         self.action_feedback.status.text = str[start:end].decode('utf-8')
00718       else:
00719         self.action_feedback.status.text = str[start:end]
00720       _x = self
00721       start = end
00722       end += 8
00723       (_x.action_feedback.feedback.feedbackStatus.goal_id.stamp.secs, _x.action_feedback.feedback.feedbackStatus.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00724       start = end
00725       end += 4
00726       (length,) = _struct_I.unpack(str[start:end])
00727       start = end
00728       end += length
00729       if python3:
00730         self.action_feedback.feedback.feedbackStatus.goal_id.id = str[start:end].decode('utf-8')
00731       else:
00732         self.action_feedback.feedback.feedbackStatus.goal_id.id = str[start:end]
00733       start = end
00734       end += 1
00735       (self.action_feedback.feedback.feedbackStatus.status,) = _struct_B.unpack(str[start:end])
00736       start = end
00737       end += 4
00738       (length,) = _struct_I.unpack(str[start:end])
00739       start = end
00740       end += length
00741       if python3:
00742         self.action_feedback.feedback.feedbackStatus.text = str[start:end].decode('utf-8')
00743       else:
00744         self.action_feedback.feedback.feedbackStatus.text = str[start:end]
00745       return self
00746     except struct.error as e:
00747       raise genpy.DeserializationError(e) #most likely buffer underfill
00748 
00749 _struct_I = genpy.struct_I
00750 _struct_3I = struct.Struct("<3I")
00751 _struct_B = struct.Struct("<B")
00752 _struct_2I = struct.Struct("<2I")
00753 _struct_3f3I = struct.Struct("<3f3I")


move_arm_head_monitor
Author(s): Adam Harmat
autogenerated on Thu Dec 12 2013 11:08:12