Class OpenPrecondition

java.lang.Object
FAtiMA.Core.plans.OpenPrecondition
All Implemented Interfaces:
Serializable

public class OpenPrecondition extends Object implements Serializable
Represents a plan's Open Precondition. An Open Precondition corresponds to a condition that its not achieved by any effect in the plan and must be satisfied in order to complete the plan
Author:
Joao Dias
See Also:
  • Constructor Details

    • OpenPrecondition

      public OpenPrecondition(Integer step, Integer cond)
      Creates a new OpenPrecondition
      Parameters:
      step - - the ID of the step that needs the precondition to be satisfied
      cond - - the ID of the precondition (in the step) that needs to be satified
  • Method Details

    • getCondition

      public Integer getCondition()
      Gets the precondition that needs to be satisfied
      Returns:
      the ID of the precondition in the step
    • getStep

      public Integer getStep()
      Gets the step that needs the precondition satisfied
      Returns:
      the ID of the Step that needs the precondition satisfied
    • setCondition

      public void setCondition(Integer condition)
      Sets the condition that needs to be satisfied
      Parameters:
      condition - - the new ID of the precondition in the step
    • setStep

      public void setStep(Integer step)
      Sets the Step that needs to have the precondition satisfied
      Parameters:
      step - - the new ID of the Step that needs the precondition satisfied
    • toString

      public String toString()
      Converts the OpenPrecondition to a String
      Overrides:
      toString in class Object
      Returns:
      the converted String