00001 """autogenerated by genmsg_py from DoorActionGoal.msg. Do not edit."""
00002 import roslib.message
00003 import struct
00004
00005 import geometry_msgs.msg
00006 import door_msgs.msg
00007 import roslib.rostime
00008 import actionlib_msgs.msg
00009 import std_msgs.msg
00010
00011 class DoorActionGoal(roslib.message.Message):
00012 _md5sum = "e7c640d872c5b169f989efc688f55658"
00013 _type = "door_msgs/DoorActionGoal"
00014 _has_header = True
00015 _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00016
00017 Header header
00018 actionlib_msgs/GoalID goal_id
00019 DoorGoal goal
00020
00021 ================================================================================
00022 MSG: std_msgs/Header
00023 # Standard metadata for higher-level stamped data types.
00024 # This is generally used to communicate timestamped data
00025 # in a particular coordinate frame.
00026 #
00027 # sequence ID: consecutively increasing ID
00028 uint32 seq
00029 #Two-integer timestamp that is expressed as:
00030 # * stamp.secs: seconds (stamp_secs) since epoch
00031 # * stamp.nsecs: nanoseconds since stamp_secs
00032 # time-handling sugar is provided by the client library
00033 time stamp
00034 #Frame this data is associated with
00035 # 0: no frame
00036 # 1: global frame
00037 string frame_id
00038
00039 ================================================================================
00040 MSG: actionlib_msgs/GoalID
00041 # The stamp should store the time at which this goal was requested.
00042 # It is used by an action server when it tries to preempt all
00043 # goals that were requested before a certain time
00044 time stamp
00045
00046 # The id provides a way to associate feedback and
00047 # result message with specific goal requests. The id
00048 # specified must be unique.
00049 string id
00050
00051
00052 ================================================================================
00053 MSG: door_msgs/DoorGoal
00054 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00055 # goal
00056 door_msgs/Door door
00057
00058 ================================================================================
00059 MSG: door_msgs/Door
00060 Header header
00061 geometry_msgs/Point32 frame_p1 ## position of the door frame
00062 geometry_msgs/Point32 frame_p2 ## position of the door frame
00063 geometry_msgs/Point32 door_p1 ## Ground plane projection of a point on the plane of the door
00064 geometry_msgs/Point32 door_p2 ## Ground plane projection of a point on the plane of the door
00065 geometry_msgs/Point32 handle ## Position of the door handle
00066 float32 height ## Height of the door
00067
00068 int32 UNKNOWN=0
00069
00070 int32 HINGE_P1=1
00071 int32 HINGE_P2=2
00072 int32 hinge
00073
00074 int32 ROT_DIR_CLOCKWISE=1
00075 int32 ROT_DIR_COUNTERCLOCKWISE=2
00076 int32 rot_dir
00077
00078 int32 LOCKED=1
00079 int32 LATCHED=2
00080 int32 UNLATCHED=3
00081 int32 latch_state
00082
00083 geometry_msgs/Vector3 travel_dir ## vector pointing in the direction the robot is going to travel through the door
00084 float32 weight ## @Sachin: what do we use this for?
00085
00086
00087
00088 ================================================================================
00089 MSG: geometry_msgs/Point32
00090 # This contains the position of a point in free space(with 32 bits of precision).
00091 # It is recommeded to use Point wherever possible instead of Point32.
00092 #
00093 # This recommendation is to promote interoperability.
00094 #
00095 # This message is designed to take up less space when sending
00096 # lots of points at once, as in the case of a PointCloud.
00097
00098 float32 x
00099 float32 y
00100 float32 z
00101 ================================================================================
00102 MSG: geometry_msgs/Vector3
00103 # This represents a vector in free space.
00104
00105 float64 x
00106 float64 y
00107 float64 z
00108 """
00109 __slots__ = ['header','goal_id','goal']
00110 _slot_types = ['Header','actionlib_msgs/GoalID','door_msgs/DoorGoal']
00111
00112 def __init__(self, *args, **kwds):
00113 """
00114 Constructor. Any message fields that are implicitly/explicitly
00115 set to None will be assigned a default value. The recommend
00116 use is keyword arguments as this is more robust to future message
00117 changes. You cannot mix in-order arguments and keyword arguments.
00118
00119 The available fields are:
00120 header,goal_id,goal
00121
00122 @param args: complete set of field values, in .msg order
00123 @param kwds: use keyword arguments corresponding to message field names
00124 to set specific fields.
00125 """
00126 if args or kwds:
00127 super(DoorActionGoal, self).__init__(*args, **kwds)
00128
00129 if self.header is None:
00130 self.header = std_msgs.msg._Header.Header()
00131 if self.goal_id is None:
00132 self.goal_id = actionlib_msgs.msg.GoalID()
00133 if self.goal is None:
00134 self.goal = door_msgs.msg.DoorGoal()
00135 else:
00136 self.header = std_msgs.msg._Header.Header()
00137 self.goal_id = actionlib_msgs.msg.GoalID()
00138 self.goal = door_msgs.msg.DoorGoal()
00139
00140 def _get_types(self):
00141 """
00142 internal API method
00143 """
00144 return self._slot_types
00145
00146 def serialize(self, buff):
00147 """
00148 serialize message into buffer
00149 @param buff: buffer
00150 @type buff: StringIO
00151 """
00152 try:
00153 _x = self
00154 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs))
00155 _x = self.header.frame_id
00156 length = len(_x)
00157 buff.write(struct.pack('<I%ss'%length, length, _x))
00158 _x = self
00159 buff.write(_struct_2I.pack(_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs))
00160 _x = self.goal_id.id
00161 length = len(_x)
00162 buff.write(struct.pack('<I%ss'%length, length, _x))
00163 _x = self
00164 buff.write(_struct_3I.pack(_x.goal.door.header.seq, _x.goal.door.header.stamp.secs, _x.goal.door.header.stamp.nsecs))
00165 _x = self.goal.door.header.frame_id
00166 length = len(_x)
00167 buff.write(struct.pack('<I%ss'%length, length, _x))
00168 _x = self
00169 buff.write(_struct_16f3i3df.pack(_x.goal.door.frame_p1.x, _x.goal.door.frame_p1.y, _x.goal.door.frame_p1.z, _x.goal.door.frame_p2.x, _x.goal.door.frame_p2.y, _x.goal.door.frame_p2.z, _x.goal.door.door_p1.x, _x.goal.door.door_p1.y, _x.goal.door.door_p1.z, _x.goal.door.door_p2.x, _x.goal.door.door_p2.y, _x.goal.door.door_p2.z, _x.goal.door.handle.x, _x.goal.door.handle.y, _x.goal.door.handle.z, _x.goal.door.height, _x.goal.door.hinge, _x.goal.door.rot_dir, _x.goal.door.latch_state, _x.goal.door.travel_dir.x, _x.goal.door.travel_dir.y, _x.goal.door.travel_dir.z, _x.goal.door.weight))
00170 except struct.error, se: self._check_types(se)
00171 except TypeError, te: self._check_types(te)
00172
00173 def deserialize(self, str):
00174 """
00175 unpack serialized message in str into this message instance
00176 @param str: byte array of serialized message
00177 @type str: str
00178 """
00179 try:
00180 if self.header is None:
00181 self.header = std_msgs.msg._Header.Header()
00182 if self.goal_id is None:
00183 self.goal_id = actionlib_msgs.msg.GoalID()
00184 if self.goal is None:
00185 self.goal = door_msgs.msg.DoorGoal()
00186 end = 0
00187 _x = self
00188 start = end
00189 end += 12
00190 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00191 start = end
00192 end += 4
00193 (length,) = _struct_I.unpack(str[start:end])
00194 start = end
00195 end += length
00196 self.header.frame_id = str[start:end]
00197 _x = self
00198 start = end
00199 end += 8
00200 (_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00201 start = end
00202 end += 4
00203 (length,) = _struct_I.unpack(str[start:end])
00204 start = end
00205 end += length
00206 self.goal_id.id = str[start:end]
00207 _x = self
00208 start = end
00209 end += 12
00210 (_x.goal.door.header.seq, _x.goal.door.header.stamp.secs, _x.goal.door.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00211 start = end
00212 end += 4
00213 (length,) = _struct_I.unpack(str[start:end])
00214 start = end
00215 end += length
00216 self.goal.door.header.frame_id = str[start:end]
00217 _x = self
00218 start = end
00219 end += 104
00220 (_x.goal.door.frame_p1.x, _x.goal.door.frame_p1.y, _x.goal.door.frame_p1.z, _x.goal.door.frame_p2.x, _x.goal.door.frame_p2.y, _x.goal.door.frame_p2.z, _x.goal.door.door_p1.x, _x.goal.door.door_p1.y, _x.goal.door.door_p1.z, _x.goal.door.door_p2.x, _x.goal.door.door_p2.y, _x.goal.door.door_p2.z, _x.goal.door.handle.x, _x.goal.door.handle.y, _x.goal.door.handle.z, _x.goal.door.height, _x.goal.door.hinge, _x.goal.door.rot_dir, _x.goal.door.latch_state, _x.goal.door.travel_dir.x, _x.goal.door.travel_dir.y, _x.goal.door.travel_dir.z, _x.goal.door.weight,) = _struct_16f3i3df.unpack(str[start:end])
00221 return self
00222 except struct.error, e:
00223 raise roslib.message.DeserializationError(e)
00224
00225
00226 def serialize_numpy(self, buff, numpy):
00227 """
00228 serialize message with numpy array types into buffer
00229 @param buff: buffer
00230 @type buff: StringIO
00231 @param numpy: numpy python module
00232 @type numpy module
00233 """
00234 try:
00235 _x = self
00236 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs))
00237 _x = self.header.frame_id
00238 length = len(_x)
00239 buff.write(struct.pack('<I%ss'%length, length, _x))
00240 _x = self
00241 buff.write(_struct_2I.pack(_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs))
00242 _x = self.goal_id.id
00243 length = len(_x)
00244 buff.write(struct.pack('<I%ss'%length, length, _x))
00245 _x = self
00246 buff.write(_struct_3I.pack(_x.goal.door.header.seq, _x.goal.door.header.stamp.secs, _x.goal.door.header.stamp.nsecs))
00247 _x = self.goal.door.header.frame_id
00248 length = len(_x)
00249 buff.write(struct.pack('<I%ss'%length, length, _x))
00250 _x = self
00251 buff.write(_struct_16f3i3df.pack(_x.goal.door.frame_p1.x, _x.goal.door.frame_p1.y, _x.goal.door.frame_p1.z, _x.goal.door.frame_p2.x, _x.goal.door.frame_p2.y, _x.goal.door.frame_p2.z, _x.goal.door.door_p1.x, _x.goal.door.door_p1.y, _x.goal.door.door_p1.z, _x.goal.door.door_p2.x, _x.goal.door.door_p2.y, _x.goal.door.door_p2.z, _x.goal.door.handle.x, _x.goal.door.handle.y, _x.goal.door.handle.z, _x.goal.door.height, _x.goal.door.hinge, _x.goal.door.rot_dir, _x.goal.door.latch_state, _x.goal.door.travel_dir.x, _x.goal.door.travel_dir.y, _x.goal.door.travel_dir.z, _x.goal.door.weight))
00252 except struct.error, se: self._check_types(se)
00253 except TypeError, te: self._check_types(te)
00254
00255 def deserialize_numpy(self, str, numpy):
00256 """
00257 unpack serialized message in str into this message instance using numpy for array types
00258 @param str: byte array of serialized message
00259 @type str: str
00260 @param numpy: numpy python module
00261 @type numpy: module
00262 """
00263 try:
00264 if self.header is None:
00265 self.header = std_msgs.msg._Header.Header()
00266 if self.goal_id is None:
00267 self.goal_id = actionlib_msgs.msg.GoalID()
00268 if self.goal is None:
00269 self.goal = door_msgs.msg.DoorGoal()
00270 end = 0
00271 _x = self
00272 start = end
00273 end += 12
00274 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00275 start = end
00276 end += 4
00277 (length,) = _struct_I.unpack(str[start:end])
00278 start = end
00279 end += length
00280 self.header.frame_id = str[start:end]
00281 _x = self
00282 start = end
00283 end += 8
00284 (_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00285 start = end
00286 end += 4
00287 (length,) = _struct_I.unpack(str[start:end])
00288 start = end
00289 end += length
00290 self.goal_id.id = str[start:end]
00291 _x = self
00292 start = end
00293 end += 12
00294 (_x.goal.door.header.seq, _x.goal.door.header.stamp.secs, _x.goal.door.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00295 start = end
00296 end += 4
00297 (length,) = _struct_I.unpack(str[start:end])
00298 start = end
00299 end += length
00300 self.goal.door.header.frame_id = str[start:end]
00301 _x = self
00302 start = end
00303 end += 104
00304 (_x.goal.door.frame_p1.x, _x.goal.door.frame_p1.y, _x.goal.door.frame_p1.z, _x.goal.door.frame_p2.x, _x.goal.door.frame_p2.y, _x.goal.door.frame_p2.z, _x.goal.door.door_p1.x, _x.goal.door.door_p1.y, _x.goal.door.door_p1.z, _x.goal.door.door_p2.x, _x.goal.door.door_p2.y, _x.goal.door.door_p2.z, _x.goal.door.handle.x, _x.goal.door.handle.y, _x.goal.door.handle.z, _x.goal.door.height, _x.goal.door.hinge, _x.goal.door.rot_dir, _x.goal.door.latch_state, _x.goal.door.travel_dir.x, _x.goal.door.travel_dir.y, _x.goal.door.travel_dir.z, _x.goal.door.weight,) = _struct_16f3i3df.unpack(str[start:end])
00305 return self
00306 except struct.error, e:
00307 raise roslib.message.DeserializationError(e)
00308
00309 _struct_I = roslib.message.struct_I
00310 _struct_3I = struct.Struct("<3I")
00311 _struct_16f3i3df = struct.Struct("<16f3i3df")
00312 _struct_2I = struct.Struct("<2I")