Class StateHolder<S,E>

java.lang.Object
org.springframework.statemachine.state.StateHolder<S,E>
Type Parameters:
S - the type of state
E - the type of event

public class StateHolder<S,E> extends Object
Utility class using holder pattern to keep a State reference.
  • Constructor Details

    • StateHolder

      public StateHolder(State<S,E> state)
      Instantiates a new state holder.
      Parameters:
      state - the state
  • Method Details

    • getState

      public State<S,E> getState()
      Gets the state.
      Returns:
      the state
    • setState

      public void setState(State<S,E> state)
      Sets the state.
      Parameters:
      state - the state