java.lang.Object | +--java.net.URLConnection | +--java.net.HttpURLConnection
A URLConnection with support for HTTP-specific features. See the spec for details.
Each HttpURLConnection instance is used to make a single request but the underlying network connection to the HTTP server may be transparently shared by other instances. Calling the close() methods on the InputStream or OutputStream of an HttpURLConnection after a request may free network resources associated with this instance but has no effect on any shared persistent connection. Calling the disconnect() method may close the underlying socket if a persistent connection is otherwise idle at that time.
disconnect()
| Field Summary | |
static int |
HTTP_ACCEPTED
copy-> HTTP_ACCEPTED
|
static int |
HTTP_BAD_GATEWAY
copy-> HTTP_BAD_GATEWAY
|
static int |
HTTP_BAD_METHOD
copy-> HTTP_BAD_METHOD
|
static int |
HTTP_BAD_REQUEST
copy-> HTTP_BAD_REQUEST
|
static int |
HTTP_CLIENT_TIMEOUT
copy-> HTTP_CLIENT_TIMEOUT
|
static int |
HTTP_CONFLICT
copy-> HTTP_CONFLICT
|
static int |
HTTP_CREATED
copy-> HTTP_CREATED
|
static int |
HTTP_ENTITY_TOO_LARGE
copy-> HTTP_ENTITY_TOO_LARGE
|
static int |
HTTP_FORBIDDEN
copy-> HTTP_FORBIDDEN
|
static int |
HTTP_GATEWAY_TIMEOUT
copy-> HTTP_GATEWAY_TIMEOUT
|
static int |
HTTP_GONE
copy-> HTTP_GONE
|
static int |
HTTP_INTERNAL_ERROR
copy-> HTTP_INTERNAL_ERROR
|
static int |
HTTP_LENGTH_REQUIRED
copy-> HTTP_LENGTH_REQUIRED
|
static int |
HTTP_MOVED_PERM
copy-> HTTP_MOVED_PERM
|
static int |
HTTP_MOVED_TEMP
copy-> HTTP_MOVED_TEMP
|
static int |
HTTP_MULT_CHOICE
copy-> HTTP_MULT_CHOICE
|
static int |
HTTP_NO_CONTENT
copy-> HTTP_NO_CONTENT
|
static int |
HTTP_NOT_ACCEPTABLE
copy-> HTTP_NOT_ACCEPTABLE
|
static int |
HTTP_NOT_AUTHORITATIVE
copy-> HTTP_NOT_AUTHORITATIVE
|
static int |
HTTP_NOT_FOUND
copy-> HTTP_NOT_FOUND
|
static int |
HTTP_NOT_IMPLEMENTED
copy-> HTTP_NOT_IMPLEMENTED
|
static int |
HTTP_NOT_MODIFIED
copy-> HTTP_NOT_MODIFIED
|
static int |
HTTP_OK
copy-> HTTP_OK
|
static int |
HTTP_PARTIAL
copy-> HTTP_PARTIAL
|
static int |
HTTP_PAYMENT_REQUIRED
copy-> HTTP_PAYMENT_REQUIRED
|
static int |
HTTP_PRECON_FAILED
copy-> HTTP_PRECON_FAILED
|
static int |
HTTP_PROXY_AUTH
copy-> HTTP_PROXY_AUTH
|
static int |
HTTP_REQ_TOO_LONG
copy-> HTTP_REQ_TOO_LONG
|
static int |
HTTP_RESET
copy-> HTTP_RESET
|
static int |
HTTP_SEE_OTHER
copy-> HTTP_SEE_OTHER
|
static int |
HTTP_SERVER_ERROR
copy-> HTTP_SERVER_ERROR
|
static int |
HTTP_UNAUTHORIZED
copy-> HTTP_UNAUTHORIZED
|
static int |
HTTP_UNAVAILABLE
copy-> HTTP_UNAVAILABLE
|
static int |
HTTP_UNSUPPORTED_TYPE
copy-> HTTP_UNSUPPORTED_TYPE
|
static int |
HTTP_USE_PROXY
copy-> HTTP_USE_PROXY
|
static int |
HTTP_VERSION
copy-> HTTP_VERSION
|
protected boolean |
instanceFollowRedirects
copy-> instanceFollowRedirects
|
protected String |
method
copy-> method
|
protected int |
responseCode
copy-> responseCode
|
protected String |
responseMessage
copy-> responseMessage
|
| Fields inherited from class java.net.URLConnection |
allowUserInteraction, connected, doInput, doOutput, ifModifiedSince, url, useCaches |
| Constructor Summary | |
protected |
HttpURLConnection
copy-> new HttpURLConnection( )copy-> <HttpURLConnection var> = new HttpURLConnection(<URL u>);
|
| Method Summary | |
abstract void |
disconnect()
copy-> .disconnect()copy-> <HttpURLConnection>.disconnect();
|
InputStream |
getErrorStream()
copy-> .getErrorStream()copy-> <InputStream var>=<HttpURLConnection>.getErrorStream();
|
static boolean |
getFollowRedirects()
copy-> HttpURLConnection.getFollowRedirects()copy-> <boolean var>=HttpURLConnection.getFollowRedirects();
|
long |
getHeaderFieldDate(String name,
long Default)
copy-> .getHeaderFieldDate(, )copy-> <long var>=<HttpURLConnection>.getHeaderFieldDate(<String name>, <long Default>);
|
boolean |
getInstanceFollowRedirects()
copy-> .getInstanceFollowRedirects()copy-> <boolean var>=<HttpURLConnection>.getInstanceFollowRedirects();
|
Permission |
getPermission()
copy-> .getPermission()copy-> <Permission var>=<HttpURLConnection>.getPermission();
|
String |
getRequestMethod()
copy-> .getRequestMethod()copy-> <String var>=<HttpURLConnection>.getRequestMethod();
|
int |
getResponseCode()
copy-> .getResponseCode()copy-> <int var>=<HttpURLConnection>.getResponseCode();
|
String |
getResponseMessage()
copy-> .getResponseMessage()copy-> <String var>=<HttpURLConnection>.getResponseMessage();
|
static void |
setFollowRedirects(boolean set)
copy-> HttpURLConnection.setFollowRedirects( )copy-> HttpURLConnection.setFollowRedirects(<boolean set>);
|
void |
setInstanceFollowRedirects(boolean followRedirects)
copy-> .setInstanceFollowRedirects( )copy-> <HttpURLConnection>.setInstanceFollowRedirects(<boolean followRedirects>);
|
void |
setRequestMethod(String method)
copy-> .setRequestMethod( )copy-> <HttpURLConnection>.setRequestMethod(<String method>);
|
abstract boolean |
usingProxy()
copy-> .usingProxy()copy-> <boolean var>=<HttpURLConnection>.usingProxy();
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |