Interface EventProducerId

All Known Implementing Classes:
PhaseEventProducerId, SolveEventProducerId

@NullMarked public interface EventProducerId
Identifies the producer of a BestSolutionChangedEvent.
  • Method Details

    • producerId

      String producerId()
      An unique string identifying what produced the event, either of the form "Event" where "Event" is a string describing the event that cause the update (like "Solving started") or "Phase (index)", where "Phase" is a string identifying the type of phase (like "Construction Heuristics") and index is the index of the phase in the SolverConfig.getPhaseConfigList().
      Returns:
      An unique string identifying what produced the event.
    • simpleProducerName

      String simpleProducerName()
      A (non-unique) string describing what produced the event. Events from different phases of the same type (for example, when multiple Construction Heuristics are configured) will return the same value.
      Returns:
      A (non-unique) string describing what produced the event.
    • phaseIndex

      OptionalInt phaseIndex()
      If present, the index of the phase that produced the event in the SolverConfig.getPhaseConfigList(). Is absent when the producer does not correspond to a phase, for instance, an event triggered after ProblemChange were processed.
      Returns:
      The index of the corresponding phase in SolverConfig.getPhaseConfigList(), or OptionalInt.empty() if there is no corresponding phase.
    • unknown

      static EventProducerId unknown()
    • solvingStarted

      static EventProducerId solvingStarted()
    • problemChange

      static EventProducerId problemChange()
    • noChange

      @Deprecated(forRemoval=true, since="1.28.0") static EventProducerId noChange(int phaseIndex)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Deprecated on account of NoChangePhase having no use.
    • constructionHeuristic

      static EventProducerId constructionHeuristic(int phaseIndex)
    • localSearch

      static EventProducerId localSearch(int phaseIndex)
    • exhaustiveSearch

      static EventProducerId exhaustiveSearch(int phaseIndex)
    • partitionedSearch

      static EventProducerId partitionedSearch(int phaseIndex)
    • customPhase

      static EventProducerId customPhase(int phaseIndex)