public abstract class Dispatcher extends Object
| Constructor and Description |
|---|
Dispatcher() |
| Modifier and Type | Method and Description |
|---|---|
abstract MockResponse |
dispatch(RecordedRequest request)
Returns a response to satisfy
request. |
SocketPolicy |
peekSocketPolicy()
Returns the socket policy of the next request.
|
public abstract MockResponse dispatch(RecordedRequest request) throws InterruptedException
request. This method may block (for
instance, to wait on a CountdownLatch).InterruptedExceptionpublic SocketPolicy peekSocketPolicy()
SocketPolicy.KEEP_OPEN. Mischievous implementations can
return other values to test HTTP edge cases.Copyright © 2014. All Rights Reserved.