Interface Policy
- All Known Implementing Classes:
HttpURLConnectionImpl
public interface Policy
-
Method Summary
Modifier and Type Method Description intgetChunkLength()longgetFixedContentLength()HttpURLConnectiongetHttpConnectionToCache()Returns the HttpURLConnection instance to store in the cache.longgetIfModifiedSince()Returns the If-Modified-Since timestamp, or 0 if none is set.URLgetURL()Returns the current destination URL, possibly a redirect.booleangetUseCaches()Returns true if HTTP response caches should be used.voidsetSelectedProxy(Proxy proxy)Sets the current proxy that this connection is using.booleanusingProxy()Returns true if a non-direct proxy is specified.
-
Method Details
-
getUseCaches
boolean getUseCaches()Returns true if HTTP response caches should be used. -
getHttpConnectionToCache
HttpURLConnection getHttpConnectionToCache()Returns the HttpURLConnection instance to store in the cache. -
getURL
URL getURL()Returns the current destination URL, possibly a redirect. -
getIfModifiedSince
long getIfModifiedSince()Returns the If-Modified-Since timestamp, or 0 if none is set. -
usingProxy
boolean usingProxy()Returns true if a non-direct proxy is specified. -
getChunkLength
int getChunkLength() -
getFixedContentLength
long getFixedContentLength() -
setSelectedProxy
Sets the current proxy that this connection is using.- See Also:
HttpURLConnection.usingProxy()
-