Modifier and Type | Method and Description |
---|---|
OkHttpClient |
OkHttpClient.cancel(Object tag)
Cancels all scheduled or in-flight calls tagged with
tag . |
OkHttpClient |
OkHttpClient.clone()
Returns a shallow copy of this OkHttpClient.
|
OkHttpClient |
OkHttpClient.setAuthenticator(Authenticator authenticator)
Sets the authenticator used to respond to challenges from the remote web
server or proxy server.
|
OkHttpClient |
OkHttpClient.setCache(Cache cache) |
OkHttpClient |
OkHttpClient.setCertificatePinner(CertificatePinner certificatePinner)
Sets the certificate pinner that constrains which certificates are trusted.
|
OkHttpClient |
OkHttpClient.setConnectionPool(ConnectionPool connectionPool)
Sets the connection pool used to recycle HTTP and HTTPS connections.
|
OkHttpClient |
OkHttpClient.setConnectionSpecs(List<ConnectionSpec> connectionSpecs) |
OkHttpClient |
OkHttpClient.setCookieHandler(CookieHandler cookieHandler)
Sets the cookie handler to be used to read outgoing cookies and write
incoming cookies.
|
OkHttpClient |
OkHttpClient.setDispatcher(Dispatcher dispatcher)
Sets the dispatcher used to set policy and execute asynchronous requests.
|
OkHttpClient |
OkHttpClient.setDns(Dns dns)
Sets the DNS service used to lookup IP addresses for hostnames.
|
OkHttpClient |
OkHttpClient.setFollowSslRedirects(boolean followProtocolRedirects)
Configure this client to follow redirects from HTTPS to HTTP and from HTTP
to HTTPS.
|
OkHttpClient |
OkHttpClient.setHostnameVerifier(HostnameVerifier hostnameVerifier)
Sets the verifier used to confirm that response certificates apply to
requested hostnames for HTTPS connections.
|
OkHttpClient |
OkHttpClient.setProtocols(List<Protocol> protocols)
Configure the protocols used by this client to communicate with remote
servers.
|
OkHttpClient |
OkHttpClient.setProxy(Proxy proxy)
Sets the HTTP proxy that will be used by connections created by this
client.
|
OkHttpClient |
OkHttpClient.setProxySelector(ProxySelector proxySelector)
Sets the proxy selection policy to be used if no
proxy
is specified explicitly. |
OkHttpClient |
OkHttpClient.setSocketFactory(SocketFactory socketFactory)
Sets the socket factory used to create connections.
|
OkHttpClient |
OkHttpClient.setSslSocketFactory(SSLSocketFactory sslSocketFactory)
Sets the socket factory used to secure HTTPS connections.
|
Constructor and Description |
---|
Call(OkHttpClient client,
Request originalRequest) |
Copyright © 2016. All Rights Reserved.