00001 """autogenerated by genpy from pddl_msgs/PDDLPlannerActionGoal.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 pddl_msgs.msg
00008 import genpy
00009 import actionlib_msgs.msg
00010 import std_msgs.msg
00011
00012 class PDDLPlannerActionGoal(genpy.Message):
00013 _md5sum = "61ae93f058612134a6e1bf37515701d5"
00014 _type = "pddl_msgs/PDDLPlannerActionGoal"
00015 _has_header = True
00016 _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00017
00018 Header header
00019 actionlib_msgs/GoalID goal_id
00020 PDDLPlannerGoal goal
00021
00022 ================================================================================
00023 MSG: std_msgs/Header
00024 # Standard metadata for higher-level stamped data types.
00025 # This is generally used to communicate timestamped data
00026 # in a particular coordinate frame.
00027 #
00028 # sequence ID: consecutively increasing ID
00029 uint32 seq
00030 #Two-integer timestamp that is expressed as:
00031 # * stamp.secs: seconds (stamp_secs) since epoch
00032 # * stamp.nsecs: nanoseconds since stamp_secs
00033 # time-handling sugar is provided by the client library
00034 time stamp
00035 #Frame this data is associated with
00036 # 0: no frame
00037 # 1: global frame
00038 string frame_id
00039
00040 ================================================================================
00041 MSG: actionlib_msgs/GoalID
00042 # The stamp should store the time at which this goal was requested.
00043 # It is used by an action server when it tries to preempt all
00044 # goals that were requested before a certain time
00045 time stamp
00046
00047 # The id provides a way to associate feedback and
00048 # result message with specific goal requests. The id
00049 # specified must be unique.
00050 string id
00051
00052
00053 ================================================================================
00054 MSG: pddl_msgs/PDDLPlannerGoal
00055 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00056 # goal
00057 pddl_msgs/PDDLDomain domain
00058 pddl_msgs/PDDLProblem problem
00059
00060 ================================================================================
00061 MSG: pddl_msgs/PDDLDomain
00062 string name
00063 string requirements
00064 string[] types
00065 string[] constants
00066 string[] predicates
00067 pddl_msgs/PDDLAction[] actions
00068 string[] functions
00069
00070 ================================================================================
00071 MSG: pddl_msgs/PDDLAction
00072 string name
00073 # write String in S expression like "(and foo var)"
00074 string parameters
00075 string precondition
00076 string effect
00077 string on_condition
00078
00079 ================================================================================
00080 MSG: pddl_msgs/PDDLProblem
00081 string name # name of problem
00082 string domain # name of domain to use
00083 pddl_msgs/PDDLObject[] objects # how to represent type?
00084 string[] initial # initial condition
00085 string goal # goal conjunction
00086
00087 ================================================================================
00088 MSG: pddl_msgs/PDDLObject
00089 # definition of PDDLObject
00090 string name
00091 string type
00092
00093 """
00094 __slots__ = ['header','goal_id','goal']
00095 _slot_types = ['std_msgs/Header','actionlib_msgs/GoalID','pddl_msgs/PDDLPlannerGoal']
00096
00097 def __init__(self, *args, **kwds):
00098 """
00099 Constructor. Any message fields that are implicitly/explicitly
00100 set to None will be assigned a default value. The recommend
00101 use is keyword arguments as this is more robust to future message
00102 changes. You cannot mix in-order arguments and keyword arguments.
00103
00104 The available fields are:
00105 header,goal_id,goal
00106
00107 :param args: complete set of field values, in .msg order
00108 :param kwds: use keyword arguments corresponding to message field names
00109 to set specific fields.
00110 """
00111 if args or kwds:
00112 super(PDDLPlannerActionGoal, self).__init__(*args, **kwds)
00113
00114 if self.header is None:
00115 self.header = std_msgs.msg.Header()
00116 if self.goal_id is None:
00117 self.goal_id = actionlib_msgs.msg.GoalID()
00118 if self.goal is None:
00119 self.goal = pddl_msgs.msg.PDDLPlannerGoal()
00120 else:
00121 self.header = std_msgs.msg.Header()
00122 self.goal_id = actionlib_msgs.msg.GoalID()
00123 self.goal = pddl_msgs.msg.PDDLPlannerGoal()
00124
00125 def _get_types(self):
00126 """
00127 internal API method
00128 """
00129 return self._slot_types
00130
00131 def serialize(self, buff):
00132 """
00133 serialize message into buffer
00134 :param buff: buffer, ``StringIO``
00135 """
00136 try:
00137 _x = self
00138 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs))
00139 _x = self.header.frame_id
00140 length = len(_x)
00141 if python3 or type(_x) == unicode:
00142 _x = _x.encode('utf-8')
00143 length = len(_x)
00144 buff.write(struct.pack('<I%ss'%length, length, _x))
00145 _x = self
00146 buff.write(_struct_2I.pack(_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs))
00147 _x = self.goal_id.id
00148 length = len(_x)
00149 if python3 or type(_x) == unicode:
00150 _x = _x.encode('utf-8')
00151 length = len(_x)
00152 buff.write(struct.pack('<I%ss'%length, length, _x))
00153 _x = self.goal.domain.name
00154 length = len(_x)
00155 if python3 or type(_x) == unicode:
00156 _x = _x.encode('utf-8')
00157 length = len(_x)
00158 buff.write(struct.pack('<I%ss'%length, length, _x))
00159 _x = self.goal.domain.requirements
00160 length = len(_x)
00161 if python3 or type(_x) == unicode:
00162 _x = _x.encode('utf-8')
00163 length = len(_x)
00164 buff.write(struct.pack('<I%ss'%length, length, _x))
00165 length = len(self.goal.domain.types)
00166 buff.write(_struct_I.pack(length))
00167 for val1 in self.goal.domain.types:
00168 length = len(val1)
00169 if python3 or type(val1) == unicode:
00170 val1 = val1.encode('utf-8')
00171 length = len(val1)
00172 buff.write(struct.pack('<I%ss'%length, length, val1))
00173 length = len(self.goal.domain.constants)
00174 buff.write(_struct_I.pack(length))
00175 for val1 in self.goal.domain.constants:
00176 length = len(val1)
00177 if python3 or type(val1) == unicode:
00178 val1 = val1.encode('utf-8')
00179 length = len(val1)
00180 buff.write(struct.pack('<I%ss'%length, length, val1))
00181 length = len(self.goal.domain.predicates)
00182 buff.write(_struct_I.pack(length))
00183 for val1 in self.goal.domain.predicates:
00184 length = len(val1)
00185 if python3 or type(val1) == unicode:
00186 val1 = val1.encode('utf-8')
00187 length = len(val1)
00188 buff.write(struct.pack('<I%ss'%length, length, val1))
00189 length = len(self.goal.domain.actions)
00190 buff.write(_struct_I.pack(length))
00191 for val1 in self.goal.domain.actions:
00192 _x = val1.name
00193 length = len(_x)
00194 if python3 or type(_x) == unicode:
00195 _x = _x.encode('utf-8')
00196 length = len(_x)
00197 buff.write(struct.pack('<I%ss'%length, length, _x))
00198 _x = val1.parameters
00199 length = len(_x)
00200 if python3 or type(_x) == unicode:
00201 _x = _x.encode('utf-8')
00202 length = len(_x)
00203 buff.write(struct.pack('<I%ss'%length, length, _x))
00204 _x = val1.precondition
00205 length = len(_x)
00206 if python3 or type(_x) == unicode:
00207 _x = _x.encode('utf-8')
00208 length = len(_x)
00209 buff.write(struct.pack('<I%ss'%length, length, _x))
00210 _x = val1.effect
00211 length = len(_x)
00212 if python3 or type(_x) == unicode:
00213 _x = _x.encode('utf-8')
00214 length = len(_x)
00215 buff.write(struct.pack('<I%ss'%length, length, _x))
00216 _x = val1.on_condition
00217 length = len(_x)
00218 if python3 or type(_x) == unicode:
00219 _x = _x.encode('utf-8')
00220 length = len(_x)
00221 buff.write(struct.pack('<I%ss'%length, length, _x))
00222 length = len(self.goal.domain.functions)
00223 buff.write(_struct_I.pack(length))
00224 for val1 in self.goal.domain.functions:
00225 length = len(val1)
00226 if python3 or type(val1) == unicode:
00227 val1 = val1.encode('utf-8')
00228 length = len(val1)
00229 buff.write(struct.pack('<I%ss'%length, length, val1))
00230 _x = self.goal.problem.name
00231 length = len(_x)
00232 if python3 or type(_x) == unicode:
00233 _x = _x.encode('utf-8')
00234 length = len(_x)
00235 buff.write(struct.pack('<I%ss'%length, length, _x))
00236 _x = self.goal.problem.domain
00237 length = len(_x)
00238 if python3 or type(_x) == unicode:
00239 _x = _x.encode('utf-8')
00240 length = len(_x)
00241 buff.write(struct.pack('<I%ss'%length, length, _x))
00242 length = len(self.goal.problem.objects)
00243 buff.write(_struct_I.pack(length))
00244 for val1 in self.goal.problem.objects:
00245 _x = val1.name
00246 length = len(_x)
00247 if python3 or type(_x) == unicode:
00248 _x = _x.encode('utf-8')
00249 length = len(_x)
00250 buff.write(struct.pack('<I%ss'%length, length, _x))
00251 _x = val1.type
00252 length = len(_x)
00253 if python3 or type(_x) == unicode:
00254 _x = _x.encode('utf-8')
00255 length = len(_x)
00256 buff.write(struct.pack('<I%ss'%length, length, _x))
00257 length = len(self.goal.problem.initial)
00258 buff.write(_struct_I.pack(length))
00259 for val1 in self.goal.problem.initial:
00260 length = len(val1)
00261 if python3 or type(val1) == unicode:
00262 val1 = val1.encode('utf-8')
00263 length = len(val1)
00264 buff.write(struct.pack('<I%ss'%length, length, val1))
00265 _x = self.goal.problem.goal
00266 length = len(_x)
00267 if python3 or type(_x) == unicode:
00268 _x = _x.encode('utf-8')
00269 length = len(_x)
00270 buff.write(struct.pack('<I%ss'%length, length, _x))
00271 except struct.error as se: self._check_types(se)
00272 except TypeError as te: self._check_types(te)
00273
00274 def deserialize(self, str):
00275 """
00276 unpack serialized message in str into this message instance
00277 :param str: byte array of serialized message, ``str``
00278 """
00279 try:
00280 if self.header is None:
00281 self.header = std_msgs.msg.Header()
00282 if self.goal_id is None:
00283 self.goal_id = actionlib_msgs.msg.GoalID()
00284 if self.goal is None:
00285 self.goal = pddl_msgs.msg.PDDLPlannerGoal()
00286 end = 0
00287 _x = self
00288 start = end
00289 end += 12
00290 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00291 start = end
00292 end += 4
00293 (length,) = _struct_I.unpack(str[start:end])
00294 start = end
00295 end += length
00296 if python3:
00297 self.header.frame_id = str[start:end].decode('utf-8')
00298 else:
00299 self.header.frame_id = str[start:end]
00300 _x = self
00301 start = end
00302 end += 8
00303 (_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00304 start = end
00305 end += 4
00306 (length,) = _struct_I.unpack(str[start:end])
00307 start = end
00308 end += length
00309 if python3:
00310 self.goal_id.id = str[start:end].decode('utf-8')
00311 else:
00312 self.goal_id.id = str[start:end]
00313 start = end
00314 end += 4
00315 (length,) = _struct_I.unpack(str[start:end])
00316 start = end
00317 end += length
00318 if python3:
00319 self.goal.domain.name = str[start:end].decode('utf-8')
00320 else:
00321 self.goal.domain.name = str[start:end]
00322 start = end
00323 end += 4
00324 (length,) = _struct_I.unpack(str[start:end])
00325 start = end
00326 end += length
00327 if python3:
00328 self.goal.domain.requirements = str[start:end].decode('utf-8')
00329 else:
00330 self.goal.domain.requirements = str[start:end]
00331 start = end
00332 end += 4
00333 (length,) = _struct_I.unpack(str[start:end])
00334 self.goal.domain.types = []
00335 for i in range(0, length):
00336 start = end
00337 end += 4
00338 (length,) = _struct_I.unpack(str[start:end])
00339 start = end
00340 end += length
00341 if python3:
00342 val1 = str[start:end].decode('utf-8')
00343 else:
00344 val1 = str[start:end]
00345 self.goal.domain.types.append(val1)
00346 start = end
00347 end += 4
00348 (length,) = _struct_I.unpack(str[start:end])
00349 self.goal.domain.constants = []
00350 for i in range(0, length):
00351 start = end
00352 end += 4
00353 (length,) = _struct_I.unpack(str[start:end])
00354 start = end
00355 end += length
00356 if python3:
00357 val1 = str[start:end].decode('utf-8')
00358 else:
00359 val1 = str[start:end]
00360 self.goal.domain.constants.append(val1)
00361 start = end
00362 end += 4
00363 (length,) = _struct_I.unpack(str[start:end])
00364 self.goal.domain.predicates = []
00365 for i in range(0, length):
00366 start = end
00367 end += 4
00368 (length,) = _struct_I.unpack(str[start:end])
00369 start = end
00370 end += length
00371 if python3:
00372 val1 = str[start:end].decode('utf-8')
00373 else:
00374 val1 = str[start:end]
00375 self.goal.domain.predicates.append(val1)
00376 start = end
00377 end += 4
00378 (length,) = _struct_I.unpack(str[start:end])
00379 self.goal.domain.actions = []
00380 for i in range(0, length):
00381 val1 = pddl_msgs.msg.PDDLAction()
00382 start = end
00383 end += 4
00384 (length,) = _struct_I.unpack(str[start:end])
00385 start = end
00386 end += length
00387 if python3:
00388 val1.name = str[start:end].decode('utf-8')
00389 else:
00390 val1.name = str[start:end]
00391 start = end
00392 end += 4
00393 (length,) = _struct_I.unpack(str[start:end])
00394 start = end
00395 end += length
00396 if python3:
00397 val1.parameters = str[start:end].decode('utf-8')
00398 else:
00399 val1.parameters = str[start:end]
00400 start = end
00401 end += 4
00402 (length,) = _struct_I.unpack(str[start:end])
00403 start = end
00404 end += length
00405 if python3:
00406 val1.precondition = str[start:end].decode('utf-8')
00407 else:
00408 val1.precondition = str[start:end]
00409 start = end
00410 end += 4
00411 (length,) = _struct_I.unpack(str[start:end])
00412 start = end
00413 end += length
00414 if python3:
00415 val1.effect = str[start:end].decode('utf-8')
00416 else:
00417 val1.effect = 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 val1.on_condition = str[start:end].decode('utf-8')
00425 else:
00426 val1.on_condition = str[start:end]
00427 self.goal.domain.actions.append(val1)
00428 start = end
00429 end += 4
00430 (length,) = _struct_I.unpack(str[start:end])
00431 self.goal.domain.functions = []
00432 for i in range(0, length):
00433 start = end
00434 end += 4
00435 (length,) = _struct_I.unpack(str[start:end])
00436 start = end
00437 end += length
00438 if python3:
00439 val1 = str[start:end].decode('utf-8')
00440 else:
00441 val1 = str[start:end]
00442 self.goal.domain.functions.append(val1)
00443 start = end
00444 end += 4
00445 (length,) = _struct_I.unpack(str[start:end])
00446 start = end
00447 end += length
00448 if python3:
00449 self.goal.problem.name = str[start:end].decode('utf-8')
00450 else:
00451 self.goal.problem.name = str[start:end]
00452 start = end
00453 end += 4
00454 (length,) = _struct_I.unpack(str[start:end])
00455 start = end
00456 end += length
00457 if python3:
00458 self.goal.problem.domain = str[start:end].decode('utf-8')
00459 else:
00460 self.goal.problem.domain = str[start:end]
00461 start = end
00462 end += 4
00463 (length,) = _struct_I.unpack(str[start:end])
00464 self.goal.problem.objects = []
00465 for i in range(0, length):
00466 val1 = pddl_msgs.msg.PDDLObject()
00467 start = end
00468 end += 4
00469 (length,) = _struct_I.unpack(str[start:end])
00470 start = end
00471 end += length
00472 if python3:
00473 val1.name = str[start:end].decode('utf-8')
00474 else:
00475 val1.name = str[start:end]
00476 start = end
00477 end += 4
00478 (length,) = _struct_I.unpack(str[start:end])
00479 start = end
00480 end += length
00481 if python3:
00482 val1.type = str[start:end].decode('utf-8')
00483 else:
00484 val1.type = str[start:end]
00485 self.goal.problem.objects.append(val1)
00486 start = end
00487 end += 4
00488 (length,) = _struct_I.unpack(str[start:end])
00489 self.goal.problem.initial = []
00490 for i in range(0, length):
00491 start = end
00492 end += 4
00493 (length,) = _struct_I.unpack(str[start:end])
00494 start = end
00495 end += length
00496 if python3:
00497 val1 = str[start:end].decode('utf-8')
00498 else:
00499 val1 = str[start:end]
00500 self.goal.problem.initial.append(val1)
00501 start = end
00502 end += 4
00503 (length,) = _struct_I.unpack(str[start:end])
00504 start = end
00505 end += length
00506 if python3:
00507 self.goal.problem.goal = str[start:end].decode('utf-8')
00508 else:
00509 self.goal.problem.goal = str[start:end]
00510 return self
00511 except struct.error as e:
00512 raise genpy.DeserializationError(e)
00513
00514
00515 def serialize_numpy(self, buff, numpy):
00516 """
00517 serialize message with numpy array types into buffer
00518 :param buff: buffer, ``StringIO``
00519 :param numpy: numpy python module
00520 """
00521 try:
00522 _x = self
00523 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs))
00524 _x = self.header.frame_id
00525 length = len(_x)
00526 if python3 or type(_x) == unicode:
00527 _x = _x.encode('utf-8')
00528 length = len(_x)
00529 buff.write(struct.pack('<I%ss'%length, length, _x))
00530 _x = self
00531 buff.write(_struct_2I.pack(_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs))
00532 _x = self.goal_id.id
00533 length = len(_x)
00534 if python3 or type(_x) == unicode:
00535 _x = _x.encode('utf-8')
00536 length = len(_x)
00537 buff.write(struct.pack('<I%ss'%length, length, _x))
00538 _x = self.goal.domain.name
00539 length = len(_x)
00540 if python3 or type(_x) == unicode:
00541 _x = _x.encode('utf-8')
00542 length = len(_x)
00543 buff.write(struct.pack('<I%ss'%length, length, _x))
00544 _x = self.goal.domain.requirements
00545 length = len(_x)
00546 if python3 or type(_x) == unicode:
00547 _x = _x.encode('utf-8')
00548 length = len(_x)
00549 buff.write(struct.pack('<I%ss'%length, length, _x))
00550 length = len(self.goal.domain.types)
00551 buff.write(_struct_I.pack(length))
00552 for val1 in self.goal.domain.types:
00553 length = len(val1)
00554 if python3 or type(val1) == unicode:
00555 val1 = val1.encode('utf-8')
00556 length = len(val1)
00557 buff.write(struct.pack('<I%ss'%length, length, val1))
00558 length = len(self.goal.domain.constants)
00559 buff.write(_struct_I.pack(length))
00560 for val1 in self.goal.domain.constants:
00561 length = len(val1)
00562 if python3 or type(val1) == unicode:
00563 val1 = val1.encode('utf-8')
00564 length = len(val1)
00565 buff.write(struct.pack('<I%ss'%length, length, val1))
00566 length = len(self.goal.domain.predicates)
00567 buff.write(_struct_I.pack(length))
00568 for val1 in self.goal.domain.predicates:
00569 length = len(val1)
00570 if python3 or type(val1) == unicode:
00571 val1 = val1.encode('utf-8')
00572 length = len(val1)
00573 buff.write(struct.pack('<I%ss'%length, length, val1))
00574 length = len(self.goal.domain.actions)
00575 buff.write(_struct_I.pack(length))
00576 for val1 in self.goal.domain.actions:
00577 _x = val1.name
00578 length = len(_x)
00579 if python3 or type(_x) == unicode:
00580 _x = _x.encode('utf-8')
00581 length = len(_x)
00582 buff.write(struct.pack('<I%ss'%length, length, _x))
00583 _x = val1.parameters
00584 length = len(_x)
00585 if python3 or type(_x) == unicode:
00586 _x = _x.encode('utf-8')
00587 length = len(_x)
00588 buff.write(struct.pack('<I%ss'%length, length, _x))
00589 _x = val1.precondition
00590 length = len(_x)
00591 if python3 or type(_x) == unicode:
00592 _x = _x.encode('utf-8')
00593 length = len(_x)
00594 buff.write(struct.pack('<I%ss'%length, length, _x))
00595 _x = val1.effect
00596 length = len(_x)
00597 if python3 or type(_x) == unicode:
00598 _x = _x.encode('utf-8')
00599 length = len(_x)
00600 buff.write(struct.pack('<I%ss'%length, length, _x))
00601 _x = val1.on_condition
00602 length = len(_x)
00603 if python3 or type(_x) == unicode:
00604 _x = _x.encode('utf-8')
00605 length = len(_x)
00606 buff.write(struct.pack('<I%ss'%length, length, _x))
00607 length = len(self.goal.domain.functions)
00608 buff.write(_struct_I.pack(length))
00609 for val1 in self.goal.domain.functions:
00610 length = len(val1)
00611 if python3 or type(val1) == unicode:
00612 val1 = val1.encode('utf-8')
00613 length = len(val1)
00614 buff.write(struct.pack('<I%ss'%length, length, val1))
00615 _x = self.goal.problem.name
00616 length = len(_x)
00617 if python3 or type(_x) == unicode:
00618 _x = _x.encode('utf-8')
00619 length = len(_x)
00620 buff.write(struct.pack('<I%ss'%length, length, _x))
00621 _x = self.goal.problem.domain
00622 length = len(_x)
00623 if python3 or type(_x) == unicode:
00624 _x = _x.encode('utf-8')
00625 length = len(_x)
00626 buff.write(struct.pack('<I%ss'%length, length, _x))
00627 length = len(self.goal.problem.objects)
00628 buff.write(_struct_I.pack(length))
00629 for val1 in self.goal.problem.objects:
00630 _x = val1.name
00631 length = len(_x)
00632 if python3 or type(_x) == unicode:
00633 _x = _x.encode('utf-8')
00634 length = len(_x)
00635 buff.write(struct.pack('<I%ss'%length, length, _x))
00636 _x = val1.type
00637 length = len(_x)
00638 if python3 or type(_x) == unicode:
00639 _x = _x.encode('utf-8')
00640 length = len(_x)
00641 buff.write(struct.pack('<I%ss'%length, length, _x))
00642 length = len(self.goal.problem.initial)
00643 buff.write(_struct_I.pack(length))
00644 for val1 in self.goal.problem.initial:
00645 length = len(val1)
00646 if python3 or type(val1) == unicode:
00647 val1 = val1.encode('utf-8')
00648 length = len(val1)
00649 buff.write(struct.pack('<I%ss'%length, length, val1))
00650 _x = self.goal.problem.goal
00651 length = len(_x)
00652 if python3 or type(_x) == unicode:
00653 _x = _x.encode('utf-8')
00654 length = len(_x)
00655 buff.write(struct.pack('<I%ss'%length, length, _x))
00656 except struct.error as se: self._check_types(se)
00657 except TypeError as te: self._check_types(te)
00658
00659 def deserialize_numpy(self, str, numpy):
00660 """
00661 unpack serialized message in str into this message instance using numpy for array types
00662 :param str: byte array of serialized message, ``str``
00663 :param numpy: numpy python module
00664 """
00665 try:
00666 if self.header is None:
00667 self.header = std_msgs.msg.Header()
00668 if self.goal_id is None:
00669 self.goal_id = actionlib_msgs.msg.GoalID()
00670 if self.goal is None:
00671 self.goal = pddl_msgs.msg.PDDLPlannerGoal()
00672 end = 0
00673 _x = self
00674 start = end
00675 end += 12
00676 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00677 start = end
00678 end += 4
00679 (length,) = _struct_I.unpack(str[start:end])
00680 start = end
00681 end += length
00682 if python3:
00683 self.header.frame_id = str[start:end].decode('utf-8')
00684 else:
00685 self.header.frame_id = str[start:end]
00686 _x = self
00687 start = end
00688 end += 8
00689 (_x.goal_id.stamp.secs, _x.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00690 start = end
00691 end += 4
00692 (length,) = _struct_I.unpack(str[start:end])
00693 start = end
00694 end += length
00695 if python3:
00696 self.goal_id.id = str[start:end].decode('utf-8')
00697 else:
00698 self.goal_id.id = str[start:end]
00699 start = end
00700 end += 4
00701 (length,) = _struct_I.unpack(str[start:end])
00702 start = end
00703 end += length
00704 if python3:
00705 self.goal.domain.name = str[start:end].decode('utf-8')
00706 else:
00707 self.goal.domain.name = str[start:end]
00708 start = end
00709 end += 4
00710 (length,) = _struct_I.unpack(str[start:end])
00711 start = end
00712 end += length
00713 if python3:
00714 self.goal.domain.requirements = str[start:end].decode('utf-8')
00715 else:
00716 self.goal.domain.requirements = str[start:end]
00717 start = end
00718 end += 4
00719 (length,) = _struct_I.unpack(str[start:end])
00720 self.goal.domain.types = []
00721 for i in range(0, length):
00722 start = end
00723 end += 4
00724 (length,) = _struct_I.unpack(str[start:end])
00725 start = end
00726 end += length
00727 if python3:
00728 val1 = str[start:end].decode('utf-8')
00729 else:
00730 val1 = str[start:end]
00731 self.goal.domain.types.append(val1)
00732 start = end
00733 end += 4
00734 (length,) = _struct_I.unpack(str[start:end])
00735 self.goal.domain.constants = []
00736 for i in range(0, length):
00737 start = end
00738 end += 4
00739 (length,) = _struct_I.unpack(str[start:end])
00740 start = end
00741 end += length
00742 if python3:
00743 val1 = str[start:end].decode('utf-8')
00744 else:
00745 val1 = str[start:end]
00746 self.goal.domain.constants.append(val1)
00747 start = end
00748 end += 4
00749 (length,) = _struct_I.unpack(str[start:end])
00750 self.goal.domain.predicates = []
00751 for i in range(0, length):
00752 start = end
00753 end += 4
00754 (length,) = _struct_I.unpack(str[start:end])
00755 start = end
00756 end += length
00757 if python3:
00758 val1 = str[start:end].decode('utf-8')
00759 else:
00760 val1 = str[start:end]
00761 self.goal.domain.predicates.append(val1)
00762 start = end
00763 end += 4
00764 (length,) = _struct_I.unpack(str[start:end])
00765 self.goal.domain.actions = []
00766 for i in range(0, length):
00767 val1 = pddl_msgs.msg.PDDLAction()
00768 start = end
00769 end += 4
00770 (length,) = _struct_I.unpack(str[start:end])
00771 start = end
00772 end += length
00773 if python3:
00774 val1.name = str[start:end].decode('utf-8')
00775 else:
00776 val1.name = str[start:end]
00777 start = end
00778 end += 4
00779 (length,) = _struct_I.unpack(str[start:end])
00780 start = end
00781 end += length
00782 if python3:
00783 val1.parameters = str[start:end].decode('utf-8')
00784 else:
00785 val1.parameters = str[start:end]
00786 start = end
00787 end += 4
00788 (length,) = _struct_I.unpack(str[start:end])
00789 start = end
00790 end += length
00791 if python3:
00792 val1.precondition = str[start:end].decode('utf-8')
00793 else:
00794 val1.precondition = str[start:end]
00795 start = end
00796 end += 4
00797 (length,) = _struct_I.unpack(str[start:end])
00798 start = end
00799 end += length
00800 if python3:
00801 val1.effect = str[start:end].decode('utf-8')
00802 else:
00803 val1.effect = str[start:end]
00804 start = end
00805 end += 4
00806 (length,) = _struct_I.unpack(str[start:end])
00807 start = end
00808 end += length
00809 if python3:
00810 val1.on_condition = str[start:end].decode('utf-8')
00811 else:
00812 val1.on_condition = str[start:end]
00813 self.goal.domain.actions.append(val1)
00814 start = end
00815 end += 4
00816 (length,) = _struct_I.unpack(str[start:end])
00817 self.goal.domain.functions = []
00818 for i in range(0, length):
00819 start = end
00820 end += 4
00821 (length,) = _struct_I.unpack(str[start:end])
00822 start = end
00823 end += length
00824 if python3:
00825 val1 = str[start:end].decode('utf-8')
00826 else:
00827 val1 = str[start:end]
00828 self.goal.domain.functions.append(val1)
00829 start = end
00830 end += 4
00831 (length,) = _struct_I.unpack(str[start:end])
00832 start = end
00833 end += length
00834 if python3:
00835 self.goal.problem.name = str[start:end].decode('utf-8')
00836 else:
00837 self.goal.problem.name = str[start:end]
00838 start = end
00839 end += 4
00840 (length,) = _struct_I.unpack(str[start:end])
00841 start = end
00842 end += length
00843 if python3:
00844 self.goal.problem.domain = str[start:end].decode('utf-8')
00845 else:
00846 self.goal.problem.domain = str[start:end]
00847 start = end
00848 end += 4
00849 (length,) = _struct_I.unpack(str[start:end])
00850 self.goal.problem.objects = []
00851 for i in range(0, length):
00852 val1 = pddl_msgs.msg.PDDLObject()
00853 start = end
00854 end += 4
00855 (length,) = _struct_I.unpack(str[start:end])
00856 start = end
00857 end += length
00858 if python3:
00859 val1.name = str[start:end].decode('utf-8')
00860 else:
00861 val1.name = str[start:end]
00862 start = end
00863 end += 4
00864 (length,) = _struct_I.unpack(str[start:end])
00865 start = end
00866 end += length
00867 if python3:
00868 val1.type = str[start:end].decode('utf-8')
00869 else:
00870 val1.type = str[start:end]
00871 self.goal.problem.objects.append(val1)
00872 start = end
00873 end += 4
00874 (length,) = _struct_I.unpack(str[start:end])
00875 self.goal.problem.initial = []
00876 for i in range(0, length):
00877 start = end
00878 end += 4
00879 (length,) = _struct_I.unpack(str[start:end])
00880 start = end
00881 end += length
00882 if python3:
00883 val1 = str[start:end].decode('utf-8')
00884 else:
00885 val1 = str[start:end]
00886 self.goal.problem.initial.append(val1)
00887 start = end
00888 end += 4
00889 (length,) = _struct_I.unpack(str[start:end])
00890 start = end
00891 end += length
00892 if python3:
00893 self.goal.problem.goal = str[start:end].decode('utf-8')
00894 else:
00895 self.goal.problem.goal = str[start:end]
00896 return self
00897 except struct.error as e:
00898 raise genpy.DeserializationError(e)
00899
00900 _struct_I = genpy.struct_I
00901 _struct_3I = struct.Struct("<3I")
00902 _struct_2I = struct.Struct("<2I")