$search
00001 """autogenerated by genmsg_py from GetPoseGoal.msg. Do not edit.""" 00002 import roslib.message 00003 import struct 00004 00005 import geometry_msgs.msg 00006 import std_msgs.msg 00007 00008 class GetPoseGoal(roslib.message.Message): 00009 _md5sum = "4d7999216d003b51bbc100bf357c806e" 00010 _type = "pr2_object_manipulation_msgs/GetPoseGoal" 00011 _has_header = False #flag to mark the presence of a Header object 00012 _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== 00013 00014 # a seed position for the pose marker. If empty (quaternion of norm 0) 00015 # the marker will be initialized at the current pose of the header frame. 00016 geometry_msgs/PoseStamped starting_pose 00017 00018 00019 ================================================================================ 00020 MSG: geometry_msgs/PoseStamped 00021 # A Pose with reference coordinate frame and timestamp 00022 Header header 00023 Pose pose 00024 00025 ================================================================================ 00026 MSG: std_msgs/Header 00027 # Standard metadata for higher-level stamped data types. 00028 # This is generally used to communicate timestamped data 00029 # in a particular coordinate frame. 00030 # 00031 # sequence ID: consecutively increasing ID 00032 uint32 seq 00033 #Two-integer timestamp that is expressed as: 00034 # * stamp.secs: seconds (stamp_secs) since epoch 00035 # * stamp.nsecs: nanoseconds since stamp_secs 00036 # time-handling sugar is provided by the client library 00037 time stamp 00038 #Frame this data is associated with 00039 # 0: no frame 00040 # 1: global frame 00041 string frame_id 00042 00043 ================================================================================ 00044 MSG: geometry_msgs/Pose 00045 # A representation of pose in free space, composed of postion and orientation. 00046 Point position 00047 Quaternion orientation 00048 00049 ================================================================================ 00050 MSG: geometry_msgs/Point 00051 # This contains the position of a point in free space 00052 float64 x 00053 float64 y 00054 float64 z 00055 00056 ================================================================================ 00057 MSG: geometry_msgs/Quaternion 00058 # This represents an orientation in free space in quaternion form. 00059 00060 float64 x 00061 float64 y 00062 float64 z 00063 float64 w 00064 00065 """ 00066 __slots__ = ['starting_pose'] 00067 _slot_types = ['geometry_msgs/PoseStamped'] 00068 00069 def __init__(self, *args, **kwds): 00070 """ 00071 Constructor. Any message fields that are implicitly/explicitly 00072 set to None will be assigned a default value. The recommend 00073 use is keyword arguments as this is more robust to future message 00074 changes. You cannot mix in-order arguments and keyword arguments. 00075 00076 The available fields are: 00077 starting_pose 00078 00079 @param args: complete set of field values, in .msg order 00080 @param kwds: use keyword arguments corresponding to message field names 00081 to set specific fields. 00082 """ 00083 if args or kwds: 00084 super(GetPoseGoal, self).__init__(*args, **kwds) 00085 #message fields cannot be None, assign default values for those that are 00086 if self.starting_pose is None: 00087 self.starting_pose = geometry_msgs.msg.PoseStamped() 00088 else: 00089 self.starting_pose = geometry_msgs.msg.PoseStamped() 00090 00091 def _get_types(self): 00092 """ 00093 internal API method 00094 """ 00095 return self._slot_types 00096 00097 def serialize(self, buff): 00098 """ 00099 serialize message into buffer 00100 @param buff: buffer 00101 @type buff: StringIO 00102 """ 00103 try: 00104 _x = self 00105 buff.write(_struct_3I.pack(_x.starting_pose.header.seq, _x.starting_pose.header.stamp.secs, _x.starting_pose.header.stamp.nsecs)) 00106 _x = self.starting_pose.header.frame_id 00107 length = len(_x) 00108 buff.write(struct.pack('<I%ss'%length, length, _x)) 00109 _x = self 00110 buff.write(_struct_7d.pack(_x.starting_pose.pose.position.x, _x.starting_pose.pose.position.y, _x.starting_pose.pose.position.z, _x.starting_pose.pose.orientation.x, _x.starting_pose.pose.orientation.y, _x.starting_pose.pose.orientation.z, _x.starting_pose.pose.orientation.w)) 00111 except struct.error as se: self._check_types(se) 00112 except TypeError as te: self._check_types(te) 00113 00114 def deserialize(self, str): 00115 """ 00116 unpack serialized message in str into this message instance 00117 @param str: byte array of serialized message 00118 @type str: str 00119 """ 00120 try: 00121 if self.starting_pose is None: 00122 self.starting_pose = geometry_msgs.msg.PoseStamped() 00123 end = 0 00124 _x = self 00125 start = end 00126 end += 12 00127 (_x.starting_pose.header.seq, _x.starting_pose.header.stamp.secs, _x.starting_pose.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00128 start = end 00129 end += 4 00130 (length,) = _struct_I.unpack(str[start:end]) 00131 start = end 00132 end += length 00133 self.starting_pose.header.frame_id = str[start:end] 00134 _x = self 00135 start = end 00136 end += 56 00137 (_x.starting_pose.pose.position.x, _x.starting_pose.pose.position.y, _x.starting_pose.pose.position.z, _x.starting_pose.pose.orientation.x, _x.starting_pose.pose.orientation.y, _x.starting_pose.pose.orientation.z, _x.starting_pose.pose.orientation.w,) = _struct_7d.unpack(str[start:end]) 00138 return self 00139 except struct.error as e: 00140 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00141 00142 00143 def serialize_numpy(self, buff, numpy): 00144 """ 00145 serialize message with numpy array types into buffer 00146 @param buff: buffer 00147 @type buff: StringIO 00148 @param numpy: numpy python module 00149 @type numpy module 00150 """ 00151 try: 00152 _x = self 00153 buff.write(_struct_3I.pack(_x.starting_pose.header.seq, _x.starting_pose.header.stamp.secs, _x.starting_pose.header.stamp.nsecs)) 00154 _x = self.starting_pose.header.frame_id 00155 length = len(_x) 00156 buff.write(struct.pack('<I%ss'%length, length, _x)) 00157 _x = self 00158 buff.write(_struct_7d.pack(_x.starting_pose.pose.position.x, _x.starting_pose.pose.position.y, _x.starting_pose.pose.position.z, _x.starting_pose.pose.orientation.x, _x.starting_pose.pose.orientation.y, _x.starting_pose.pose.orientation.z, _x.starting_pose.pose.orientation.w)) 00159 except struct.error as se: self._check_types(se) 00160 except TypeError as te: self._check_types(te) 00161 00162 def deserialize_numpy(self, str, numpy): 00163 """ 00164 unpack serialized message in str into this message instance using numpy for array types 00165 @param str: byte array of serialized message 00166 @type str: str 00167 @param numpy: numpy python module 00168 @type numpy: module 00169 """ 00170 try: 00171 if self.starting_pose is None: 00172 self.starting_pose = geometry_msgs.msg.PoseStamped() 00173 end = 0 00174 _x = self 00175 start = end 00176 end += 12 00177 (_x.starting_pose.header.seq, _x.starting_pose.header.stamp.secs, _x.starting_pose.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00178 start = end 00179 end += 4 00180 (length,) = _struct_I.unpack(str[start:end]) 00181 start = end 00182 end += length 00183 self.starting_pose.header.frame_id = str[start:end] 00184 _x = self 00185 start = end 00186 end += 56 00187 (_x.starting_pose.pose.position.x, _x.starting_pose.pose.position.y, _x.starting_pose.pose.position.z, _x.starting_pose.pose.orientation.x, _x.starting_pose.pose.orientation.y, _x.starting_pose.pose.orientation.z, _x.starting_pose.pose.orientation.w,) = _struct_7d.unpack(str[start:end]) 00188 return self 00189 except struct.error as e: 00190 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00191 00192 _struct_I = roslib.message.struct_I 00193 _struct_3I = struct.Struct("<3I") 00194 _struct_7d = struct.Struct("<7d")