Package org.jmock

Interface States

  • All Superinterfaces:
    org.hamcrest.SelfDescribing, StatesClause
    All Known Implementing Classes:
    StateMachine

    public interface States
    extends org.hamcrest.SelfDescribing, StatesClause
    A state machine that is used to constrain the order of invocations. An invocation can be constrained to occur when a state is, or is not, active.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void become​(java.lang.String nextState)
      Put the state machine into state nextState.
      States startsAs​(java.lang.String initialState)
      Put the state machine into state initialState.
      • Methods inherited from interface org.hamcrest.SelfDescribing

        describeTo
    • Method Detail

      • startsAs

        States startsAs​(java.lang.String initialState)
        Put the state machine into state initialState.
        Parameters:
        initialState - The initial state of the state machine.
        Returns:
        Itself.
      • become

        void become​(java.lang.String nextState)
        Put the state machine into state nextState.
        Parameters:
        nextState - The next state of the state machine.