Interface StateProvider<Context,S extends State<Context>>

All Known Implementing Classes:
Application, StateMachine

@ProviderOf(State.class) public interface StateProvider<Context,S extends State<Context>>
Provides information about the state in a certain context.
  • Method Summary

    Modifier and Type
    Method
    Description
     
    default boolean
    isAnyState(S... states)
    Checks whether the state machine is in any of the given states.
    default boolean
    isState(S state)
    Checks whether the state machine is in a given state.
  • Method Details

    • getState

      S getState()
      Returns:
      The current state of the state machine.
    • isState

      default boolean isState(S state)
      Checks whether the state machine is in a given state.
    • isAnyState

      default boolean isAnyState(S... states)
      Checks whether the state machine is in any of the given states.