Class HttpResponseStub
- java.lang.Object
-
- org.robolectric.shadows.httpclient.HttpResponseStub
-
- All Implemented Interfaces:
org.apache.http.HttpMessage
,org.apache.http.HttpResponse
- Direct Known Subclasses:
TestHttpResponse
public class HttpResponseStub extends Object implements org.apache.http.HttpResponse
-
-
Constructor Summary
Constructors Constructor Description HttpResponseStub()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addHeader(String s, String s1)
void
addHeader(org.apache.http.Header header)
boolean
containsHeader(String s)
org.apache.http.Header[]
getAllHeaders()
org.apache.http.HttpEntity
getEntity()
org.apache.http.Header
getFirstHeader(String s)
org.apache.http.Header[]
getHeaders(String s)
org.apache.http.Header
getLastHeader(String s)
Locale
getLocale()
HttpParams
getParams()
org.apache.http.ProtocolVersion
getProtocolVersion()
org.apache.http.StatusLine
getStatusLine()
org.apache.http.HeaderIterator
headerIterator()
org.apache.http.HeaderIterator
headerIterator(String s)
void
removeHeader(org.apache.http.Header header)
void
removeHeaders(String s)
void
setEntity(org.apache.http.HttpEntity httpEntity)
void
setHeader(String s, String s1)
void
setHeader(org.apache.http.Header header)
void
setHeaders(org.apache.http.Header[] headers)
void
setLocale(Locale locale)
void
setParams(HttpParams httpParams)
void
setReasonPhrase(String s)
void
setStatusCode(int i)
void
setStatusLine(org.apache.http.ProtocolVersion protocolVersion, int i)
void
setStatusLine(org.apache.http.ProtocolVersion protocolVersion, int i, String s)
void
setStatusLine(org.apache.http.StatusLine statusLine)
-
-
-
Method Detail
-
getStatusLine
public org.apache.http.StatusLine getStatusLine()
- Specified by:
getStatusLine
in interfaceorg.apache.http.HttpResponse
-
setStatusLine
public void setStatusLine(org.apache.http.StatusLine statusLine)
- Specified by:
setStatusLine
in interfaceorg.apache.http.HttpResponse
-
setStatusLine
public void setStatusLine(org.apache.http.ProtocolVersion protocolVersion, int i)
- Specified by:
setStatusLine
in interfaceorg.apache.http.HttpResponse
-
setStatusLine
public void setStatusLine(org.apache.http.ProtocolVersion protocolVersion, int i, String s)
- Specified by:
setStatusLine
in interfaceorg.apache.http.HttpResponse
-
setStatusCode
public void setStatusCode(int i) throws IllegalStateException
- Specified by:
setStatusCode
in interfaceorg.apache.http.HttpResponse
- Throws:
IllegalStateException
-
setReasonPhrase
public void setReasonPhrase(String s) throws IllegalStateException
- Specified by:
setReasonPhrase
in interfaceorg.apache.http.HttpResponse
- Throws:
IllegalStateException
-
getEntity
public org.apache.http.HttpEntity getEntity()
- Specified by:
getEntity
in interfaceorg.apache.http.HttpResponse
-
setEntity
public void setEntity(org.apache.http.HttpEntity httpEntity)
- Specified by:
setEntity
in interfaceorg.apache.http.HttpResponse
-
getLocale
public Locale getLocale()
- Specified by:
getLocale
in interfaceorg.apache.http.HttpResponse
-
setLocale
public void setLocale(Locale locale)
- Specified by:
setLocale
in interfaceorg.apache.http.HttpResponse
-
getProtocolVersion
public org.apache.http.ProtocolVersion getProtocolVersion()
- Specified by:
getProtocolVersion
in interfaceorg.apache.http.HttpMessage
-
containsHeader
public boolean containsHeader(String s)
- Specified by:
containsHeader
in interfaceorg.apache.http.HttpMessage
-
getHeaders
public org.apache.http.Header[] getHeaders(String s)
- Specified by:
getHeaders
in interfaceorg.apache.http.HttpMessage
-
getFirstHeader
public org.apache.http.Header getFirstHeader(String s)
- Specified by:
getFirstHeader
in interfaceorg.apache.http.HttpMessage
-
getLastHeader
public org.apache.http.Header getLastHeader(String s)
- Specified by:
getLastHeader
in interfaceorg.apache.http.HttpMessage
-
getAllHeaders
public org.apache.http.Header[] getAllHeaders()
- Specified by:
getAllHeaders
in interfaceorg.apache.http.HttpMessage
-
addHeader
public void addHeader(org.apache.http.Header header)
- Specified by:
addHeader
in interfaceorg.apache.http.HttpMessage
-
addHeader
public void addHeader(String s, String s1)
- Specified by:
addHeader
in interfaceorg.apache.http.HttpMessage
-
setHeader
public void setHeader(org.apache.http.Header header)
- Specified by:
setHeader
in interfaceorg.apache.http.HttpMessage
-
setHeader
public void setHeader(String s, String s1)
- Specified by:
setHeader
in interfaceorg.apache.http.HttpMessage
-
setHeaders
public void setHeaders(org.apache.http.Header[] headers)
- Specified by:
setHeaders
in interfaceorg.apache.http.HttpMessage
-
removeHeader
public void removeHeader(org.apache.http.Header header)
- Specified by:
removeHeader
in interfaceorg.apache.http.HttpMessage
-
removeHeaders
public void removeHeaders(String s)
- Specified by:
removeHeaders
in interfaceorg.apache.http.HttpMessage
-
headerIterator
public org.apache.http.HeaderIterator headerIterator()
- Specified by:
headerIterator
in interfaceorg.apache.http.HttpMessage
-
headerIterator
public org.apache.http.HeaderIterator headerIterator(String s)
- Specified by:
headerIterator
in interfaceorg.apache.http.HttpMessage
-
getParams
public HttpParams getParams()
- Specified by:
getParams
in interfaceorg.apache.http.HttpMessage
-
setParams
public void setParams(HttpParams httpParams)
- Specified by:
setParams
in interfaceorg.apache.http.HttpMessage
-
-