$search
00001 """autogenerated by genmsg_py from StoreCloudActionResult.msg. Do not edit.""" 00002 import roslib.message 00003 import struct 00004 00005 import sensor_msgs.msg 00006 import point_cloud_server.msg 00007 import roslib.rostime 00008 import actionlib_msgs.msg 00009 import std_msgs.msg 00010 00011 class StoreCloudActionResult(roslib.message.Message): 00012 _md5sum = "56433c41ffc71f25e105fdb7bb83e9bd" 00013 _type = "point_cloud_server/StoreCloudActionResult" 00014 _has_header = True #flag to mark the presence of a Header object 00015 _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== 00016 00017 Header header 00018 actionlib_msgs/GoalStatus status 00019 StoreCloudResult result 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/GoalStatus 00041 GoalID goal_id 00042 uint8 status 00043 uint8 PENDING = 0 # The goal has yet to be processed by the action server 00044 uint8 ACTIVE = 1 # The goal is currently being processed by the action server 00045 uint8 PREEMPTED = 2 # The goal received a cancel request after it started executing 00046 # and has since completed its execution (Terminal State) 00047 uint8 SUCCEEDED = 3 # The goal was achieved successfully by the action server (Terminal State) 00048 uint8 ABORTED = 4 # The goal was aborted during execution by the action server due 00049 # to some failure (Terminal State) 00050 uint8 REJECTED = 5 # The goal was rejected by the action server without being processed, 00051 # because the goal was unattainable or invalid (Terminal State) 00052 uint8 PREEMPTING = 6 # The goal received a cancel request after it started executing 00053 # and has not yet completed execution 00054 uint8 RECALLING = 7 # The goal received a cancel request before it started executing, 00055 # but the action server has not yet confirmed that the goal is canceled 00056 uint8 RECALLED = 8 # The goal received a cancel request before it started executing 00057 # and was successfully cancelled (Terminal State) 00058 uint8 LOST = 9 # An action client can determine that a goal is LOST. This should not be 00059 # sent over the wire by an action server 00060 00061 #Allow for the user to associate a string with GoalStatus for debugging 00062 string text 00063 00064 00065 ================================================================================ 00066 MSG: actionlib_msgs/GoalID 00067 # The stamp should store the time at which this goal was requested. 00068 # It is used by an action server when it tries to preempt all 00069 # goals that were requested before a certain time 00070 time stamp 00071 00072 # The id provides a way to associate feedback and 00073 # result message with specific goal requests. The id 00074 # specified must be unique. 00075 string id 00076 00077 00078 ================================================================================ 00079 MSG: point_cloud_server/StoreCloudResult 00080 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== 00081 00082 # The cloud that was stored (if return_cloud was true) 00083 sensor_msgs/PointCloud2 cloud 00084 00085 # Any text that might be needed... 00086 int32 result 00087 00088 int32 SUCCESS = 0 00089 int32 NAME_ERROR = 1 00090 int32 TOPIC_ERROR = 2 00091 int32 TF_ERROR = 3 00092 int32 OTHER_ERROR = 4 00093 00094 00095 ================================================================================ 00096 MSG: sensor_msgs/PointCloud2 00097 # This message holds a collection of N-dimensional points, which may 00098 # contain additional information such as normals, intensity, etc. The 00099 # point data is stored as a binary blob, its layout described by the 00100 # contents of the "fields" array. 00101 00102 # The point cloud data may be organized 2d (image-like) or 1d 00103 # (unordered). Point clouds organized as 2d images may be produced by 00104 # camera depth sensors such as stereo or time-of-flight. 00105 00106 # Time of sensor data acquisition, and the coordinate frame ID (for 3d 00107 # points). 00108 Header header 00109 00110 # 2D structure of the point cloud. If the cloud is unordered, height is 00111 # 1 and width is the length of the point cloud. 00112 uint32 height 00113 uint32 width 00114 00115 # Describes the channels and their layout in the binary data blob. 00116 PointField[] fields 00117 00118 bool is_bigendian # Is this data bigendian? 00119 uint32 point_step # Length of a point in bytes 00120 uint32 row_step # Length of a row in bytes 00121 uint8[] data # Actual point data, size is (row_step*height) 00122 00123 bool is_dense # True if there are no invalid points 00124 00125 ================================================================================ 00126 MSG: sensor_msgs/PointField 00127 # This message holds the description of one point entry in the 00128 # PointCloud2 message format. 00129 uint8 INT8 = 1 00130 uint8 UINT8 = 2 00131 uint8 INT16 = 3 00132 uint8 UINT16 = 4 00133 uint8 INT32 = 5 00134 uint8 UINT32 = 6 00135 uint8 FLOAT32 = 7 00136 uint8 FLOAT64 = 8 00137 00138 string name # Name of field 00139 uint32 offset # Offset from start of point struct 00140 uint8 datatype # Datatype enumeration, see above 00141 uint32 count # How many elements in the field 00142 00143 """ 00144 __slots__ = ['header','status','result'] 00145 _slot_types = ['Header','actionlib_msgs/GoalStatus','point_cloud_server/StoreCloudResult'] 00146 00147 def __init__(self, *args, **kwds): 00148 """ 00149 Constructor. Any message fields that are implicitly/explicitly 00150 set to None will be assigned a default value. The recommend 00151 use is keyword arguments as this is more robust to future message 00152 changes. You cannot mix in-order arguments and keyword arguments. 00153 00154 The available fields are: 00155 header,status,result 00156 00157 @param args: complete set of field values, in .msg order 00158 @param kwds: use keyword arguments corresponding to message field names 00159 to set specific fields. 00160 """ 00161 if args or kwds: 00162 super(StoreCloudActionResult, self).__init__(*args, **kwds) 00163 #message fields cannot be None, assign default values for those that are 00164 if self.header is None: 00165 self.header = std_msgs.msg._Header.Header() 00166 if self.status is None: 00167 self.status = actionlib_msgs.msg.GoalStatus() 00168 if self.result is None: 00169 self.result = point_cloud_server.msg.StoreCloudResult() 00170 else: 00171 self.header = std_msgs.msg._Header.Header() 00172 self.status = actionlib_msgs.msg.GoalStatus() 00173 self.result = point_cloud_server.msg.StoreCloudResult() 00174 00175 def _get_types(self): 00176 """ 00177 internal API method 00178 """ 00179 return self._slot_types 00180 00181 def serialize(self, buff): 00182 """ 00183 serialize message into buffer 00184 @param buff: buffer 00185 @type buff: StringIO 00186 """ 00187 try: 00188 _x = self 00189 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs)) 00190 _x = self.header.frame_id 00191 length = len(_x) 00192 buff.write(struct.pack('<I%ss'%length, length, _x)) 00193 _x = self 00194 buff.write(_struct_2I.pack(_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs)) 00195 _x = self.status.goal_id.id 00196 length = len(_x) 00197 buff.write(struct.pack('<I%ss'%length, length, _x)) 00198 buff.write(_struct_B.pack(self.status.status)) 00199 _x = self.status.text 00200 length = len(_x) 00201 buff.write(struct.pack('<I%ss'%length, length, _x)) 00202 _x = self 00203 buff.write(_struct_3I.pack(_x.result.cloud.header.seq, _x.result.cloud.header.stamp.secs, _x.result.cloud.header.stamp.nsecs)) 00204 _x = self.result.cloud.header.frame_id 00205 length = len(_x) 00206 buff.write(struct.pack('<I%ss'%length, length, _x)) 00207 _x = self 00208 buff.write(_struct_2I.pack(_x.result.cloud.height, _x.result.cloud.width)) 00209 length = len(self.result.cloud.fields) 00210 buff.write(_struct_I.pack(length)) 00211 for val1 in self.result.cloud.fields: 00212 _x = val1.name 00213 length = len(_x) 00214 buff.write(struct.pack('<I%ss'%length, length, _x)) 00215 _x = val1 00216 buff.write(_struct_IBI.pack(_x.offset, _x.datatype, _x.count)) 00217 _x = self 00218 buff.write(_struct_B2I.pack(_x.result.cloud.is_bigendian, _x.result.cloud.point_step, _x.result.cloud.row_step)) 00219 _x = self.result.cloud.data 00220 length = len(_x) 00221 # - if encoded as a list instead, serialize as bytes instead of string 00222 if type(_x) in [list, tuple]: 00223 buff.write(struct.pack('<I%sB'%length, length, *_x)) 00224 else: 00225 buff.write(struct.pack('<I%ss'%length, length, _x)) 00226 _x = self 00227 buff.write(_struct_Bi.pack(_x.result.cloud.is_dense, _x.result.result)) 00228 except struct.error as se: self._check_types(se) 00229 except TypeError as te: self._check_types(te) 00230 00231 def deserialize(self, str): 00232 """ 00233 unpack serialized message in str into this message instance 00234 @param str: byte array of serialized message 00235 @type str: str 00236 """ 00237 try: 00238 if self.header is None: 00239 self.header = std_msgs.msg._Header.Header() 00240 if self.status is None: 00241 self.status = actionlib_msgs.msg.GoalStatus() 00242 if self.result is None: 00243 self.result = point_cloud_server.msg.StoreCloudResult() 00244 end = 0 00245 _x = self 00246 start = end 00247 end += 12 00248 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00249 start = end 00250 end += 4 00251 (length,) = _struct_I.unpack(str[start:end]) 00252 start = end 00253 end += length 00254 self.header.frame_id = str[start:end] 00255 _x = self 00256 start = end 00257 end += 8 00258 (_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end]) 00259 start = end 00260 end += 4 00261 (length,) = _struct_I.unpack(str[start:end]) 00262 start = end 00263 end += length 00264 self.status.goal_id.id = str[start:end] 00265 start = end 00266 end += 1 00267 (self.status.status,) = _struct_B.unpack(str[start:end]) 00268 start = end 00269 end += 4 00270 (length,) = _struct_I.unpack(str[start:end]) 00271 start = end 00272 end += length 00273 self.status.text = str[start:end] 00274 _x = self 00275 start = end 00276 end += 12 00277 (_x.result.cloud.header.seq, _x.result.cloud.header.stamp.secs, _x.result.cloud.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00278 start = end 00279 end += 4 00280 (length,) = _struct_I.unpack(str[start:end]) 00281 start = end 00282 end += length 00283 self.result.cloud.header.frame_id = str[start:end] 00284 _x = self 00285 start = end 00286 end += 8 00287 (_x.result.cloud.height, _x.result.cloud.width,) = _struct_2I.unpack(str[start:end]) 00288 start = end 00289 end += 4 00290 (length,) = _struct_I.unpack(str[start:end]) 00291 self.result.cloud.fields = [] 00292 for i in range(0, length): 00293 val1 = sensor_msgs.msg.PointField() 00294 start = end 00295 end += 4 00296 (length,) = _struct_I.unpack(str[start:end]) 00297 start = end 00298 end += length 00299 val1.name = str[start:end] 00300 _x = val1 00301 start = end 00302 end += 9 00303 (_x.offset, _x.datatype, _x.count,) = _struct_IBI.unpack(str[start:end]) 00304 self.result.cloud.fields.append(val1) 00305 _x = self 00306 start = end 00307 end += 9 00308 (_x.result.cloud.is_bigendian, _x.result.cloud.point_step, _x.result.cloud.row_step,) = _struct_B2I.unpack(str[start:end]) 00309 self.result.cloud.is_bigendian = bool(self.result.cloud.is_bigendian) 00310 start = end 00311 end += 4 00312 (length,) = _struct_I.unpack(str[start:end]) 00313 start = end 00314 end += length 00315 self.result.cloud.data = str[start:end] 00316 _x = self 00317 start = end 00318 end += 5 00319 (_x.result.cloud.is_dense, _x.result.result,) = _struct_Bi.unpack(str[start:end]) 00320 self.result.cloud.is_dense = bool(self.result.cloud.is_dense) 00321 return self 00322 except struct.error as e: 00323 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00324 00325 00326 def serialize_numpy(self, buff, numpy): 00327 """ 00328 serialize message with numpy array types into buffer 00329 @param buff: buffer 00330 @type buff: StringIO 00331 @param numpy: numpy python module 00332 @type numpy module 00333 """ 00334 try: 00335 _x = self 00336 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs)) 00337 _x = self.header.frame_id 00338 length = len(_x) 00339 buff.write(struct.pack('<I%ss'%length, length, _x)) 00340 _x = self 00341 buff.write(_struct_2I.pack(_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs)) 00342 _x = self.status.goal_id.id 00343 length = len(_x) 00344 buff.write(struct.pack('<I%ss'%length, length, _x)) 00345 buff.write(_struct_B.pack(self.status.status)) 00346 _x = self.status.text 00347 length = len(_x) 00348 buff.write(struct.pack('<I%ss'%length, length, _x)) 00349 _x = self 00350 buff.write(_struct_3I.pack(_x.result.cloud.header.seq, _x.result.cloud.header.stamp.secs, _x.result.cloud.header.stamp.nsecs)) 00351 _x = self.result.cloud.header.frame_id 00352 length = len(_x) 00353 buff.write(struct.pack('<I%ss'%length, length, _x)) 00354 _x = self 00355 buff.write(_struct_2I.pack(_x.result.cloud.height, _x.result.cloud.width)) 00356 length = len(self.result.cloud.fields) 00357 buff.write(_struct_I.pack(length)) 00358 for val1 in self.result.cloud.fields: 00359 _x = val1.name 00360 length = len(_x) 00361 buff.write(struct.pack('<I%ss'%length, length, _x)) 00362 _x = val1 00363 buff.write(_struct_IBI.pack(_x.offset, _x.datatype, _x.count)) 00364 _x = self 00365 buff.write(_struct_B2I.pack(_x.result.cloud.is_bigendian, _x.result.cloud.point_step, _x.result.cloud.row_step)) 00366 _x = self.result.cloud.data 00367 length = len(_x) 00368 # - if encoded as a list instead, serialize as bytes instead of string 00369 if type(_x) in [list, tuple]: 00370 buff.write(struct.pack('<I%sB'%length, length, *_x)) 00371 else: 00372 buff.write(struct.pack('<I%ss'%length, length, _x)) 00373 _x = self 00374 buff.write(_struct_Bi.pack(_x.result.cloud.is_dense, _x.result.result)) 00375 except struct.error as se: self._check_types(se) 00376 except TypeError as te: self._check_types(te) 00377 00378 def deserialize_numpy(self, str, numpy): 00379 """ 00380 unpack serialized message in str into this message instance using numpy for array types 00381 @param str: byte array of serialized message 00382 @type str: str 00383 @param numpy: numpy python module 00384 @type numpy: module 00385 """ 00386 try: 00387 if self.header is None: 00388 self.header = std_msgs.msg._Header.Header() 00389 if self.status is None: 00390 self.status = actionlib_msgs.msg.GoalStatus() 00391 if self.result is None: 00392 self.result = point_cloud_server.msg.StoreCloudResult() 00393 end = 0 00394 _x = self 00395 start = end 00396 end += 12 00397 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00398 start = end 00399 end += 4 00400 (length,) = _struct_I.unpack(str[start:end]) 00401 start = end 00402 end += length 00403 self.header.frame_id = str[start:end] 00404 _x = self 00405 start = end 00406 end += 8 00407 (_x.status.goal_id.stamp.secs, _x.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end]) 00408 start = end 00409 end += 4 00410 (length,) = _struct_I.unpack(str[start:end]) 00411 start = end 00412 end += length 00413 self.status.goal_id.id = str[start:end] 00414 start = end 00415 end += 1 00416 (self.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 self.status.text = str[start:end] 00423 _x = self 00424 start = end 00425 end += 12 00426 (_x.result.cloud.header.seq, _x.result.cloud.header.stamp.secs, _x.result.cloud.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00427 start = end 00428 end += 4 00429 (length,) = _struct_I.unpack(str[start:end]) 00430 start = end 00431 end += length 00432 self.result.cloud.header.frame_id = str[start:end] 00433 _x = self 00434 start = end 00435 end += 8 00436 (_x.result.cloud.height, _x.result.cloud.width,) = _struct_2I.unpack(str[start:end]) 00437 start = end 00438 end += 4 00439 (length,) = _struct_I.unpack(str[start:end]) 00440 self.result.cloud.fields = [] 00441 for i in range(0, length): 00442 val1 = sensor_msgs.msg.PointField() 00443 start = end 00444 end += 4 00445 (length,) = _struct_I.unpack(str[start:end]) 00446 start = end 00447 end += length 00448 val1.name = str[start:end] 00449 _x = val1 00450 start = end 00451 end += 9 00452 (_x.offset, _x.datatype, _x.count,) = _struct_IBI.unpack(str[start:end]) 00453 self.result.cloud.fields.append(val1) 00454 _x = self 00455 start = end 00456 end += 9 00457 (_x.result.cloud.is_bigendian, _x.result.cloud.point_step, _x.result.cloud.row_step,) = _struct_B2I.unpack(str[start:end]) 00458 self.result.cloud.is_bigendian = bool(self.result.cloud.is_bigendian) 00459 start = end 00460 end += 4 00461 (length,) = _struct_I.unpack(str[start:end]) 00462 start = end 00463 end += length 00464 self.result.cloud.data = str[start:end] 00465 _x = self 00466 start = end 00467 end += 5 00468 (_x.result.cloud.is_dense, _x.result.result,) = _struct_Bi.unpack(str[start:end]) 00469 self.result.cloud.is_dense = bool(self.result.cloud.is_dense) 00470 return self 00471 except struct.error as e: 00472 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00473 00474 _struct_I = roslib.message.struct_I 00475 _struct_IBI = struct.Struct("<IBI") 00476 _struct_B = struct.Struct("<B") 00477 _struct_Bi = struct.Struct("<Bi") 00478 _struct_3I = struct.Struct("<3I") 00479 _struct_B2I = struct.Struct("<B2I") 00480 _struct_2I = struct.Struct("<2I")