Class FakeHttpLayer.RequestMatcherResponseRule
java.lang.Object
org.robolectric.shadows.httpclient.FakeHttpLayer.RequestMatcherResponseRule
- All Implemented Interfaces:
HttpEntityStub.ResponseRule
- Enclosing class:
- FakeHttpLayer
public static class FakeHttpLayer.RequestMatcherResponseRule
extends Object
implements HttpEntityStub.ResponseRule
-
Constructor Summary
ConstructorDescriptionRequestMatcherResponseRule
(RequestMatcher requestMatcher, IOException ioException) RequestMatcherResponseRule
(RequestMatcher requestMatcher, List<? extends org.apache.http.HttpResponse> responses) RequestMatcherResponseRule
(RequestMatcher requestMatcher, org.apache.http.HttpException httpException) RequestMatcherResponseRule
(RequestMatcher requestMatcher, org.apache.http.HttpResponse responseToGive) -
Method Summary
Modifier and TypeMethodDescriptionorg.apache.http.HttpResponse
boolean
matches
(org.apache.http.HttpRequest request)
-
Constructor Details
-
RequestMatcherResponseRule
public RequestMatcherResponseRule(RequestMatcher requestMatcher, org.apache.http.HttpResponse responseToGive) -
RequestMatcherResponseRule
-
RequestMatcherResponseRule
public RequestMatcherResponseRule(RequestMatcher requestMatcher, org.apache.http.HttpException httpException) -
RequestMatcherResponseRule
public RequestMatcherResponseRule(RequestMatcher requestMatcher, List<? extends org.apache.http.HttpResponse> responses)
-
-
Method Details
-
matches
public boolean matches(org.apache.http.HttpRequest request) - Specified by:
matches
in interfaceHttpEntityStub.ResponseRule
-
getResponse
- Specified by:
getResponse
in interfaceHttpEntityStub.ResponseRule
- Throws:
org.apache.http.HttpException
IOException
-