_SetPointClusterGraspParams.py
Go to the documentation of this file.
00001 """autogenerated by genpy from pr2_gripper_grasp_planner_cluster/SetPointClusterGraspParamsRequest.msg. Do not edit."""
00002 import sys
00003 python3 = True if sys.hexversion > 0x03000000 else False
00004 import genpy
00005 import struct
00006 
00007 
00008 class SetPointClusterGraspParamsRequest(genpy.Message):
00009   _md5sum = "176c495282fca5febd8468900b9ef915"
00010   _type = "pr2_gripper_grasp_planner_cluster/SetPointClusterGraspParamsRequest"
00011   _has_header = False #flag to mark the presence of a Header object
00012   _full_text = """
00013 float64 height_good_for_side_grasps
00014 
00015 
00016 float64 gripper_opening
00017 
00018 
00019 float64 side_step
00020 
00021 
00022 float64 palm_step
00023 
00024 
00025 bool overhead_grasps_only
00026 
00027 
00028 bool side_grasps_only
00029 
00030 
00031 bool include_high_point_grasps
00032 
00033 
00034 bool pregrasp_just_outside_box
00035 
00036 
00037 int32 backoff_depth_steps
00038 
00039 
00040 bool disable_grasp_neighbor_check
00041 
00042 
00043 bool randomize_grasps
00044 
00045 
00046 """
00047   __slots__ = ['height_good_for_side_grasps','gripper_opening','side_step','palm_step','overhead_grasps_only','side_grasps_only','include_high_point_grasps','pregrasp_just_outside_box','backoff_depth_steps','disable_grasp_neighbor_check','randomize_grasps']
00048   _slot_types = ['float64','float64','float64','float64','bool','bool','bool','bool','int32','bool','bool']
00049 
00050   def __init__(self, *args, **kwds):
00051     """
00052     Constructor. Any message fields that are implicitly/explicitly
00053     set to None will be assigned a default value. The recommend
00054     use is keyword arguments as this is more robust to future message
00055     changes.  You cannot mix in-order arguments and keyword arguments.
00056 
00057     The available fields are:
00058        height_good_for_side_grasps,gripper_opening,side_step,palm_step,overhead_grasps_only,side_grasps_only,include_high_point_grasps,pregrasp_just_outside_box,backoff_depth_steps,disable_grasp_neighbor_check,randomize_grasps
00059 
00060     :param args: complete set of field values, in .msg order
00061     :param kwds: use keyword arguments corresponding to message field names
00062     to set specific fields.
00063     """
00064     if args or kwds:
00065       super(SetPointClusterGraspParamsRequest, self).__init__(*args, **kwds)
00066       #message fields cannot be None, assign default values for those that are
00067       if self.height_good_for_side_grasps is None:
00068         self.height_good_for_side_grasps = 0.
00069       if self.gripper_opening is None:
00070         self.gripper_opening = 0.
00071       if self.side_step is None:
00072         self.side_step = 0.
00073       if self.palm_step is None:
00074         self.palm_step = 0.
00075       if self.overhead_grasps_only is None:
00076         self.overhead_grasps_only = False
00077       if self.side_grasps_only is None:
00078         self.side_grasps_only = False
00079       if self.include_high_point_grasps is None:
00080         self.include_high_point_grasps = False
00081       if self.pregrasp_just_outside_box is None:
00082         self.pregrasp_just_outside_box = False
00083       if self.backoff_depth_steps is None:
00084         self.backoff_depth_steps = 0
00085       if self.disable_grasp_neighbor_check is None:
00086         self.disable_grasp_neighbor_check = False
00087       if self.randomize_grasps is None:
00088         self.randomize_grasps = False
00089     else:
00090       self.height_good_for_side_grasps = 0.
00091       self.gripper_opening = 0.
00092       self.side_step = 0.
00093       self.palm_step = 0.
00094       self.overhead_grasps_only = False
00095       self.side_grasps_only = False
00096       self.include_high_point_grasps = False
00097       self.pregrasp_just_outside_box = False
00098       self.backoff_depth_steps = 0
00099       self.disable_grasp_neighbor_check = False
00100       self.randomize_grasps = False
00101 
00102   def _get_types(self):
00103     """
00104     internal API method
00105     """
00106     return self._slot_types
00107 
00108   def serialize(self, buff):
00109     """
00110     serialize message into buffer
00111     :param buff: buffer, ``StringIO``
00112     """
00113     try:
00114       _x = self
00115       buff.write(_struct_4d4Bi2B.pack(_x.height_good_for_side_grasps, _x.gripper_opening, _x.side_step, _x.palm_step, _x.overhead_grasps_only, _x.side_grasps_only, _x.include_high_point_grasps, _x.pregrasp_just_outside_box, _x.backoff_depth_steps, _x.disable_grasp_neighbor_check, _x.randomize_grasps))
00116     except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(_x))))
00117     except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(_x))))
00118 
00119   def deserialize(self, str):
00120     """
00121     unpack serialized message in str into this message instance
00122     :param str: byte array of serialized message, ``str``
00123     """
00124     try:
00125       end = 0
00126       _x = self
00127       start = end
00128       end += 42
00129       (_x.height_good_for_side_grasps, _x.gripper_opening, _x.side_step, _x.palm_step, _x.overhead_grasps_only, _x.side_grasps_only, _x.include_high_point_grasps, _x.pregrasp_just_outside_box, _x.backoff_depth_steps, _x.disable_grasp_neighbor_check, _x.randomize_grasps,) = _struct_4d4Bi2B.unpack(str[start:end])
00130       self.overhead_grasps_only = bool(self.overhead_grasps_only)
00131       self.side_grasps_only = bool(self.side_grasps_only)
00132       self.include_high_point_grasps = bool(self.include_high_point_grasps)
00133       self.pregrasp_just_outside_box = bool(self.pregrasp_just_outside_box)
00134       self.disable_grasp_neighbor_check = bool(self.disable_grasp_neighbor_check)
00135       self.randomize_grasps = bool(self.randomize_grasps)
00136       return self
00137     except struct.error as e:
00138       raise genpy.DeserializationError(e) #most likely buffer underfill
00139 
00140 
00141   def serialize_numpy(self, buff, numpy):
00142     """
00143     serialize message with numpy array types into buffer
00144     :param buff: buffer, ``StringIO``
00145     :param numpy: numpy python module
00146     """
00147     try:
00148       _x = self
00149       buff.write(_struct_4d4Bi2B.pack(_x.height_good_for_side_grasps, _x.gripper_opening, _x.side_step, _x.palm_step, _x.overhead_grasps_only, _x.side_grasps_only, _x.include_high_point_grasps, _x.pregrasp_just_outside_box, _x.backoff_depth_steps, _x.disable_grasp_neighbor_check, _x.randomize_grasps))
00150     except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(_x))))
00151     except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(_x))))
00152 
00153   def deserialize_numpy(self, str, numpy):
00154     """
00155     unpack serialized message in str into this message instance using numpy for array types
00156     :param str: byte array of serialized message, ``str``
00157     :param numpy: numpy python module
00158     """
00159     try:
00160       end = 0
00161       _x = self
00162       start = end
00163       end += 42
00164       (_x.height_good_for_side_grasps, _x.gripper_opening, _x.side_step, _x.palm_step, _x.overhead_grasps_only, _x.side_grasps_only, _x.include_high_point_grasps, _x.pregrasp_just_outside_box, _x.backoff_depth_steps, _x.disable_grasp_neighbor_check, _x.randomize_grasps,) = _struct_4d4Bi2B.unpack(str[start:end])
00165       self.overhead_grasps_only = bool(self.overhead_grasps_only)
00166       self.side_grasps_only = bool(self.side_grasps_only)
00167       self.include_high_point_grasps = bool(self.include_high_point_grasps)
00168       self.pregrasp_just_outside_box = bool(self.pregrasp_just_outside_box)
00169       self.disable_grasp_neighbor_check = bool(self.disable_grasp_neighbor_check)
00170       self.randomize_grasps = bool(self.randomize_grasps)
00171       return self
00172     except struct.error as e:
00173       raise genpy.DeserializationError(e) #most likely buffer underfill
00174 
00175 _struct_I = genpy.struct_I
00176 _struct_4d4Bi2B = struct.Struct("<4d4Bi2B")
00177 """autogenerated by genpy from pr2_gripper_grasp_planner_cluster/SetPointClusterGraspParamsResponse.msg. Do not edit."""
00178 import sys
00179 python3 = True if sys.hexversion > 0x03000000 else False
00180 import genpy
00181 import struct
00182 
00183 
00184 class SetPointClusterGraspParamsResponse(genpy.Message):
00185   _md5sum = "d41d8cd98f00b204e9800998ecf8427e"
00186   _type = "pr2_gripper_grasp_planner_cluster/SetPointClusterGraspParamsResponse"
00187   _has_header = False #flag to mark the presence of a Header object
00188   _full_text = """
00189 """
00190   __slots__ = []
00191   _slot_types = []
00192 
00193   def __init__(self, *args, **kwds):
00194     """
00195     Constructor. Any message fields that are implicitly/explicitly
00196     set to None will be assigned a default value. The recommend
00197     use is keyword arguments as this is more robust to future message
00198     changes.  You cannot mix in-order arguments and keyword arguments.
00199 
00200     The available fields are:
00201        
00202 
00203     :param args: complete set of field values, in .msg order
00204     :param kwds: use keyword arguments corresponding to message field names
00205     to set specific fields.
00206     """
00207     if args or kwds:
00208       super(SetPointClusterGraspParamsResponse, self).__init__(*args, **kwds)
00209 
00210   def _get_types(self):
00211     """
00212     internal API method
00213     """
00214     return self._slot_types
00215 
00216   def serialize(self, buff):
00217     """
00218     serialize message into buffer
00219     :param buff: buffer, ``StringIO``
00220     """
00221     try:
00222       pass
00223     except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(_x))))
00224     except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(_x))))
00225 
00226   def deserialize(self, str):
00227     """
00228     unpack serialized message in str into this message instance
00229     :param str: byte array of serialized message, ``str``
00230     """
00231     try:
00232       end = 0
00233       return self
00234     except struct.error as e:
00235       raise genpy.DeserializationError(e) #most likely buffer underfill
00236 
00237 
00238   def serialize_numpy(self, buff, numpy):
00239     """
00240     serialize message with numpy array types into buffer
00241     :param buff: buffer, ``StringIO``
00242     :param numpy: numpy python module
00243     """
00244     try:
00245       pass
00246     except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(_x))))
00247     except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(_x))))
00248 
00249   def deserialize_numpy(self, str, numpy):
00250     """
00251     unpack serialized message in str into this message instance using numpy for array types
00252     :param str: byte array of serialized message, ``str``
00253     :param numpy: numpy python module
00254     """
00255     try:
00256       end = 0
00257       return self
00258     except struct.error as e:
00259       raise genpy.DeserializationError(e) #most likely buffer underfill
00260 
00261 _struct_I = genpy.struct_I
00262 class SetPointClusterGraspParams(object):
00263   _type          = 'pr2_gripper_grasp_planner_cluster/SetPointClusterGraspParams'
00264   _md5sum = '176c495282fca5febd8468900b9ef915'
00265   _request_class  = SetPointClusterGraspParamsRequest
00266   _response_class = SetPointClusterGraspParamsResponse


pr2_gripper_grasp_planner_cluster
Author(s): Kaijen Hsiao
autogenerated on Mon Oct 6 2014 12:13:03