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


point_cloud_server
Author(s): Adam Leeper
autogenerated on Thu Jan 2 2014 11:39:34