com.eclipsesource.restfuse.internal.poll
Class PollStateImpl

java.lang.Object
  extended by com.eclipsesource.restfuse.internal.poll.PollStateImpl
All Implemented Interfaces:
PollState

public class PollStateImpl
extends java.lang.Object
implements PollState


Constructor Summary
PollStateImpl()
           
 
Method Summary
 void abort()
          Aborts a poll series.
 Response getResponse(int attempt)
          Returns a single response for a specific request attempt with a poll series.
 java.util.List<Response> getResponses()
          Returns all responses that were received during the poll series.
 int getTimes()
          Returns the number of the last request attempt.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PollStateImpl

public PollStateImpl()
Method Detail

abort

public void abort()
Description copied from interface: PollState

Aborts a poll series. After this method was called JUnit will continue with the next test method.

Specified by:
abort in interface PollState

getResponse

public Response getResponse(int attempt)
                     throws java.lang.IllegalArgumentException
Description copied from interface: PollState

Returns a single response for a specific request attempt with a poll series.

Specified by:
getResponse in interface PollState
Throws:
java.lang.IllegalArgumentException

getResponses

public java.util.List<Response> getResponses()
Description copied from interface: PollState

Returns all responses that were received during the poll series.

Specified by:
getResponses in interface PollState

getTimes

public int getTimes()
Description copied from interface: PollState

Returns the number of the last request attempt. It can be used to get the current response when it will be passed to the PollState.getResponse(int) method.

Specified by:
getTimes in interface PollState