|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ObjectSimpleHttpClient.SimpleHTTPResponse
public static class SimpleHttpClient.SimpleHTTPResponse
Constructor Summary | |
---|---|
SimpleHttpClient.SimpleHTTPResponse(URLConnection connection)
|
Method Summary | |
---|---|
void |
dispose()
Disposes this HTTP response and cleans up any resource being held. |
String |
getContentType()
Short cut for getResponseHeader("Content-Type") |
String |
getResponseCharset()
|
String |
getResponseHeader(String headerName)
Returns the value of the requested HTTP response header, or null if not set. |
InputStream |
getResponseStream()
Returns the HTTP response content byte stream, automatically recognizing gzip encoded responses and returning an uncompressing stream if that's the case. |
Methods inherited from class Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SimpleHttpClient.SimpleHTTPResponse(URLConnection connection) throws IOException
IOException
Method Detail |
---|
public void dispose()
HTTPResponse
Multiple invocations of this method shall not raise an exception but return silently.
dispose
in interface HTTPResponse
HTTPResponse.dispose()
public String getContentType()
HTTPResponse
getResponseHeader("Content-Type")
getContentType
in interface HTTPResponse
HTTPResponse.getContentType()
public String getResponseHeader(String headerName)
HTTPResponse
null
if not set.
getResponseHeader
in interface HTTPResponse
public InputStream getResponseStream() throws IOException
HTTPResponse
getResponseStream
in interface HTTPResponse
IOException
- if such happens when obtaining the response stream.HTTPResponse.getResponseStream()
public String getResponseCharset()
getResponseCharset
in interface HTTPResponse
null
otherwise.HTTPResponse.getResponseCharset()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |