Class Encoding

java.lang.Object
jobshop.encodings.Encoding
Direct Known Subclasses:
ResourceOrder, Schedule

public abstract class Encoding extends Object
Common class for all encodings. The only requirement for this class is to provide a conversion from the encoding into a Schedule.
  • Field Details

    • instance

      public final Instance instance
      Problem instance of which this is the solution.
  • Constructor Details

    • Encoding

      public Encoding(Instance instance)
      Constructor, that initializes the instance field.
  • Method Details

    • toSchedule

      public abstract Optional<Schedule> toSchedule()
      Attempts to convert this solution into a schedule.
      Returns:
      A empty optional if the solution is not valid. Otherwise the optional will contain a valid schedule of the solution.