00001 """autogenerated by genpy from point_cloud_server/StoreCloudAction.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 sensor_msgs.msg
00008 import std_msgs.msg
00009 import genpy
00010 import actionlib_msgs.msg
00011 import point_cloud_server.msg
00012
00013 class StoreCloudAction(genpy.Message):
00014 _md5sum = "43d67f5d9598c562f5f1a43d8bdadb77"
00015 _type = "point_cloud_server/StoreCloudAction"
00016 _has_header = False
00017 _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00018
00019 StoreCloudActionGoal action_goal
00020 StoreCloudActionResult action_result
00021 StoreCloudActionFeedback action_feedback
00022
00023 ================================================================================
00024 MSG: point_cloud_server/StoreCloudActionGoal
00025 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00026
00027 Header header
00028 actionlib_msgs/GoalID goal_id
00029 StoreCloudGoal goal
00030
00031 ================================================================================
00032 MSG: std_msgs/Header
00033 # Standard metadata for higher-level stamped data types.
00034 # This is generally used to communicate timestamped data
00035 # in a particular coordinate frame.
00036 #
00037 # sequence ID: consecutively increasing ID
00038 uint32 seq
00039 #Two-integer timestamp that is expressed as:
00040 # * stamp.secs: seconds (stamp_secs) since epoch
00041 # * stamp.nsecs: nanoseconds since stamp_secs
00042 # time-handling sugar is provided by the client library
00043 time stamp
00044 #Frame this data is associated with
00045 # 0: no frame
00046 # 1: global frame
00047 string frame_id
00048
00049 ================================================================================
00050 MSG: actionlib_msgs/GoalID
00051 # The stamp should store the time at which this goal was requested.
00052 # It is used by an action server when it tries to preempt all
00053 # goals that were requested before a certain time
00054 time stamp
00055
00056 # The id provides a way to associate feedback and
00057 # result message with specific goal requests. The id
00058 # specified must be unique.
00059 string id
00060
00061
00062 ================================================================================
00063 MSG: point_cloud_server/StoreCloudGoal
00064 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00065 # The storage name of the point cloud.
00066 string name
00067
00068 # The topic on which to capture a point cloud message.
00069 # If this is empty, then 'cloud' will be used instead.
00070 string topic
00071
00072 # A point cloud to store.
00073 sensor_msgs/PointCloud2 cloud
00074
00075 # If not empty, transforms the cloud to this frame before storing.
00076 string storage_frame_id
00077
00078 # If not empty, transforms the cloud to this frame in the return result.
00079 string result_frame_id
00080
00081 # A flag to determine whether to reply with the cloud.
00082 int32 action
00083
00084 # Will get a message on topic, or store cloud.
00085 int32 STORE=0
00086
00087 # Will get a message on a topic if it is provided, save, and return it;
00088 # otherwise just returns the existing cloud.
00089 int32 GET=1
00090
00091 # Topic and cloud are ignored, just removes cloud from the server.
00092 int32 CLEAR=2
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 MSG: point_cloud_server/StoreCloudActionResult
00145 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00146
00147 Header header
00148 actionlib_msgs/GoalStatus status
00149 StoreCloudResult result
00150
00151 ================================================================================
00152 MSG: actionlib_msgs/GoalStatus
00153 GoalID goal_id
00154 uint8 status
00155 uint8 PENDING = 0 # The goal has yet to be processed by the action server
00156 uint8 ACTIVE = 1 # The goal is currently being processed by the action server
00157 uint8 PREEMPTED = 2 # The goal received a cancel request after it started executing
00158 # and has since completed its execution (Terminal State)
00159 uint8 SUCCEEDED = 3 # The goal was achieved successfully by the action server (Terminal State)
00160 uint8 ABORTED = 4 # The goal was aborted during execution by the action server due
00161 # to some failure (Terminal State)
00162 uint8 REJECTED = 5 # The goal was rejected by the action server without being processed,
00163 # because the goal was unattainable or invalid (Terminal State)
00164 uint8 PREEMPTING = 6 # The goal received a cancel request after it started executing
00165 # and has not yet completed execution
00166 uint8 RECALLING = 7 # The goal received a cancel request before it started executing,
00167 # but the action server has not yet confirmed that the goal is canceled
00168 uint8 RECALLED = 8 # The goal received a cancel request before it started executing
00169 # and was successfully cancelled (Terminal State)
00170 uint8 LOST = 9 # An action client can determine that a goal is LOST. This should not be
00171 # sent over the wire by an action server
00172
00173 #Allow for the user to associate a string with GoalStatus for debugging
00174 string text
00175
00176
00177 ================================================================================
00178 MSG: point_cloud_server/StoreCloudResult
00179 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00180
00181 # The cloud that was stored (if return_cloud was true)
00182 sensor_msgs/PointCloud2 cloud
00183
00184 # Any text that might be needed...
00185 int32 result
00186
00187 int32 SUCCESS = 0
00188 int32 NAME_ERROR = 1
00189 int32 TOPIC_ERROR = 2
00190 int32 TF_ERROR = 3
00191 int32 OTHER_ERROR = 4
00192
00193
00194 ================================================================================
00195 MSG: point_cloud_server/StoreCloudActionFeedback
00196 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00197
00198 Header header
00199 actionlib_msgs/GoalStatus status
00200 StoreCloudFeedback feedback
00201
00202 ================================================================================
00203 MSG: point_cloud_server/StoreCloudFeedback
00204 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00205
00206
00207 """
00208 __slots__ = ['action_goal','action_result','action_feedback']
00209 _slot_types = ['point_cloud_server/StoreCloudActionGoal','point_cloud_server/StoreCloudActionResult','point_cloud_server/StoreCloudActionFeedback']
00210
00211 def __init__(self, *args, **kwds):
00212 """
00213 Constructor. Any message fields that are implicitly/explicitly
00214 set to None will be assigned a default value. The recommend
00215 use is keyword arguments as this is more robust to future message
00216 changes. You cannot mix in-order arguments and keyword arguments.
00217
00218 The available fields are:
00219 action_goal,action_result,action_feedback
00220
00221 :param args: complete set of field values, in .msg order
00222 :param kwds: use keyword arguments corresponding to message field names
00223 to set specific fields.
00224 """
00225 if args or kwds:
00226 super(StoreCloudAction, self).__init__(*args, **kwds)
00227
00228 if self.action_goal is None:
00229 self.action_goal = point_cloud_server.msg.StoreCloudActionGoal()
00230 if self.action_result is None:
00231 self.action_result = point_cloud_server.msg.StoreCloudActionResult()
00232 if self.action_feedback is None:
00233 self.action_feedback = point_cloud_server.msg.StoreCloudActionFeedback()
00234 else:
00235 self.action_goal = point_cloud_server.msg.StoreCloudActionGoal()
00236 self.action_result = point_cloud_server.msg.StoreCloudActionResult()
00237 self.action_feedback = point_cloud_server.msg.StoreCloudActionFeedback()
00238
00239 def _get_types(self):
00240 """
00241 internal API method
00242 """
00243 return self._slot_types
00244
00245 def serialize(self, buff):
00246 """
00247 serialize message into buffer
00248 :param buff: buffer, ``StringIO``
00249 """
00250 try:
00251 _x = self
00252 buff.write(_struct_3I.pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
00253 _x = self.action_goal.header.frame_id
00254 length = len(_x)
00255 if python3 or type(_x) == unicode:
00256 _x = _x.encode('utf-8')
00257 length = len(_x)
00258 buff.write(struct.pack('<I%ss'%length, length, _x))
00259 _x = self
00260 buff.write(_struct_2I.pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
00261 _x = self.action_goal.goal_id.id
00262 length = len(_x)
00263 if python3 or type(_x) == unicode:
00264 _x = _x.encode('utf-8')
00265 length = len(_x)
00266 buff.write(struct.pack('<I%ss'%length, length, _x))
00267 _x = self.action_goal.goal.name
00268 length = len(_x)
00269 if python3 or type(_x) == unicode:
00270 _x = _x.encode('utf-8')
00271 length = len(_x)
00272 buff.write(struct.pack('<I%ss'%length, length, _x))
00273 _x = self.action_goal.goal.topic
00274 length = len(_x)
00275 if python3 or type(_x) == unicode:
00276 _x = _x.encode('utf-8')
00277 length = len(_x)
00278 buff.write(struct.pack('<I%ss'%length, length, _x))
00279 _x = self
00280 buff.write(_struct_3I.pack(_x.action_goal.goal.cloud.header.seq, _x.action_goal.goal.cloud.header.stamp.secs, _x.action_goal.goal.cloud.header.stamp.nsecs))
00281 _x = self.action_goal.goal.cloud.header.frame_id
00282 length = len(_x)
00283 if python3 or type(_x) == unicode:
00284 _x = _x.encode('utf-8')
00285 length = len(_x)
00286 buff.write(struct.pack('<I%ss'%length, length, _x))
00287 _x = self
00288 buff.write(_struct_2I.pack(_x.action_goal.goal.cloud.height, _x.action_goal.goal.cloud.width))
00289 length = len(self.action_goal.goal.cloud.fields)
00290 buff.write(_struct_I.pack(length))
00291 for val1 in self.action_goal.goal.cloud.fields:
00292 _x = val1.name
00293 length = len(_x)
00294 if python3 or type(_x) == unicode:
00295 _x = _x.encode('utf-8')
00296 length = len(_x)
00297 buff.write(struct.pack('<I%ss'%length, length, _x))
00298 _x = val1
00299 buff.write(_struct_IBI.pack(_x.offset, _x.datatype, _x.count))
00300 _x = self
00301 buff.write(_struct_B2I.pack(_x.action_goal.goal.cloud.is_bigendian, _x.action_goal.goal.cloud.point_step, _x.action_goal.goal.cloud.row_step))
00302 _x = self.action_goal.goal.cloud.data
00303 length = len(_x)
00304
00305 if type(_x) in [list, tuple]:
00306 buff.write(struct.pack('<I%sB'%length, length, *_x))
00307 else:
00308 buff.write(struct.pack('<I%ss'%length, length, _x))
00309 buff.write(_struct_B.pack(self.action_goal.goal.cloud.is_dense))
00310 _x = self.action_goal.goal.storage_frame_id
00311 length = len(_x)
00312 if python3 or type(_x) == unicode:
00313 _x = _x.encode('utf-8')
00314 length = len(_x)
00315 buff.write(struct.pack('<I%ss'%length, length, _x))
00316 _x = self.action_goal.goal.result_frame_id
00317 length = len(_x)
00318 if python3 or type(_x) == unicode:
00319 _x = _x.encode('utf-8')
00320 length = len(_x)
00321 buff.write(struct.pack('<I%ss'%length, length, _x))
00322 _x = self
00323 buff.write(_struct_i3I.pack(_x.action_goal.goal.action, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
00324 _x = self.action_result.header.frame_id
00325 length = len(_x)
00326 if python3 or type(_x) == unicode:
00327 _x = _x.encode('utf-8')
00328 length = len(_x)
00329 buff.write(struct.pack('<I%ss'%length, length, _x))
00330 _x = self
00331 buff.write(_struct_2I.pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
00332 _x = self.action_result.status.goal_id.id
00333 length = len(_x)
00334 if python3 or type(_x) == unicode:
00335 _x = _x.encode('utf-8')
00336 length = len(_x)
00337 buff.write(struct.pack('<I%ss'%length, length, _x))
00338 buff.write(_struct_B.pack(self.action_result.status.status))
00339 _x = self.action_result.status.text
00340 length = len(_x)
00341 if python3 or type(_x) == unicode:
00342 _x = _x.encode('utf-8')
00343 length = len(_x)
00344 buff.write(struct.pack('<I%ss'%length, length, _x))
00345 _x = self
00346 buff.write(_struct_3I.pack(_x.action_result.result.cloud.header.seq, _x.action_result.result.cloud.header.stamp.secs, _x.action_result.result.cloud.header.stamp.nsecs))
00347 _x = self.action_result.result.cloud.header.frame_id
00348 length = len(_x)
00349 if python3 or type(_x) == unicode:
00350 _x = _x.encode('utf-8')
00351 length = len(_x)
00352 buff.write(struct.pack('<I%ss'%length, length, _x))
00353 _x = self
00354 buff.write(_struct_2I.pack(_x.action_result.result.cloud.height, _x.action_result.result.cloud.width))
00355 length = len(self.action_result.result.cloud.fields)
00356 buff.write(_struct_I.pack(length))
00357 for val1 in self.action_result.result.cloud.fields:
00358 _x = val1.name
00359 length = len(_x)
00360 if python3 or type(_x) == unicode:
00361 _x = _x.encode('utf-8')
00362 length = len(_x)
00363 buff.write(struct.pack('<I%ss'%length, length, _x))
00364 _x = val1
00365 buff.write(_struct_IBI.pack(_x.offset, _x.datatype, _x.count))
00366 _x = self
00367 buff.write(_struct_B2I.pack(_x.action_result.result.cloud.is_bigendian, _x.action_result.result.cloud.point_step, _x.action_result.result.cloud.row_step))
00368 _x = self.action_result.result.cloud.data
00369 length = len(_x)
00370
00371 if type(_x) in [list, tuple]:
00372 buff.write(struct.pack('<I%sB'%length, length, *_x))
00373 else:
00374 buff.write(struct.pack('<I%ss'%length, length, _x))
00375 _x = self
00376 buff.write(_struct_Bi3I.pack(_x.action_result.result.cloud.is_dense, _x.action_result.result.result, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
00377 _x = self.action_feedback.header.frame_id
00378 length = len(_x)
00379 if python3 or type(_x) == unicode:
00380 _x = _x.encode('utf-8')
00381 length = len(_x)
00382 buff.write(struct.pack('<I%ss'%length, length, _x))
00383 _x = self
00384 buff.write(_struct_2I.pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
00385 _x = self.action_feedback.status.goal_id.id
00386 length = len(_x)
00387 if python3 or type(_x) == unicode:
00388 _x = _x.encode('utf-8')
00389 length = len(_x)
00390 buff.write(struct.pack('<I%ss'%length, length, _x))
00391 buff.write(_struct_B.pack(self.action_feedback.status.status))
00392 _x = self.action_feedback.status.text
00393 length = len(_x)
00394 if python3 or type(_x) == unicode:
00395 _x = _x.encode('utf-8')
00396 length = len(_x)
00397 buff.write(struct.pack('<I%ss'%length, length, _x))
00398 except struct.error as se: self._check_types(se)
00399 except TypeError as te: self._check_types(te)
00400
00401 def deserialize(self, str):
00402 """
00403 unpack serialized message in str into this message instance
00404 :param str: byte array of serialized message, ``str``
00405 """
00406 try:
00407 if self.action_goal is None:
00408 self.action_goal = point_cloud_server.msg.StoreCloudActionGoal()
00409 if self.action_result is None:
00410 self.action_result = point_cloud_server.msg.StoreCloudActionResult()
00411 if self.action_feedback is None:
00412 self.action_feedback = point_cloud_server.msg.StoreCloudActionFeedback()
00413 end = 0
00414 _x = self
00415 start = end
00416 end += 12
00417 (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00418 start = end
00419 end += 4
00420 (length,) = _struct_I.unpack(str[start:end])
00421 start = end
00422 end += length
00423 if python3:
00424 self.action_goal.header.frame_id = str[start:end].decode('utf-8')
00425 else:
00426 self.action_goal.header.frame_id = str[start:end]
00427 _x = self
00428 start = end
00429 end += 8
00430 (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00431 start = end
00432 end += 4
00433 (length,) = _struct_I.unpack(str[start:end])
00434 start = end
00435 end += length
00436 if python3:
00437 self.action_goal.goal_id.id = str[start:end].decode('utf-8')
00438 else:
00439 self.action_goal.goal_id.id = str[start:end]
00440 start = end
00441 end += 4
00442 (length,) = _struct_I.unpack(str[start:end])
00443 start = end
00444 end += length
00445 if python3:
00446 self.action_goal.goal.name = str[start:end].decode('utf-8')
00447 else:
00448 self.action_goal.goal.name = str[start:end]
00449 start = end
00450 end += 4
00451 (length,) = _struct_I.unpack(str[start:end])
00452 start = end
00453 end += length
00454 if python3:
00455 self.action_goal.goal.topic = str[start:end].decode('utf-8')
00456 else:
00457 self.action_goal.goal.topic = str[start:end]
00458 _x = self
00459 start = end
00460 end += 12
00461 (_x.action_goal.goal.cloud.header.seq, _x.action_goal.goal.cloud.header.stamp.secs, _x.action_goal.goal.cloud.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00462 start = end
00463 end += 4
00464 (length,) = _struct_I.unpack(str[start:end])
00465 start = end
00466 end += length
00467 if python3:
00468 self.action_goal.goal.cloud.header.frame_id = str[start:end].decode('utf-8')
00469 else:
00470 self.action_goal.goal.cloud.header.frame_id = str[start:end]
00471 _x = self
00472 start = end
00473 end += 8
00474 (_x.action_goal.goal.cloud.height, _x.action_goal.goal.cloud.width,) = _struct_2I.unpack(str[start:end])
00475 start = end
00476 end += 4
00477 (length,) = _struct_I.unpack(str[start:end])
00478 self.action_goal.goal.cloud.fields = []
00479 for i in range(0, length):
00480 val1 = sensor_msgs.msg.PointField()
00481 start = end
00482 end += 4
00483 (length,) = _struct_I.unpack(str[start:end])
00484 start = end
00485 end += length
00486 if python3:
00487 val1.name = str[start:end].decode('utf-8')
00488 else:
00489 val1.name = str[start:end]
00490 _x = val1
00491 start = end
00492 end += 9
00493 (_x.offset, _x.datatype, _x.count,) = _struct_IBI.unpack(str[start:end])
00494 self.action_goal.goal.cloud.fields.append(val1)
00495 _x = self
00496 start = end
00497 end += 9
00498 (_x.action_goal.goal.cloud.is_bigendian, _x.action_goal.goal.cloud.point_step, _x.action_goal.goal.cloud.row_step,) = _struct_B2I.unpack(str[start:end])
00499 self.action_goal.goal.cloud.is_bigendian = bool(self.action_goal.goal.cloud.is_bigendian)
00500 start = end
00501 end += 4
00502 (length,) = _struct_I.unpack(str[start:end])
00503 start = end
00504 end += length
00505 if python3:
00506 self.action_goal.goal.cloud.data = str[start:end].decode('utf-8')
00507 else:
00508 self.action_goal.goal.cloud.data = str[start:end]
00509 start = end
00510 end += 1
00511 (self.action_goal.goal.cloud.is_dense,) = _struct_B.unpack(str[start:end])
00512 self.action_goal.goal.cloud.is_dense = bool(self.action_goal.goal.cloud.is_dense)
00513 start = end
00514 end += 4
00515 (length,) = _struct_I.unpack(str[start:end])
00516 start = end
00517 end += length
00518 if python3:
00519 self.action_goal.goal.storage_frame_id = str[start:end].decode('utf-8')
00520 else:
00521 self.action_goal.goal.storage_frame_id = str[start:end]
00522 start = end
00523 end += 4
00524 (length,) = _struct_I.unpack(str[start:end])
00525 start = end
00526 end += length
00527 if python3:
00528 self.action_goal.goal.result_frame_id = str[start:end].decode('utf-8')
00529 else:
00530 self.action_goal.goal.result_frame_id = str[start:end]
00531 _x = self
00532 start = end
00533 end += 16
00534 (_x.action_goal.goal.action, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _struct_i3I.unpack(str[start:end])
00535 start = end
00536 end += 4
00537 (length,) = _struct_I.unpack(str[start:end])
00538 start = end
00539 end += length
00540 if python3:
00541 self.action_result.header.frame_id = str[start:end].decode('utf-8')
00542 else:
00543 self.action_result.header.frame_id = str[start:end]
00544 _x = self
00545 start = end
00546 end += 8
00547 (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00548 start = end
00549 end += 4
00550 (length,) = _struct_I.unpack(str[start:end])
00551 start = end
00552 end += length
00553 if python3:
00554 self.action_result.status.goal_id.id = str[start:end].decode('utf-8')
00555 else:
00556 self.action_result.status.goal_id.id = str[start:end]
00557 start = end
00558 end += 1
00559 (self.action_result.status.status,) = _struct_B.unpack(str[start:end])
00560 start = end
00561 end += 4
00562 (length,) = _struct_I.unpack(str[start:end])
00563 start = end
00564 end += length
00565 if python3:
00566 self.action_result.status.text = str[start:end].decode('utf-8')
00567 else:
00568 self.action_result.status.text = str[start:end]
00569 _x = self
00570 start = end
00571 end += 12
00572 (_x.action_result.result.cloud.header.seq, _x.action_result.result.cloud.header.stamp.secs, _x.action_result.result.cloud.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00573 start = end
00574 end += 4
00575 (length,) = _struct_I.unpack(str[start:end])
00576 start = end
00577 end += length
00578 if python3:
00579 self.action_result.result.cloud.header.frame_id = str[start:end].decode('utf-8')
00580 else:
00581 self.action_result.result.cloud.header.frame_id = str[start:end]
00582 _x = self
00583 start = end
00584 end += 8
00585 (_x.action_result.result.cloud.height, _x.action_result.result.cloud.width,) = _struct_2I.unpack(str[start:end])
00586 start = end
00587 end += 4
00588 (length,) = _struct_I.unpack(str[start:end])
00589 self.action_result.result.cloud.fields = []
00590 for i in range(0, length):
00591 val1 = sensor_msgs.msg.PointField()
00592 start = end
00593 end += 4
00594 (length,) = _struct_I.unpack(str[start:end])
00595 start = end
00596 end += length
00597 if python3:
00598 val1.name = str[start:end].decode('utf-8')
00599 else:
00600 val1.name = str[start:end]
00601 _x = val1
00602 start = end
00603 end += 9
00604 (_x.offset, _x.datatype, _x.count,) = _struct_IBI.unpack(str[start:end])
00605 self.action_result.result.cloud.fields.append(val1)
00606 _x = self
00607 start = end
00608 end += 9
00609 (_x.action_result.result.cloud.is_bigendian, _x.action_result.result.cloud.point_step, _x.action_result.result.cloud.row_step,) = _struct_B2I.unpack(str[start:end])
00610 self.action_result.result.cloud.is_bigendian = bool(self.action_result.result.cloud.is_bigendian)
00611 start = end
00612 end += 4
00613 (length,) = _struct_I.unpack(str[start:end])
00614 start = end
00615 end += length
00616 if python3:
00617 self.action_result.result.cloud.data = str[start:end].decode('utf-8')
00618 else:
00619 self.action_result.result.cloud.data = str[start:end]
00620 _x = self
00621 start = end
00622 end += 17
00623 (_x.action_result.result.cloud.is_dense, _x.action_result.result.result, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _struct_Bi3I.unpack(str[start:end])
00624 self.action_result.result.cloud.is_dense = bool(self.action_result.result.cloud.is_dense)
00625 start = end
00626 end += 4
00627 (length,) = _struct_I.unpack(str[start:end])
00628 start = end
00629 end += length
00630 if python3:
00631 self.action_feedback.header.frame_id = str[start:end].decode('utf-8')
00632 else:
00633 self.action_feedback.header.frame_id = str[start:end]
00634 _x = self
00635 start = end
00636 end += 8
00637 (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00638 start = end
00639 end += 4
00640 (length,) = _struct_I.unpack(str[start:end])
00641 start = end
00642 end += length
00643 if python3:
00644 self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8')
00645 else:
00646 self.action_feedback.status.goal_id.id = str[start:end]
00647 start = end
00648 end += 1
00649 (self.action_feedback.status.status,) = _struct_B.unpack(str[start:end])
00650 start = end
00651 end += 4
00652 (length,) = _struct_I.unpack(str[start:end])
00653 start = end
00654 end += length
00655 if python3:
00656 self.action_feedback.status.text = str[start:end].decode('utf-8')
00657 else:
00658 self.action_feedback.status.text = str[start:end]
00659 return self
00660 except struct.error as e:
00661 raise genpy.DeserializationError(e)
00662
00663
00664 def serialize_numpy(self, buff, numpy):
00665 """
00666 serialize message with numpy array types into buffer
00667 :param buff: buffer, ``StringIO``
00668 :param numpy: numpy python module
00669 """
00670 try:
00671 _x = self
00672 buff.write(_struct_3I.pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
00673 _x = self.action_goal.header.frame_id
00674 length = len(_x)
00675 if python3 or type(_x) == unicode:
00676 _x = _x.encode('utf-8')
00677 length = len(_x)
00678 buff.write(struct.pack('<I%ss'%length, length, _x))
00679 _x = self
00680 buff.write(_struct_2I.pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
00681 _x = self.action_goal.goal_id.id
00682 length = len(_x)
00683 if python3 or type(_x) == unicode:
00684 _x = _x.encode('utf-8')
00685 length = len(_x)
00686 buff.write(struct.pack('<I%ss'%length, length, _x))
00687 _x = self.action_goal.goal.name
00688 length = len(_x)
00689 if python3 or type(_x) == unicode:
00690 _x = _x.encode('utf-8')
00691 length = len(_x)
00692 buff.write(struct.pack('<I%ss'%length, length, _x))
00693 _x = self.action_goal.goal.topic
00694 length = len(_x)
00695 if python3 or type(_x) == unicode:
00696 _x = _x.encode('utf-8')
00697 length = len(_x)
00698 buff.write(struct.pack('<I%ss'%length, length, _x))
00699 _x = self
00700 buff.write(_struct_3I.pack(_x.action_goal.goal.cloud.header.seq, _x.action_goal.goal.cloud.header.stamp.secs, _x.action_goal.goal.cloud.header.stamp.nsecs))
00701 _x = self.action_goal.goal.cloud.header.frame_id
00702 length = len(_x)
00703 if python3 or type(_x) == unicode:
00704 _x = _x.encode('utf-8')
00705 length = len(_x)
00706 buff.write(struct.pack('<I%ss'%length, length, _x))
00707 _x = self
00708 buff.write(_struct_2I.pack(_x.action_goal.goal.cloud.height, _x.action_goal.goal.cloud.width))
00709 length = len(self.action_goal.goal.cloud.fields)
00710 buff.write(_struct_I.pack(length))
00711 for val1 in self.action_goal.goal.cloud.fields:
00712 _x = val1.name
00713 length = len(_x)
00714 if python3 or type(_x) == unicode:
00715 _x = _x.encode('utf-8')
00716 length = len(_x)
00717 buff.write(struct.pack('<I%ss'%length, length, _x))
00718 _x = val1
00719 buff.write(_struct_IBI.pack(_x.offset, _x.datatype, _x.count))
00720 _x = self
00721 buff.write(_struct_B2I.pack(_x.action_goal.goal.cloud.is_bigendian, _x.action_goal.goal.cloud.point_step, _x.action_goal.goal.cloud.row_step))
00722 _x = self.action_goal.goal.cloud.data
00723 length = len(_x)
00724
00725 if type(_x) in [list, tuple]:
00726 buff.write(struct.pack('<I%sB'%length, length, *_x))
00727 else:
00728 buff.write(struct.pack('<I%ss'%length, length, _x))
00729 buff.write(_struct_B.pack(self.action_goal.goal.cloud.is_dense))
00730 _x = self.action_goal.goal.storage_frame_id
00731 length = len(_x)
00732 if python3 or type(_x) == unicode:
00733 _x = _x.encode('utf-8')
00734 length = len(_x)
00735 buff.write(struct.pack('<I%ss'%length, length, _x))
00736 _x = self.action_goal.goal.result_frame_id
00737 length = len(_x)
00738 if python3 or type(_x) == unicode:
00739 _x = _x.encode('utf-8')
00740 length = len(_x)
00741 buff.write(struct.pack('<I%ss'%length, length, _x))
00742 _x = self
00743 buff.write(_struct_i3I.pack(_x.action_goal.goal.action, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
00744 _x = self.action_result.header.frame_id
00745 length = len(_x)
00746 if python3 or type(_x) == unicode:
00747 _x = _x.encode('utf-8')
00748 length = len(_x)
00749 buff.write(struct.pack('<I%ss'%length, length, _x))
00750 _x = self
00751 buff.write(_struct_2I.pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
00752 _x = self.action_result.status.goal_id.id
00753 length = len(_x)
00754 if python3 or type(_x) == unicode:
00755 _x = _x.encode('utf-8')
00756 length = len(_x)
00757 buff.write(struct.pack('<I%ss'%length, length, _x))
00758 buff.write(_struct_B.pack(self.action_result.status.status))
00759 _x = self.action_result.status.text
00760 length = len(_x)
00761 if python3 or type(_x) == unicode:
00762 _x = _x.encode('utf-8')
00763 length = len(_x)
00764 buff.write(struct.pack('<I%ss'%length, length, _x))
00765 _x = self
00766 buff.write(_struct_3I.pack(_x.action_result.result.cloud.header.seq, _x.action_result.result.cloud.header.stamp.secs, _x.action_result.result.cloud.header.stamp.nsecs))
00767 _x = self.action_result.result.cloud.header.frame_id
00768 length = len(_x)
00769 if python3 or type(_x) == unicode:
00770 _x = _x.encode('utf-8')
00771 length = len(_x)
00772 buff.write(struct.pack('<I%ss'%length, length, _x))
00773 _x = self
00774 buff.write(_struct_2I.pack(_x.action_result.result.cloud.height, _x.action_result.result.cloud.width))
00775 length = len(self.action_result.result.cloud.fields)
00776 buff.write(_struct_I.pack(length))
00777 for val1 in self.action_result.result.cloud.fields:
00778 _x = val1.name
00779 length = len(_x)
00780 if python3 or type(_x) == unicode:
00781 _x = _x.encode('utf-8')
00782 length = len(_x)
00783 buff.write(struct.pack('<I%ss'%length, length, _x))
00784 _x = val1
00785 buff.write(_struct_IBI.pack(_x.offset, _x.datatype, _x.count))
00786 _x = self
00787 buff.write(_struct_B2I.pack(_x.action_result.result.cloud.is_bigendian, _x.action_result.result.cloud.point_step, _x.action_result.result.cloud.row_step))
00788 _x = self.action_result.result.cloud.data
00789 length = len(_x)
00790
00791 if type(_x) in [list, tuple]:
00792 buff.write(struct.pack('<I%sB'%length, length, *_x))
00793 else:
00794 buff.write(struct.pack('<I%ss'%length, length, _x))
00795 _x = self
00796 buff.write(_struct_Bi3I.pack(_x.action_result.result.cloud.is_dense, _x.action_result.result.result, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
00797 _x = self.action_feedback.header.frame_id
00798 length = len(_x)
00799 if python3 or type(_x) == unicode:
00800 _x = _x.encode('utf-8')
00801 length = len(_x)
00802 buff.write(struct.pack('<I%ss'%length, length, _x))
00803 _x = self
00804 buff.write(_struct_2I.pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
00805 _x = self.action_feedback.status.goal_id.id
00806 length = len(_x)
00807 if python3 or type(_x) == unicode:
00808 _x = _x.encode('utf-8')
00809 length = len(_x)
00810 buff.write(struct.pack('<I%ss'%length, length, _x))
00811 buff.write(_struct_B.pack(self.action_feedback.status.status))
00812 _x = self.action_feedback.status.text
00813 length = len(_x)
00814 if python3 or type(_x) == unicode:
00815 _x = _x.encode('utf-8')
00816 length = len(_x)
00817 buff.write(struct.pack('<I%ss'%length, length, _x))
00818 except struct.error as se: self._check_types(se)
00819 except TypeError as te: self._check_types(te)
00820
00821 def deserialize_numpy(self, str, numpy):
00822 """
00823 unpack serialized message in str into this message instance using numpy for array types
00824 :param str: byte array of serialized message, ``str``
00825 :param numpy: numpy python module
00826 """
00827 try:
00828 if self.action_goal is None:
00829 self.action_goal = point_cloud_server.msg.StoreCloudActionGoal()
00830 if self.action_result is None:
00831 self.action_result = point_cloud_server.msg.StoreCloudActionResult()
00832 if self.action_feedback is None:
00833 self.action_feedback = point_cloud_server.msg.StoreCloudActionFeedback()
00834 end = 0
00835 _x = self
00836 start = end
00837 end += 12
00838 (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00839 start = end
00840 end += 4
00841 (length,) = _struct_I.unpack(str[start:end])
00842 start = end
00843 end += length
00844 if python3:
00845 self.action_goal.header.frame_id = str[start:end].decode('utf-8')
00846 else:
00847 self.action_goal.header.frame_id = str[start:end]
00848 _x = self
00849 start = end
00850 end += 8
00851 (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00852 start = end
00853 end += 4
00854 (length,) = _struct_I.unpack(str[start:end])
00855 start = end
00856 end += length
00857 if python3:
00858 self.action_goal.goal_id.id = str[start:end].decode('utf-8')
00859 else:
00860 self.action_goal.goal_id.id = str[start:end]
00861 start = end
00862 end += 4
00863 (length,) = _struct_I.unpack(str[start:end])
00864 start = end
00865 end += length
00866 if python3:
00867 self.action_goal.goal.name = str[start:end].decode('utf-8')
00868 else:
00869 self.action_goal.goal.name = str[start:end]
00870 start = end
00871 end += 4
00872 (length,) = _struct_I.unpack(str[start:end])
00873 start = end
00874 end += length
00875 if python3:
00876 self.action_goal.goal.topic = str[start:end].decode('utf-8')
00877 else:
00878 self.action_goal.goal.topic = str[start:end]
00879 _x = self
00880 start = end
00881 end += 12
00882 (_x.action_goal.goal.cloud.header.seq, _x.action_goal.goal.cloud.header.stamp.secs, _x.action_goal.goal.cloud.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00883 start = end
00884 end += 4
00885 (length,) = _struct_I.unpack(str[start:end])
00886 start = end
00887 end += length
00888 if python3:
00889 self.action_goal.goal.cloud.header.frame_id = str[start:end].decode('utf-8')
00890 else:
00891 self.action_goal.goal.cloud.header.frame_id = str[start:end]
00892 _x = self
00893 start = end
00894 end += 8
00895 (_x.action_goal.goal.cloud.height, _x.action_goal.goal.cloud.width,) = _struct_2I.unpack(str[start:end])
00896 start = end
00897 end += 4
00898 (length,) = _struct_I.unpack(str[start:end])
00899 self.action_goal.goal.cloud.fields = []
00900 for i in range(0, length):
00901 val1 = sensor_msgs.msg.PointField()
00902 start = end
00903 end += 4
00904 (length,) = _struct_I.unpack(str[start:end])
00905 start = end
00906 end += length
00907 if python3:
00908 val1.name = str[start:end].decode('utf-8')
00909 else:
00910 val1.name = str[start:end]
00911 _x = val1
00912 start = end
00913 end += 9
00914 (_x.offset, _x.datatype, _x.count,) = _struct_IBI.unpack(str[start:end])
00915 self.action_goal.goal.cloud.fields.append(val1)
00916 _x = self
00917 start = end
00918 end += 9
00919 (_x.action_goal.goal.cloud.is_bigendian, _x.action_goal.goal.cloud.point_step, _x.action_goal.goal.cloud.row_step,) = _struct_B2I.unpack(str[start:end])
00920 self.action_goal.goal.cloud.is_bigendian = bool(self.action_goal.goal.cloud.is_bigendian)
00921 start = end
00922 end += 4
00923 (length,) = _struct_I.unpack(str[start:end])
00924 start = end
00925 end += length
00926 if python3:
00927 self.action_goal.goal.cloud.data = str[start:end].decode('utf-8')
00928 else:
00929 self.action_goal.goal.cloud.data = str[start:end]
00930 start = end
00931 end += 1
00932 (self.action_goal.goal.cloud.is_dense,) = _struct_B.unpack(str[start:end])
00933 self.action_goal.goal.cloud.is_dense = bool(self.action_goal.goal.cloud.is_dense)
00934 start = end
00935 end += 4
00936 (length,) = _struct_I.unpack(str[start:end])
00937 start = end
00938 end += length
00939 if python3:
00940 self.action_goal.goal.storage_frame_id = str[start:end].decode('utf-8')
00941 else:
00942 self.action_goal.goal.storage_frame_id = str[start:end]
00943 start = end
00944 end += 4
00945 (length,) = _struct_I.unpack(str[start:end])
00946 start = end
00947 end += length
00948 if python3:
00949 self.action_goal.goal.result_frame_id = str[start:end].decode('utf-8')
00950 else:
00951 self.action_goal.goal.result_frame_id = str[start:end]
00952 _x = self
00953 start = end
00954 end += 16
00955 (_x.action_goal.goal.action, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _struct_i3I.unpack(str[start:end])
00956 start = end
00957 end += 4
00958 (length,) = _struct_I.unpack(str[start:end])
00959 start = end
00960 end += length
00961 if python3:
00962 self.action_result.header.frame_id = str[start:end].decode('utf-8')
00963 else:
00964 self.action_result.header.frame_id = str[start:end]
00965 _x = self
00966 start = end
00967 end += 8
00968 (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00969 start = end
00970 end += 4
00971 (length,) = _struct_I.unpack(str[start:end])
00972 start = end
00973 end += length
00974 if python3:
00975 self.action_result.status.goal_id.id = str[start:end].decode('utf-8')
00976 else:
00977 self.action_result.status.goal_id.id = str[start:end]
00978 start = end
00979 end += 1
00980 (self.action_result.status.status,) = _struct_B.unpack(str[start:end])
00981 start = end
00982 end += 4
00983 (length,) = _struct_I.unpack(str[start:end])
00984 start = end
00985 end += length
00986 if python3:
00987 self.action_result.status.text = str[start:end].decode('utf-8')
00988 else:
00989 self.action_result.status.text = str[start:end]
00990 _x = self
00991 start = end
00992 end += 12
00993 (_x.action_result.result.cloud.header.seq, _x.action_result.result.cloud.header.stamp.secs, _x.action_result.result.cloud.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00994 start = end
00995 end += 4
00996 (length,) = _struct_I.unpack(str[start:end])
00997 start = end
00998 end += length
00999 if python3:
01000 self.action_result.result.cloud.header.frame_id = str[start:end].decode('utf-8')
01001 else:
01002 self.action_result.result.cloud.header.frame_id = str[start:end]
01003 _x = self
01004 start = end
01005 end += 8
01006 (_x.action_result.result.cloud.height, _x.action_result.result.cloud.width,) = _struct_2I.unpack(str[start:end])
01007 start = end
01008 end += 4
01009 (length,) = _struct_I.unpack(str[start:end])
01010 self.action_result.result.cloud.fields = []
01011 for i in range(0, length):
01012 val1 = sensor_msgs.msg.PointField()
01013 start = end
01014 end += 4
01015 (length,) = _struct_I.unpack(str[start:end])
01016 start = end
01017 end += length
01018 if python3:
01019 val1.name = str[start:end].decode('utf-8')
01020 else:
01021 val1.name = str[start:end]
01022 _x = val1
01023 start = end
01024 end += 9
01025 (_x.offset, _x.datatype, _x.count,) = _struct_IBI.unpack(str[start:end])
01026 self.action_result.result.cloud.fields.append(val1)
01027 _x = self
01028 start = end
01029 end += 9
01030 (_x.action_result.result.cloud.is_bigendian, _x.action_result.result.cloud.point_step, _x.action_result.result.cloud.row_step,) = _struct_B2I.unpack(str[start:end])
01031 self.action_result.result.cloud.is_bigendian = bool(self.action_result.result.cloud.is_bigendian)
01032 start = end
01033 end += 4
01034 (length,) = _struct_I.unpack(str[start:end])
01035 start = end
01036 end += length
01037 if python3:
01038 self.action_result.result.cloud.data = str[start:end].decode('utf-8')
01039 else:
01040 self.action_result.result.cloud.data = str[start:end]
01041 _x = self
01042 start = end
01043 end += 17
01044 (_x.action_result.result.cloud.is_dense, _x.action_result.result.result, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _struct_Bi3I.unpack(str[start:end])
01045 self.action_result.result.cloud.is_dense = bool(self.action_result.result.cloud.is_dense)
01046 start = end
01047 end += 4
01048 (length,) = _struct_I.unpack(str[start:end])
01049 start = end
01050 end += length
01051 if python3:
01052 self.action_feedback.header.frame_id = str[start:end].decode('utf-8')
01053 else:
01054 self.action_feedback.header.frame_id = str[start:end]
01055 _x = self
01056 start = end
01057 end += 8
01058 (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
01059 start = end
01060 end += 4
01061 (length,) = _struct_I.unpack(str[start:end])
01062 start = end
01063 end += length
01064 if python3:
01065 self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8')
01066 else:
01067 self.action_feedback.status.goal_id.id = str[start:end]
01068 start = end
01069 end += 1
01070 (self.action_feedback.status.status,) = _struct_B.unpack(str[start:end])
01071 start = end
01072 end += 4
01073 (length,) = _struct_I.unpack(str[start:end])
01074 start = end
01075 end += length
01076 if python3:
01077 self.action_feedback.status.text = str[start:end].decode('utf-8')
01078 else:
01079 self.action_feedback.status.text = str[start:end]
01080 return self
01081 except struct.error as e:
01082 raise genpy.DeserializationError(e)
01083
01084 _struct_I = genpy.struct_I
01085 _struct_IBI = struct.Struct("<IBI")
01086 _struct_B = struct.Struct("<B")
01087 _struct_i3I = struct.Struct("<i3I")
01088 _struct_3I = struct.Struct("<3I")
01089 _struct_B2I = struct.Struct("<B2I")
01090 _struct_Bi3I = struct.Struct("<Bi3I")
01091 _struct_2I = struct.Struct("<2I")