diff --git a/1.x/javadoc/allclasses-frame.html b/1.x/javadoc/allclasses-frame.html index 3e0819b18..4dd63e89c 100644 --- a/1.x/javadoc/allclasses-frame.html +++ b/1.x/javadoc/allclasses-frame.html @@ -2,9 +2,9 @@
- + -public final class Address +extends Object+
no proxy is explicitly requested), this also includes
+ that proxy information. For secure connections the address also includes the
+ SSL socket factory and hostname verifier.
+
+ HTTP requests that share the same Address may also share the same
+ Connection.
| Constructor and Description | +
|---|
Address(String uriHost,
+ int uriPort,
+ SSLSocketFactory sslSocketFactory,
+ HostnameVerifier hostnameVerifier,
+ OkAuthenticator authenticator,
+ Proxy proxy,
+ List<Protocol> protocols) |
+
| Modifier and Type | +Method and Description | +
|---|---|
boolean |
+equals(Object other) |
+
OkAuthenticator |
+getAuthenticator()
+Returns the client's authenticator.
+ |
+
HostnameVerifier |
+getHostnameVerifier()
+Returns the hostname verifier, or null if this is not an HTTPS
+ address.
+ |
+
List<Protocol> |
+getProtocols()
+Returns the protocols the client supports.
+ |
+
Proxy |
+getProxy()
+Returns this address's explicitly-specified HTTP proxy, or null to
+ delegate to the HTTP client's proxy selector.
+ |
+
SSLSocketFactory |
+getSslSocketFactory()
+Returns the SSL socket factory, or null if this is not an HTTPS
+ address.
+ |
+
String |
+getUriHost()
+Returns the hostname of the origin server.
+ |
+
int |
+getUriPort()
+Returns the port of the origin server; typically 80 or 443.
+ |
+
int |
+hashCode() |
+
public Address(String uriHost, + int uriPort, + SSLSocketFactory sslSocketFactory, + HostnameVerifier hostnameVerifier, + OkAuthenticator authenticator, + Proxy proxy, + List<Protocol> protocols) + throws UnknownHostException+
UnknownHostExceptionpublic String getUriHost()+
public int getUriPort()+
getPort() accessors, this method never returns -1.public SSLSocketFactory getSslSocketFactory()+
public HostnameVerifier getHostnameVerifier()+
public OkAuthenticator getAuthenticator()+
public List<Protocol> getProtocols()+
Protocol.HTTP_11.public Proxy getProxy()+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/Cache.html b/1.x/javadoc/com/squareup/okhttp/Cache.html new file mode 100644 index 000000000..2d04aafb6 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/Cache.html @@ -0,0 +1,660 @@ + + + + + + +public class Cache +extends ResponseCache +implements OkResponseCache+
Request Count: the number
+ of HTTP requests issued since this cache was created.
+ Network Count: the
+ number of those requests that required network use.
+ Hit Count: the number of
+ those requests whose responses were served by the cache.
+ GET. The server will then send either the updated response if it has
+ changed, or a short 'not modified' response if the client's copy is still
+ valid. Such responses increment both the network count and hit count.
+
+ The best way to improve the cache hit rate is by configuring the web + server to return cacheable responses. Although this client honors all HTTP/1.1 (RFC 2068) cache + headers, it doesn't cache partial responses. + +
no-cache directive: connection.addRequestProperty("Cache-Control", "no-cache");
+
+ If it is only necessary to force a cached response to be validated by the
+ server, use the more efficient max-age=0 instead: connection.addRequestProperty("Cache-Control", "max-age=0");
+
+
+ only-if-cached directive: try {
+ connection.addRequestProperty("Cache-Control", "only-if-cached");
+ InputStream cached = connection.getInputStream();
+ // the resource was cached! show it
+ } catch (FileNotFoundException e) {
+ // the resource was not cached
+ }
+
+ This technique works even better in situations where a stale response is
+ better than no response. To permit stale cached responses, use the max-stale directive with the maximum staleness in seconds: int maxStale = 60 * 60 * 24 * 28; // tolerate 4-weeks stale
+ connection.addRequestProperty("Cache-Control", "max-stale=" + maxStale);
+ | Constructor and Description | +
|---|
Cache(File directory,
+ long maxSize) |
+
| Modifier and Type | +Method and Description | +
|---|---|
void |
+close() |
+
void |
+delete()
+Closes the cache and deletes all of its stored values.
+ |
+
void |
+flush() |
+
com.squareup.okhttp.internal.http.Response |
+get(com.squareup.okhttp.internal.http.Request request) |
+
CacheResponse |
+get(URI uri,
+ String s,
+ Map<String,List<String>> stringListMap) |
+
File |
+getDirectory() |
+
int |
+getHitCount() |
+
long |
+getMaxSize() |
+
int |
+getNetworkCount() |
+
int |
+getRequestCount() |
+
long |
+getSize() |
+
int |
+getWriteAbortCount() |
+
int |
+getWriteSuccessCount() |
+
boolean |
+isClosed() |
+
boolean |
+maybeRemove(com.squareup.okhttp.internal.http.Request request)
+Remove any cache entries for the supplied
+uri. |
+
CacheRequest |
+put(com.squareup.okhttp.internal.http.Response response) |
+
CacheRequest |
+put(URI uri,
+ URLConnection urlConnection) |
+
void |
+trackConditionalCacheHit()
+Track an conditional GET that was satisfied by this cache.
+ |
+
void |
+trackResponse(ResponseSource source)
+Track an HTTP response being satisfied by
+source. |
+
void |
+update(com.squareup.okhttp.internal.http.Response cached,
+ com.squareup.okhttp.internal.http.Response network)
+Handles a conditional request hit by updating the stored cache response
+ with the headers from
+network. |
+
getDefault, setDefaultpublic Cache(File directory, + long maxSize) + throws IOException+
IOExceptionpublic CacheResponse get(URI uri, + String s, + Map<String,List<String>> stringListMap) + throws IOException+
get in class ResponseCacheIOExceptionpublic CacheRequest put(URI uri, + URLConnection urlConnection) + throws IOException+
put in class ResponseCacheIOExceptionpublic com.squareup.okhttp.internal.http.Response get(com.squareup.okhttp.internal.http.Request request)+
get in interface OkResponseCachepublic CacheRequest put(com.squareup.okhttp.internal.http.Response response) + throws IOException+
put in interface OkResponseCacheIOExceptionpublic boolean maybeRemove(com.squareup.okhttp.internal.http.Request request)+
OkResponseCacheuri. Returns true if the
+ supplied requestMethod potentially invalidates an entry in the
+ cache.maybeRemove in interface OkResponseCachepublic void update(com.squareup.okhttp.internal.http.Response cached, + com.squareup.okhttp.internal.http.Response network)+
OkResponseCachenetwork. The cached response body is not
+ updated. If the stored response has changed since cached was
+ returned, this does nothing.update in interface OkResponseCachepublic void delete() + throws IOException+
IOExceptionpublic int getWriteAbortCount()+
public int getWriteSuccessCount()+
public long getSize()+
public long getMaxSize()+
public void flush() + throws IOException+
IOExceptionpublic void close() + throws IOException+
IOExceptionpublic File getDirectory()+
public boolean isClosed()+
public void trackResponse(ResponseSource source)+
OkResponseCachesource.trackResponse in interface OkResponseCachepublic void trackConditionalCacheHit()+
OkResponseCachetrackConditionalCacheHit in interface OkResponseCachepublic int getNetworkCount()+
public int getHitCount()+
public int getRequestCount()+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/CacheControl.html b/1.x/javadoc/com/squareup/okhttp/CacheControl.html new file mode 100644 index 000000000..a3f2d4b8b --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/CacheControl.html @@ -0,0 +1,377 @@ + + + + + + +public final class CacheControl +extends Object+
See RFC + 2616, 14.9.
| Modifier and Type | +Method and Description | +
|---|---|
boolean |
+isPublic() |
+
int |
+maxAgeSeconds()
+The duration past the response's served date that it can be served without
+ validation.
+ |
+
int |
+maxStaleSeconds() |
+
int |
+minFreshSeconds() |
+
boolean |
+mustRevalidate() |
+
boolean |
+noCache()
+In a response, this field's name "no-cache" is misleading.
+ |
+
boolean |
+noStore()
+If true, this response should not be cached.
+ |
+
boolean |
+onlyIfCached()
+This field's name "only-if-cached" is misleading.
+ |
+
static CacheControl |
+parse(com.squareup.okhttp.internal.http.Headers headers)
+Returns the cache directives of
+headers. |
+
int |
+sMaxAgeSeconds()
+The "s-maxage" directive is the max age for shared caches.
+ |
+
public boolean noCache()+
In a request, it means do not use a cache to satisfy the request.
public boolean noStore()+
public int maxAgeSeconds()+
public int sMaxAgeSeconds()+
public boolean isPublic()+
public boolean mustRevalidate()+
public int maxStaleSeconds()+
public int minFreshSeconds()+
public boolean onlyIfCached()+
public static CacheControl parse(com.squareup.okhttp.internal.http.Headers headers)+
headers. This honors both
+ Cache-Control and Pragma headers if they are present.Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/Connection.html b/1.x/javadoc/com/squareup/okhttp/Connection.html new file mode 100644 index 000000000..53fe2252f --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/Connection.html @@ -0,0 +1,675 @@ + + + + + + +public final class Connection +extends Object +implements Closeable+
Typically instances of this class are created, connected and exercised
+ automatically by the HTTP client. Applications may use this class to monitor
+ HTTP connections as members of a connection pool.
+
+
Do not confuse this class with the misnamed HttpURLConnection,
+ which isn't so much a connection as a single request/response exchange.
+
+
| Constructor and Description | +
|---|
Connection(ConnectionPool pool,
+ Route route) |
+
| Modifier and Type | +Method and Description | +
|---|---|
boolean |
+clearOwner()
+Attempts to clears the owner of this connection.
+ |
+
void |
+close() |
+
void |
+closeIfOwnedBy(Object owner)
+Closes this connection if it is currently owned by
+owner. |
+
void |
+connect(int connectTimeout,
+ int readTimeout,
+ TunnelRequest tunnelRequest) |
+
Handshake |
+getHandshake() |
+
int |
+getHttpMinorVersion()
+Returns the minor HTTP version that should be used for future requests on
+ this connection.
+ |
+
long |
+getIdleStartTimeNs()
+Returns the time in ns when this connection became idle.
+ |
+
Object |
+getOwner() |
+
Route |
+getRoute()
+Returns the route used by this connection.
+ |
+
Socket |
+getSocket()
+Returns the socket that this connection uses, or null if the connection
+ is not currently connected.
+ |
+
void |
+incrementRecycleCount() |
+
boolean |
+isAlive()
+Returns true if this connection is alive.
+ |
+
boolean |
+isConnected()
+Returns true if
+connect(int, int, com.squareup.okhttp.TunnelRequest) has been attempted on this connection. |
+
boolean |
+isExpired(long keepAliveDurationNs)
+Returns true if this connection has been idle for longer than
+
+keepAliveDurationNs. |
+
boolean |
+isIdle()
+Returns true if this connection is idle.
+ |
+
boolean |
+isReadable()
+Returns true if we are confident that we can read data from this
+ connection.
+ |
+
boolean |
+isSpdy()
+Returns true if this is a SPDY connection.
+ |
+
Object |
+newTransport(com.squareup.okhttp.internal.http.HttpEngine httpEngine)
+Returns the transport appropriate for this connection.
+ |
+
int |
+recycleCount()
+Returns the number of times this connection has been returned to the
+ connection pool.
+ |
+
boolean |
+requiresTunnel()
+Returns true if the HTTP connection needs to tunnel one protocol over
+ another, such as when using HTTPS through an HTTP proxy.
+ |
+
void |
+resetIdleStartTime() |
+
void |
+setHttpMinorVersion(int httpMinorVersion) |
+
void |
+setOwner(Object owner) |
+
void |
+updateReadTimeout(int newTimeout) |
+
public Connection(ConnectionPool pool, + Route route)+
public Object getOwner()+
public void setOwner(Object owner)+
public boolean clearOwner()+
closeIfOwnedBy(java.lang.Object).public void closeIfOwnedBy(Object owner) + throws IOException+
owner. This also
+ strips the ownership of the connection so it cannot be pooled or reused.IOExceptionpublic void connect(int connectTimeout, + int readTimeout, + TunnelRequest tunnelRequest) + throws IOException+
IOExceptionpublic boolean isConnected()+
connect(int, int, com.squareup.okhttp.TunnelRequest) has been attempted on this connection.public void close() + throws IOException+
close in interface Closeableclose in interface AutoCloseableIOExceptionpublic Route getRoute()+
public Socket getSocket()+
public boolean isAlive()+
public boolean isReadable()+ +
public void resetIdleStartTime()+
public boolean isIdle()+
public boolean isExpired(long keepAliveDurationNs)+
keepAliveDurationNs.public long getIdleStartTimeNs()+
public Handshake getHandshake()+
public Object newTransport(com.squareup.okhttp.internal.http.HttpEngine httpEngine) + throws IOException+
IOExceptionpublic boolean isSpdy()+
public int getHttpMinorVersion()+
public void setHttpMinorVersion(int httpMinorVersion)+
public boolean requiresTunnel()+
public void updateReadTimeout(int newTimeout) + throws IOException+
IOExceptionpublic void incrementRecycleCount()+
public int recycleCount()+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/ConnectionPool.html b/1.x/javadoc/com/squareup/okhttp/ConnectionPool.html new file mode 100644 index 000000000..8b40809db --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/ConnectionPool.html @@ -0,0 +1,395 @@ + + + + + + +public class ConnectionPool +extends Object+
Address may share a
+ Connection. This class implements the policy of
+ which connections to keep open for future use.
+
+ The system-wide default uses system properties for
+ tuning parameters:
+
http.keepAlive true if HTTP and SPDY connections should be
+ pooled at all. Default is true.
+ http.maxConnections maximum number of idle connections to
+ each to keep in the pool. Default is 5.
+ http.keepAliveDuration Time in milliseconds to keep the
+ connection alive in the pool before closing it. Default is 5 minutes.
+ This property isn't used by HttpURLConnection.
+ The default instance doesn't adjust its configuration as system + properties are changed. This assumes that the applications that set these + parameters do so before making HTTP connections, and that this class is + initialized lazily.
| Constructor and Description | +
|---|
ConnectionPool(int maxIdleConnections,
+ long keepAliveDurationMs) |
+
| Modifier and Type | +Method and Description | +
|---|---|
void |
+evictAll()
+Close and remove all connections in the pool.
+ |
+
Connection |
+get(Address address)
+Returns a recycled connection to
+address, or null if no such connection exists. |
+
int |
+getConnectionCount()
+Returns total number of connections in the pool.
+ |
+
static ConnectionPool |
+getDefault() |
+
int |
+getHttpConnectionCount()
+Returns total number of http connections in the pool.
+ |
+
int |
+getSpdyConnectionCount()
+Returns total number of spdy connections in the pool.
+ |
+
void |
+recycle(Connection connection)
+Gives
+connection to the pool. |
+
void |
+share(Connection connection)
+Shares the SPDY connection with the pool.
+ |
+
public ConnectionPool(int maxIdleConnections, + long keepAliveDurationMs)+
public static ConnectionPool getDefault()+
public int getConnectionCount()+
public int getSpdyConnectionCount()+
public int getHttpConnectionCount()+
public Connection get(Address address)+
address, or null if no such connection exists.public void recycle(Connection connection)+
connection to the pool. The pool may store the connection,
+ or close it, as its policy describes.
+
+ It is an error to use connection after calling this method.
public void share(Connection connection)+
connection.public void evictAll()+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/Handshake.html b/1.x/javadoc/com/squareup/okhttp/Handshake.html new file mode 100644 index 000000000..5439d5b1a --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/Handshake.html @@ -0,0 +1,357 @@ + + + + + + +public final class Handshake +extends Object+
This value object describes a completed handshake. Use SSLSocketFactory to set policy for new handshakes.
| Modifier and Type | +Method and Description | +
|---|---|
String |
+cipherSuite()
+Returns a cipher suite name like "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA".
+ |
+
boolean |
+equals(Object other) |
+
static Handshake |
+get(SSLSession session) |
+
static Handshake |
+get(String cipherSuite,
+ List<Certificate> peerCertificates,
+ List<Certificate> localCertificates) |
+
int |
+hashCode() |
+
List<Certificate> |
+localCertificates()
+Returns a possibly-empty list of certificates that identify this peer.
+ |
+
Principal |
+localPrincipal()
+Returns the local principle, or null if this peer is anonymous.
+ |
+
List<Certificate> |
+peerCertificates()
+Returns a possibly-empty list of certificates that identify the remote peer.
+ |
+
Principal |
+peerPrincipal()
+Returns the remote peer's principle, or null if that peer is anonymous.
+ |
+
public static Handshake get(SSLSession session)+
public static Handshake get(String cipherSuite, + List<Certificate> peerCertificates, + List<Certificate> localCertificates)+
public String cipherSuite()+
public List<Certificate> peerCertificates()+
public Principal peerPrincipal()+
public List<Certificate> localCertificates()+
public Principal localPrincipal()+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/HttpResponseCache.html b/1.x/javadoc/com/squareup/okhttp/HttpResponseCache.html new file mode 100644 index 000000000..beba2022a --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/HttpResponseCache.html @@ -0,0 +1,268 @@ + + + + + + +Cache.@Deprecated +public final class HttpResponseCache +extends Cache+
| Constructor and Description | +
|---|
HttpResponseCache(File directory,
+ long maxSize)
+Deprecated.
+ |
+
close, delete, flush, get, get, getDirectory, getHitCount, getMaxSize, getNetworkCount, getRequestCount, getSize, getWriteAbortCount, getWriteSuccessCount, isClosed, maybeRemove, put, put, trackConditionalCacheHit, trackResponse, updategetDefault, setDefaultpublic HttpResponseCache(File directory, + long maxSize) + throws IOException+
IOExceptionCopyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/MediaType.html b/1.x/javadoc/com/squareup/okhttp/MediaType.html new file mode 100644 index 000000000..e08b76c77 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/MediaType.html @@ -0,0 +1,357 @@ + + + + + + +| Modifier and Type | +Method and Description | +
|---|---|
Charset |
+charset()
+Returns the charset of this media type, or null if this media type doesn't
+ specify a charset.
+ |
+
Charset |
+charset(Charset defaultValue)
+Returns the charset of this media type, or
+defaultValue if this
+ media type doesn't specify a charset. |
+
boolean |
+equals(Object o) |
+
int |
+hashCode() |
+
static MediaType |
+parse(String string)
+Returns a media type for
+string, or null if string is not a
+ well-formed media type. |
+
String |
+subtype()
+Returns a specific media subtype, such as "plain" or "png", "mpeg",
+ "mp4" or "xml".
+ |
+
String |
+toString()
+Returns the encoded media type, like "text/plain; charset=utf-8",
+ appropriate for use in a Content-Type header.
+ |
+
String |
+type()
+Returns the high-level media type, such as "text", "image", "audio",
+ "video", or "application".
+ |
+
public static MediaType parse(String string)+
string, or null if string is not a
+ well-formed media type.public String type()+
public String subtype()+
public Charset charset()+
public Charset charset(Charset defaultValue)+
defaultValue if this
+ media type doesn't specify a charset.public String toString()+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/OkAuthenticator.Challenge.html b/1.x/javadoc/com/squareup/okhttp/OkAuthenticator.Challenge.html new file mode 100644 index 000000000..e7f244601 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/OkAuthenticator.Challenge.html @@ -0,0 +1,333 @@ + + + + + + +public static final class OkAuthenticator.Challenge +extends Object+
| Constructor and Description | +
|---|
OkAuthenticator.Challenge(String scheme,
+ String realm) |
+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/OkAuthenticator.Credential.html b/1.x/javadoc/com/squareup/okhttp/OkAuthenticator.Credential.html new file mode 100644 index 000000000..171354f00 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/OkAuthenticator.Credential.html @@ -0,0 +1,296 @@ + + + + + + +public static final class OkAuthenticator.Credential +extends Object+
| Modifier and Type | +Method and Description | +
|---|---|
static OkAuthenticator.Credential |
+basic(String userName,
+ String password)
+Returns an auth credential for the Basic scheme.
+ |
+
boolean |
+equals(Object o) |
+
String |
+getHeaderValue() |
+
int |
+hashCode() |
+
String |
+toString() |
+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/OkAuthenticator.html b/1.x/javadoc/com/squareup/okhttp/OkAuthenticator.html new file mode 100644 index 000000000..8b1242890 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/OkAuthenticator.html @@ -0,0 +1,290 @@ + + + + + + +Authenticator in OkHttp 2.0.@Deprecated +public interface OkAuthenticator+
| Modifier and Type | +Interface and Description | +
|---|---|
static class |
+OkAuthenticator.Challenge
+Deprecated.
+An RFC 2617 challenge.
+ |
+
static class |
+OkAuthenticator.Credential
+Deprecated.
+An RFC 2617 credential.
+ |
+
| Modifier and Type | +Method and Description | +
|---|---|
OkAuthenticator.Credential |
+authenticate(Proxy proxy,
+ URL url,
+ List<OkAuthenticator.Challenge> challenges)
+Deprecated.
+Returns a credential that satisfies the authentication challenge made by
+
+url. |
+
OkAuthenticator.Credential |
+authenticateProxy(Proxy proxy,
+ URL url,
+ List<OkAuthenticator.Challenge> challenges)
+Deprecated.
+Returns a credential that satisfies the authentication challenge made by
+
+proxy. |
+
OkAuthenticator.Credential authenticate(Proxy proxy, + URL url, + List<OkAuthenticator.Challenge> challenges) + throws IOException+
url. Returns null if the challenge cannot be satisfied. This method
+ is called in response to an HTTP 401 unauthorized status code sent by the
+ origin server.challenges - parsed "WWW-Authenticate" challenge headers from the HTTP
+ response.IOExceptionOkAuthenticator.Credential authenticateProxy(Proxy proxy, + URL url, + List<OkAuthenticator.Challenge> challenges) + throws IOException+
proxy. Returns null if the challenge cannot be satisfied. This
+ method is called in response to an HTTP 401 unauthorized status code sent
+ by the proxy server.challenges - parsed "Proxy-Authenticate" challenge headers from the
+ HTTP response.IOExceptionCopyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/OkHttpClient.html b/1.x/javadoc/com/squareup/okhttp/OkHttpClient.html new file mode 100644 index 000000000..4eda1157c --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/OkHttpClient.html @@ -0,0 +1,925 @@ + + + + + + +public final class OkHttpClient +extends Object +implements URLStreamHandlerFactory, Cloneable+
clone() to make a shallow copy of the OkHttpClient that can be
+ safely modified with further configuration changes.| Constructor and Description | +
|---|
OkHttpClient() |
+
| Modifier and Type | +Method and Description | +
|---|---|
OkHttpClient |
+clone()
+Returns a shallow copy of this OkHttpClient.
+ |
+
URLStreamHandler |
+createURLStreamHandler(String protocol)
+Deprecated.
+
+moved to
+OkUrlFactory.createURLStreamHandler. |
+
OkAuthenticator |
+getAuthenticator() |
+
Cache |
+getCache() |
+
ConnectionPool |
+getConnectionPool() |
+
int |
+getConnectTimeout()
+Default connect timeout (in milliseconds).
+ |
+
CookieHandler |
+getCookieHandler() |
+
boolean |
+getFollowProtocolRedirects()
+Deprecated.
+
+moved to
+getFollowSslRedirects(). |
+
boolean |
+getFollowSslRedirects() |
+
HostnameVerifier |
+getHostnameVerifier() |
+
OkResponseCache |
+getOkResponseCache()
+Deprecated.
+
+replaced by
+getCache() which doesn't support custom
+ cache implementations. |
+
List<Protocol> |
+getProtocols() |
+
Proxy |
+getProxy() |
+
ProxySelector |
+getProxySelector() |
+
int |
+getReadTimeout()
+Default read timeout (in milliseconds).
+ |
+
ResponseCache |
+getResponseCache()
+Deprecated.
+
+replaced by
+getCache() which doesn't support custom
+ cache implementations. |
+
RouteDatabase |
+getRoutesDatabase()
+Deprecated.
+
+removed from the public API in OkHttp 2.0.
+ |
+
SSLSocketFactory |
+getSslSocketFactory() |
+
List<String> |
+getTransports()
+Deprecated.
+
+OkHttp 1.5 enforces an enumeration of
+protocols that can be selected. Please switch to getProtocols(). |
+
HttpURLConnection |
+open(URL url)
+Deprecated.
+
+moved to
+OkUrlFactory.open. |
+
OkHttpClient |
+setAuthenticator(OkAuthenticator authenticator)
+Sets the authenticator used to respond to challenges from the remote web
+ server or proxy server.
+ |
+
OkHttpClient |
+setCache(Cache cache) |
+
OkHttpClient |
+setConnectionPool(ConnectionPool connectionPool)
+Sets the connection pool used to recycle HTTP and HTTPS connections.
+ |
+
void |
+setConnectTimeout(long timeout,
+ TimeUnit unit)
+Sets the default connect timeout for new connections.
+ |
+
OkHttpClient |
+setCookieHandler(CookieHandler cookieHandler)
+Sets the cookie handler to be used to read outgoing cookies and write
+ incoming cookies.
+ |
+
OkHttpClient |
+setFollowProtocolRedirects(boolean followProtocolRedirects)
+Deprecated.
+
+moved to
+setFollowSslRedirects(boolean). |
+
OkHttpClient |
+setFollowSslRedirects(boolean followProtocolRedirects)
+Configure this client to follow redirects from HTTPS to HTTP and from HTTP
+ to HTTPS.
+ |
+
OkHttpClient |
+setHostnameVerifier(HostnameVerifier hostnameVerifier)
+Sets the verifier used to confirm that response certificates apply to
+ requested hostnames for HTTPS connections.
+ |
+
OkHttpClient |
+setOkResponseCache(OkResponseCache responseCache)
+Deprecated.
+
+replaced by
+setCache(com.squareup.okhttp.Cache) which doesn't support custom
+ cache implementations. |
+
OkHttpClient |
+setProtocols(List<Protocol> protocols)
+Configure the protocols used by this client to communicate with remote
+ servers.
+ |
+
OkHttpClient |
+setProxy(Proxy proxy)
+Sets the HTTP proxy that will be used by connections created by this
+ client.
+ |
+
OkHttpClient |
+setProxySelector(ProxySelector proxySelector)
+Sets the proxy selection policy to be used if no
+proxy
+ is specified explicitly. |
+
void |
+setReadTimeout(long timeout,
+ TimeUnit unit)
+Sets the default read timeout for new connections.
+ |
+
OkHttpClient |
+setResponseCache(ResponseCache responseCache)
+Deprecated.
+
+replaced by
+setCache(com.squareup.okhttp.Cache) which doesn't support custom
+ cache implementations. |
+
OkHttpClient |
+setSslSocketFactory(SSLSocketFactory sslSocketFactory)
+Sets the socket factory used to secure HTTPS connections.
+ |
+
OkHttpClient |
+setTransports(List<String> transports)
+Deprecated.
+
+OkHttp 1.5 enforces an enumeration of
+protocols
+ that can be selected. Please switch to setProtocols(java.util.List). |
+
public void setConnectTimeout(long timeout, + TimeUnit unit)+
URLConnection.setConnectTimeout(int)public int getConnectTimeout()+
public void setReadTimeout(long timeout, + TimeUnit unit)+
URLConnection.setReadTimeout(int)public int getReadTimeout()+
public OkHttpClient setProxy(Proxy proxy)+
setProxySelector(java.net.ProxySelector), which is
+ only honored when this proxy is null (which it is by default). To disable
+ proxy use completely, call setProxy(Proxy.NO_PROXY).public Proxy getProxy()+
public OkHttpClient setProxySelector(ProxySelector proxySelector)+
proxy
+ is specified explicitly. The proxy selector may return multiple proxies;
+ in that case they will be tried in sequence until a successful connection
+ is established.
+
+ If unset, the system-wide default
+ proxy selector will be used.
public ProxySelector getProxySelector()+
public OkHttpClient setCookieHandler(CookieHandler cookieHandler)+
If unset, the system-wide default
+ cookie handler will be used.
public CookieHandler getCookieHandler()+
@Deprecated +public OkHttpClient setResponseCache(ResponseCache responseCache)+
setCache(com.squareup.okhttp.Cache) which doesn't support custom
+ cache implementations.@Deprecated +public ResponseCache getResponseCache()+
getCache() which doesn't support custom
+ cache implementations.@Deprecated +public OkHttpClient setOkResponseCache(OkResponseCache responseCache)+
setCache(com.squareup.okhttp.Cache) which doesn't support custom
+ cache implementations.@Deprecated +public OkResponseCache getOkResponseCache()+
getCache() which doesn't support custom
+ cache implementations.public OkHttpClient setCache(Cache cache)+
public Cache getCache()+
public OkHttpClient setSslSocketFactory(SSLSocketFactory sslSocketFactory)+
If unset, a lazily created SSL socket factory will be used.
public SSLSocketFactory getSslSocketFactory()+
public OkHttpClient setHostnameVerifier(HostnameVerifier hostnameVerifier)+
If unset, the
+ system-wide default hostname verifier will be used.
public HostnameVerifier getHostnameVerifier()+
public OkHttpClient setAuthenticator(OkAuthenticator authenticator)+
If unset, the system-wide default
+ authenticator will be used.
public OkAuthenticator getAuthenticator()+
public OkHttpClient setConnectionPool(ConnectionPool connectionPool)+
If unset, the system-wide
+ default connection pool will be used.
public ConnectionPool getConnectionPool()+
@Deprecated +public OkHttpClient setFollowProtocolRedirects(boolean followProtocolRedirects)+
setFollowSslRedirects(boolean).@Deprecated +public boolean getFollowProtocolRedirects()+
getFollowSslRedirects().public OkHttpClient setFollowSslRedirects(boolean followProtocolRedirects)+
If unset, protocol redirects will be followed. This is different than
+ the built-in HttpURLConnection's default.
public boolean getFollowSslRedirects()+
@Deprecated +public RouteDatabase getRoutesDatabase()+
@Deprecated +public OkHttpClient setTransports(List<String> transports)+
protocols
+ that can be selected. Please switch to setProtocols(java.util.List).public OkHttpClient setProtocols(List<Protocol> protocols)+
The following protocols are currently supported: +
This is an evolving set. Future releases may drop + support for transitional protocols (like spdy/3.1), in favor of their + successors (spdy/4 or http/2.0). The http/1.1 transport will never be + dropped. + +
If multiple protocols are specified, NPN will + be used to negotiate a transport. Future releases may use another mechanism + (such as ALPN) + to negotiate a transport.
protocols - the protocols to use, in order of preference. The list
+ must contain "http/1.1". It must not contain null.@Deprecated +public List<String> getTransports()+
protocols that can be selected. Please switch to getProtocols().@Deprecated +public HttpURLConnection open(URL url)+
OkUrlFactory.open.public OkHttpClient clone()+
@Deprecated +public URLStreamHandler createURLStreamHandler(String protocol)+
OkUrlFactory.createURLStreamHandler.URL.setURLStreamHandlerFactory(java.net.URLStreamHandlerFactory).
+
+ This code configures OkHttp to handle all HTTP and HTTPS connections
+ created with URL.openConnection():
OkHttpClient okHttpClient = new OkHttpClient();
+ URL.setURLStreamHandlerFactory(okHttpClient);
+ createURLStreamHandler in interface URLStreamHandlerFactoryCopyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/OkResponseCache.html b/1.x/javadoc/com/squareup/okhttp/OkResponseCache.html new file mode 100644 index 000000000..46d098443 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/OkResponseCache.html @@ -0,0 +1,330 @@ + + + + + + +@Deprecated +public interface OkResponseCache+
ResponseCache, this
+ interface supports conditional caching and statistics.
+
+ | Modifier and Type | +Method and Description | +
|---|---|
com.squareup.okhttp.internal.http.Response |
+get(com.squareup.okhttp.internal.http.Request request)
+Deprecated.
+ |
+
boolean |
+maybeRemove(com.squareup.okhttp.internal.http.Request request)
+Deprecated.
+Remove any cache entries for the supplied
+uri. |
+
CacheRequest |
+put(com.squareup.okhttp.internal.http.Response response)
+Deprecated.
+ |
+
void |
+trackConditionalCacheHit()
+Deprecated.
+Track an conditional GET that was satisfied by this cache.
+ |
+
void |
+trackResponse(ResponseSource source)
+Deprecated.
+Track an HTTP response being satisfied by
+source. |
+
void |
+update(com.squareup.okhttp.internal.http.Response cached,
+ com.squareup.okhttp.internal.http.Response network)
+Deprecated.
+Handles a conditional request hit by updating the stored cache response
+ with the headers from
+network. |
+
com.squareup.okhttp.internal.http.Response get(com.squareup.okhttp.internal.http.Request request) + throws IOException+
IOExceptionCacheRequest put(com.squareup.okhttp.internal.http.Response response) + throws IOException+
IOExceptionboolean maybeRemove(com.squareup.okhttp.internal.http.Request request) + throws IOException+
uri. Returns true if the
+ supplied requestMethod potentially invalidates an entry in the
+ cache.IOExceptionvoid update(com.squareup.okhttp.internal.http.Response cached, + com.squareup.okhttp.internal.http.Response network) + throws IOException+
network. The cached response body is not
+ updated. If the stored response has changed since cached was
+ returned, this does nothing.IOExceptionvoid trackConditionalCacheHit()+
void trackResponse(ResponseSource source)+
source.Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/Protocol.html b/1.x/javadoc/com/squareup/okhttp/Protocol.html new file mode 100644 index 000000000..059965a74 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/Protocol.html @@ -0,0 +1,407 @@ + + + + + + +public enum Protocol +extends Enum<Protocol>+
+
URL.getProtocol() returns the
+ scheme (http, https, etc.) of the URL, not
+ the protocol (http/1.1, spdy/3.1, etc.). OkHttp uses the word protocol to
+ indicate how HTTP messages are framed.| Enum Constant and Description | +
|---|
HTTP_11 |
+
HTTP_2 |
+
SPDY_3 |
+
| Modifier and Type | +Field and Description | +
|---|---|
com.squareup.okhttp.internal.okio.ByteString |
+name
+Deprecated.
+
+removed from the public API in OkHttp 2.0.
+ |
+
boolean |
+spdyVariant
+Deprecated.
+
+removed from the public API in OkHttp 2.0.
+ |
+
| Modifier and Type | +Method and Description | +
|---|---|
static Protocol |
+valueOf(String name)
+Returns the enum constant of this type with the specified name.
+ |
+
static Protocol[] |
+values()
+Returns an array containing the constants of this enum type, in
+the order they are declared.
+ |
+
public static final Protocol HTTP_2+
public static final Protocol SPDY_3+
public static final Protocol HTTP_11+
@Deprecated +public final com.squareup.okhttp.internal.okio.ByteString name+
@Deprecated +public final boolean spdyVariant+
Variantpublic static Protocol[] values()+
+for (Protocol c : Protocol.values()) + System.out.println(c); +
public static Protocol valueOf(String name)+
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant
+with the specified nameNullPointerException - if the argument is nullCopyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/ResponseSource.html b/1.x/javadoc/com/squareup/okhttp/ResponseSource.html new file mode 100644 index 000000000..b896fa616 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/ResponseSource.html @@ -0,0 +1,413 @@ + + + + + + +networkResponse() and cacheResponse() to compute how the
+ request was satisfied.@Deprecated +public enum ResponseSource +extends Enum<ResponseSource>+
| Enum Constant and Description | +
|---|
CACHE
+Deprecated.
+The response was returned from the local cache.
+ |
+
CONDITIONAL_CACHE
+Deprecated.
+The response is available in the cache but must be validated with the
+ network.
+ |
+
NETWORK
+Deprecated.
+The response was returned from the network.
+ |
+
NONE
+Deprecated.
+The request demanded a cached response that the cache couldn't satisfy.
+ |
+
| Modifier and Type | +Method and Description | +
|---|---|
boolean |
+requiresConnection()
+Deprecated.
+ |
+
boolean |
+usesCache()
+Deprecated.
+ |
+
static ResponseSource |
+valueOf(String name)
+Deprecated.
+Returns the enum constant of this type with the specified name.
+ |
+
static ResponseSource[] |
+values()
+Deprecated.
+Returns an array containing the constants of this enum type, in
+the order they are declared.
+ |
+
public static final ResponseSource CACHE+
public static final ResponseSource CONDITIONAL_CACHE+
public static final ResponseSource NETWORK+
public static final ResponseSource NONE+
public static ResponseSource[] values()+
+for (ResponseSource c : ResponseSource.values()) + System.out.println(c); +
public static ResponseSource valueOf(String name)+
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant
+with the specified nameNullPointerException - if the argument is nullpublic boolean requiresConnection()+
public boolean usesCache()+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/Route.html b/1.x/javadoc/com/squareup/okhttp/Route.html new file mode 100644 index 000000000..13ee7dcd4 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/Route.html @@ -0,0 +1,379 @@ + + + + + + +public class Route +extends Object+
proxy selector is used. It may return multiple proxies to attempt.
+ | Constructor and Description | +
|---|
Route(Address address,
+ Proxy proxy,
+ InetSocketAddress inetSocketAddress,
+ boolean modernTls) |
+
| Modifier and Type | +Method and Description | +
|---|---|
boolean |
+equals(Object obj) |
+
Address |
+getAddress()
+Returns the
+Address of this route. |
+
Proxy |
+getProxy()
+Returns the
+Proxy of this route. |
+
InetSocketAddress |
+getSocketAddress()
+Returns the
+InetSocketAddress of this route. |
+
String |
+getTlsVersion() |
+
int |
+hashCode() |
+
boolean |
+isModernTls()
+Deprecated.
+
+replaced with
+getTlsVersion() in OkHttp 2.0. |
+
public Route(Address address, + Proxy proxy, + InetSocketAddress inetSocketAddress, + boolean modernTls)+
public Proxy getProxy()+
Proxy of this route.
+
+ Warning: This may disagree with Address.getProxy()
+ is null. When the address's proxy is null, the proxy selector will be used.public InetSocketAddress getSocketAddress()+
InetSocketAddress of this route.@Deprecated +public boolean isModernTls()+
getTlsVersion() in OkHttp 2.0.public String getTlsVersion()+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/RouteDatabase.html b/1.x/javadoc/com/squareup/okhttp/RouteDatabase.html new file mode 100644 index 000000000..b789cdeca --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/RouteDatabase.html @@ -0,0 +1,325 @@ + + + + + + +@Deprecated +public final class RouteDatabase +extends Object+
| Constructor and Description | +
|---|
RouteDatabase()
+Deprecated.
+ |
+
| Modifier and Type | +Method and Description | +
|---|---|
void |
+connected(Route route)
+Deprecated.
+Records success connecting to
+failedRoute. |
+
void |
+failed(Route failedRoute)
+Deprecated.
+Records a failure connecting to
+failedRoute. |
+
int |
+failedRoutesCount()
+Deprecated.
+ |
+
boolean |
+shouldPostpone(Route route)
+Deprecated.
+Returns true if
+route has failed recently and should be avoided. |
+
public void failed(Route failedRoute)+
failedRoute.public void connected(Route route)+
failedRoute.public boolean shouldPostpone(Route route)+
route has failed recently and should be avoided.public int failedRoutesCount()+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/TunnelRequest.html b/1.x/javadoc/com/squareup/okhttp/TunnelRequest.html new file mode 100644 index 000000000..9e6c0d695 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/TunnelRequest.html @@ -0,0 +1,249 @@ + + + + + + +@Deprecated +public final class TunnelRequest +extends Object+
| Constructor and Description | +
|---|
TunnelRequest(String host,
+ int port,
+ String userAgent,
+ String proxyAuthorization)
+Deprecated.
+ |
+
public TunnelRequest(String host, + int port, + String userAgent, + String proxyAuthorization)+
host - the origin server's hostname. Not null.port - the origin server's port, like 80 or 443.userAgent - the client's user-agent. Not null.proxyAuthorization - proxy authorization, or null if the proxy is
+ used without an authorization header.Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/apache/OkApacheClient.html b/1.x/javadoc/com/squareup/okhttp/apache/OkApacheClient.html deleted file mode 100644 index 53f732334..000000000 --- a/1.x/javadoc/com/squareup/okhttp/apache/OkApacheClient.html +++ /dev/null @@ -1,528 +0,0 @@ - - - - - - -public class OkApacheClient -extends Object -implements org.apache.http.client.HttpClient-
HttpClient API using OkHttpClient.
- - Warning: Many core features of Apache HTTP client are not implemented by this - API. This includes the keep-alive strategy, cookie store, credentials provider, route planner - and others.
| Modifier and Type | -Field and Description | -
|---|---|
protected OkHttpClient |
-client |
-
| Constructor and Description | -
|---|
OkApacheClient() |
-
OkApacheClient(OkHttpClient client) |
-
| Modifier and Type | -Method and Description | -
|---|---|
org.apache.http.HttpResponse |
-execute(org.apache.http.HttpHost host,
- org.apache.http.HttpRequest request) |
-
org.apache.http.HttpResponse |
-execute(org.apache.http.HttpHost host,
- org.apache.http.HttpRequest request,
- org.apache.http.protocol.HttpContext context) |
-
<T> T |
-execute(org.apache.http.HttpHost host,
- org.apache.http.HttpRequest request,
- org.apache.http.client.ResponseHandler<? extends T> handler) |
-
<T> T |
-execute(org.apache.http.HttpHost host,
- org.apache.http.HttpRequest request,
- org.apache.http.client.ResponseHandler<? extends T> handler,
- org.apache.http.protocol.HttpContext context) |
-
org.apache.http.HttpResponse |
-execute(org.apache.http.client.methods.HttpUriRequest request) |
-
org.apache.http.HttpResponse |
-execute(org.apache.http.client.methods.HttpUriRequest request,
- org.apache.http.protocol.HttpContext context) |
-
<T> T |
-execute(org.apache.http.client.methods.HttpUriRequest request,
- org.apache.http.client.ResponseHandler<? extends T> handler) |
-
<T> T |
-execute(org.apache.http.client.methods.HttpUriRequest request,
- org.apache.http.client.ResponseHandler<? extends T> handler,
- org.apache.http.protocol.HttpContext context) |
-
org.apache.http.conn.ClientConnectionManager |
-getConnectionManager() |
-
org.apache.http.params.HttpParams |
-getParams() |
-
protected HttpURLConnection |
-openConnection(URL url)
-Returns a new HttpURLConnection customized for this application.
- |
-
protected final OkHttpClient client-
public OkApacheClient()-
public OkApacheClient(OkHttpClient client)-
protected HttpURLConnection openConnection(URL url)-
public org.apache.http.params.HttpParams getParams()-
getParams in interface org.apache.http.client.HttpClientpublic org.apache.http.conn.ClientConnectionManager getConnectionManager()-
getConnectionManager in interface org.apache.http.client.HttpClientpublic org.apache.http.HttpResponse execute(org.apache.http.client.methods.HttpUriRequest request) - throws IOException-
execute in interface org.apache.http.client.HttpClientIOExceptionpublic org.apache.http.HttpResponse execute(org.apache.http.client.methods.HttpUriRequest request, - org.apache.http.protocol.HttpContext context) - throws IOException-
execute in interface org.apache.http.client.HttpClientIOExceptionpublic org.apache.http.HttpResponse execute(org.apache.http.HttpHost host, - org.apache.http.HttpRequest request) - throws IOException-
execute in interface org.apache.http.client.HttpClientIOExceptionpublic org.apache.http.HttpResponse execute(org.apache.http.HttpHost host, - org.apache.http.HttpRequest request, - org.apache.http.protocol.HttpContext context) - throws IOException-
execute in interface org.apache.http.client.HttpClientIOExceptionpublic <T> T execute(org.apache.http.client.methods.HttpUriRequest request, - org.apache.http.client.ResponseHandler<? extends T> handler) - throws IOException-
execute in interface org.apache.http.client.HttpClientIOExceptionpublic <T> T execute(org.apache.http.client.methods.HttpUriRequest request, - org.apache.http.client.ResponseHandler<? extends T> handler, - org.apache.http.protocol.HttpContext context) - throws IOException-
execute in interface org.apache.http.client.HttpClientIOExceptionpublic <T> T execute(org.apache.http.HttpHost host, - org.apache.http.HttpRequest request, - org.apache.http.client.ResponseHandler<? extends T> handler) - throws IOException-
execute in interface org.apache.http.client.HttpClientIOExceptionpublic <T> T execute(org.apache.http.HttpHost host, - org.apache.http.HttpRequest request, - org.apache.http.client.ResponseHandler<? extends T> handler, - org.apache.http.protocol.HttpContext context) - throws IOException-
execute in interface org.apache.http.client.HttpClientIOExceptionCopyright © 2014. All Rights Reserved.
- - diff --git a/1.x/javadoc/com/squareup/okhttp/apache/class-use/OkApacheClient.html b/1.x/javadoc/com/squareup/okhttp/apache/class-use/OkApacheClient.html deleted file mode 100644 index 69bfc2446..000000000 --- a/1.x/javadoc/com/squareup/okhttp/apache/class-use/OkApacheClient.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/1.x/javadoc/com/squareup/okhttp/apache/package-frame.html b/1.x/javadoc/com/squareup/okhttp/apache/package-frame.html deleted file mode 100644 index a10ed4cb8..000000000 --- a/1.x/javadoc/com/squareup/okhttp/apache/package-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/1.x/javadoc/com/squareup/okhttp/class-use/Address.html b/1.x/javadoc/com/squareup/okhttp/class-use/Address.html new file mode 100644 index 000000000..0faf23064 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/class-use/Address.html @@ -0,0 +1,171 @@ + + + + + + +| Modifier and Type | +Method and Description | +
|---|---|
Address |
+Route.getAddress()
+Returns the
+Address of this route. |
+
| Modifier and Type | +Method and Description | +
|---|---|
Connection |
+ConnectionPool.get(Address address)
+Returns a recycled connection to
+address, or null if no such connection exists. |
+
| Constructor and Description | +
|---|
Route(Address address,
+ Proxy proxy,
+ InetSocketAddress inetSocketAddress,
+ boolean modernTls) |
+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/class-use/Cache.html b/1.x/javadoc/com/squareup/okhttp/class-use/Cache.html new file mode 100644 index 000000000..b14522141 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/class-use/Cache.html @@ -0,0 +1,170 @@ + + + + + + +| Modifier and Type | +Class and Description | +
|---|---|
class |
+HttpResponseCache
+Deprecated.
+
+renamed to
+Cache. |
+
| Modifier and Type | +Method and Description | +
|---|---|
Cache |
+OkHttpClient.getCache() |
+
| Modifier and Type | +Method and Description | +
|---|---|
OkHttpClient |
+OkHttpClient.setCache(Cache cache) |
+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/class-use/CacheControl.html b/1.x/javadoc/com/squareup/okhttp/class-use/CacheControl.html new file mode 100644 index 000000000..ff44b478e --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/class-use/CacheControl.html @@ -0,0 +1,142 @@ + + + + + + +| Modifier and Type | +Method and Description | +
|---|---|
static CacheControl |
+CacheControl.parse(com.squareup.okhttp.internal.http.Headers headers)
+Returns the cache directives of
+headers. |
+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/class-use/Connection.html b/1.x/javadoc/com/squareup/okhttp/class-use/Connection.html new file mode 100644 index 000000000..8828e98d3 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/class-use/Connection.html @@ -0,0 +1,163 @@ + + + + + + +| Modifier and Type | +Method and Description | +
|---|---|
Connection |
+ConnectionPool.get(Address address)
+Returns a recycled connection to
+address, or null if no such connection exists. |
+
| Modifier and Type | +Method and Description | +
|---|---|
void |
+ConnectionPool.recycle(Connection connection)
+Gives
+connection to the pool. |
+
void |
+ConnectionPool.share(Connection connection)
+Shares the SPDY connection with the pool.
+ |
+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/class-use/ConnectionPool.html b/1.x/javadoc/com/squareup/okhttp/class-use/ConnectionPool.html new file mode 100644 index 000000000..5089cbc40 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/class-use/ConnectionPool.html @@ -0,0 +1,171 @@ + + + + + + +| Modifier and Type | +Method and Description | +
|---|---|
ConnectionPool |
+OkHttpClient.getConnectionPool() |
+
static ConnectionPool |
+ConnectionPool.getDefault() |
+
| Modifier and Type | +Method and Description | +
|---|---|
OkHttpClient |
+OkHttpClient.setConnectionPool(ConnectionPool connectionPool)
+Sets the connection pool used to recycle HTTP and HTTPS connections.
+ |
+
| Constructor and Description | +
|---|
Connection(ConnectionPool pool,
+ Route route) |
+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/class-use/Handshake.html b/1.x/javadoc/com/squareup/okhttp/class-use/Handshake.html new file mode 100644 index 000000000..4fe500aa9 --- /dev/null +++ b/1.x/javadoc/com/squareup/okhttp/class-use/Handshake.html @@ -0,0 +1,150 @@ + + + + + + +| Modifier and Type | +Method and Description | +
|---|---|
static Handshake |
+Handshake.get(SSLSession session) |
+
static Handshake |
+Handshake.get(String cipherSuite,
+ List<Certificate> peerCertificates,
+ List<Certificate> localCertificates) |
+
Handshake |
+Connection.getHandshake() |
+
Copyright © 2014. All Rights Reserved.
+ + diff --git a/1.x/javadoc/com/squareup/okhttp/apache/package-use.html b/1.x/javadoc/com/squareup/okhttp/class-use/HttpResponseCache.html similarity index 67% rename from 1.x/javadoc/com/squareup/okhttp/apache/package-use.html rename to 1.x/javadoc/com/squareup/okhttp/class-use/HttpResponseCache.html index 850deeb8e..4ee7f30ac 100644 --- a/1.x/javadoc/com/squareup/okhttp/apache/package-use.html +++ b/1.x/javadoc/com/squareup/okhttp/class-use/HttpResponseCache.html @@ -2,16 +2,16 @@ - + -