Interface ProcessingLifecycle.Phase

All Known Implementing Classes:
ProcessingLifecycle.DefaultPhases
Enclosing interface:
ProcessingLifecycle

public static interface ProcessingLifecycle.Phase
Interface describing a possible phase for the ProcessingLifecycle to perform steps in.

Lifecycle actions are invoked in the order() of their respective phase, where action in phases with the same order may be invoked in parallel.

Since:
5.0.0
Author:
Allard Buijze, Gerard Klijs, Milan Savić, Mitchell Herrijgers, Sara Pellegrini, Steven van Beelen
  • Method Summary

    Modifier and Type
    Method
    Description
    default boolean
    Checks if the order() of this Phase is larger than the order of the other.
    default boolean
    Checks if the order() of this Phase is smaller than the order of the other.
    int
    The order of this phase compared to other phases.
  • Method Details

    • order

      int order()
      The order of this phase compared to other phases. Phases with the same order are considered "simultaneous" and may have their handlers invoked in parallel.
      Returns:
      The int describing the relative order of this phase.
    • isBefore

      default boolean isBefore(@Nonnull ProcessingLifecycle.Phase other)
      Checks if the order() of this Phase is smaller than the order of the other. Returns true if this is the case and false otherwise.
      Parameters:
      other - The ProcessingLifecycle.Phase to validate if its order is larger than the order of this Phase.
      Returns:
      true if the order() of this Phase is smaller than the order of the other Phase.
    • isAfter

      default boolean isAfter(@Nonnull ProcessingLifecycle.Phase other)
      Checks if the order() of this Phase is larger than the order of the other. Returns true if this is the case and false otherwise.
      Parameters:
      other - The ProcessingLifecycle.Phase to validate if its order is smaller than the order of this Phase.
      Returns:
      true if the order() of this Phase is larger than the order of the other Phase.