A  B  C  D  E  F  G  H  I  J  K  L  M  N  O  P  Q  R  S  T  U  V  W 

A

abort() - Method in class okhttp3 .internal . DiskLruCache.Editor
Aborts this edit.
abort() - Method in interface okhttp3 .internal .http . CacheRequest
 
abortUnlessCommitted() - Method in class okhttp3 .internal . DiskLruCache.Editor
 
ackSettings() - Method in interface okhttp3 .internal .framed . FrameReader.Handler
HTTP/2 only.
ackSettings(Settings) - Method in interface okhttp3 .internal .framed . FrameWriter
Informs the peer that we've applied its latest settings.
acquire(RealConnection) - Method in class okhttp3 .internal .http . StreamAllocation
Use this allocation to hold connection.
add(String, String...) - Method in class okhttp3 . CertificatePinner.Builder
Pins certificates for pattern.
add(String, String) - Method in class okhttp3 . FormBody.Builder
 
add(String) - Method in class okhttp3 . Headers.Builder
Add an header line containing a field name, a literal colon, and a value.
add(String, String) - Method in class okhttp3 . Headers.Builder
Add a field with the specified value.
addConnectException(IOException) - Method in exception okhttp3 .internal .http . RouteException
 
addEncoded(String, String) - Method in class okhttp3 . FormBody.Builder
 
addEncodedPathSegment(String) - Method in class okhttp3 . HttpUrl.Builder
 
addEncodedPathSegments(String) - Method in class okhttp3 . HttpUrl.Builder
Adds a set of encoded path segments separated by a slash (either \ or /).
addEncodedQueryParameter(String, String) - Method in class okhttp3 . HttpUrl.Builder
Adds the pre-encoded query parameter to this URL's query string.
addFormDataPart(String, String) - Method in class okhttp3 . MultipartBody.Builder
Add a form data part to the body.
addFormDataPart(String, String, RequestBody) - Method in class okhttp3 . MultipartBody.Builder
Add a form data part to the body.
addHeader(String, String) - Method in class okhttp3 . Request.Builder
Adds a header with name and value.
addHeader(String, String) - Method in class okhttp3 . Response.Builder
Adds a header with name and value.
addInterceptor(Interceptor) - Method in class okhttp3 . OkHttpClient.Builder
 
addLenient(Headers.Builder, String) - Method in class okhttp3 .internal . Internal
 
addLenient(Headers.Builder, String, String) - Method in class okhttp3 .internal . Internal
 
addNetworkInterceptor(Interceptor) - Method in class okhttp3 . OkHttpClient.Builder
 
addPart(RequestBody) - Method in class okhttp3 . MultipartBody.Builder
Add a part to the body.
addPart(Headers, RequestBody) - Method in class okhttp3 . MultipartBody.Builder
Add a part to the body.
addPart(MultipartBody.Part) - Method in class okhttp3 . MultipartBody.Builder
Add a part to the body.
addPathSegment(String) - Method in class okhttp3 . HttpUrl.Builder
 
addPathSegments(String) - Method in class okhttp3 . HttpUrl.Builder
Adds a set of path segments separated by a slash (either \ or /).
addQueryParameter(String, String) - Method in class okhttp3 . HttpUrl.Builder
Encodes the query parameter using UTF-8 and adds it to this URL's query string.
Address - Class in okhttp3
A specification for a connection to an origin server.
Address(String, int, Dns, SocketFactory, SSLSocketFactory, HostnameVerifier, CertificatePinner, Authenticator, Proxy, List<Protocol>, List<ConnectionSpec>, ProxySelector) - Constructor for class okhttp3 . Address
 
address - Variable in class okhttp3 .internal .http . StreamAllocation
 
address() - Method in class okhttp3 . Route
 
afterHandshake(SSLSocket) - Method in class okhttp3 .internal . Platform
allEnabledCipherSuites() - Method in class okhttp3 . ConnectionSpec.Builder
 
allEnabledTlsVersions() - Method in class okhttp3 . ConnectionSpec.Builder
 
allocationLimit - Variable in class okhttp3 .internal .io . RealConnection
 
allocations - Variable in class okhttp3 .internal .io . RealConnection
 
allSubjectAltNames(X509Certificate) - Static method in class okhttp3 .internal .tls . OkHostnameVerifier
 
alternateService(int, String, ByteString, String, int, long) - Method in interface okhttp3 .internal .framed . FrameReader.Handler
HTTP/2 only.
ALTERNATIVE - Static variable in class okhttp3 . MultipartBody
The "multipart/alternative" type is syntactically identical to "multipart/mixed", but the semantics are different.
AndroidTrustRootIndex - Class in okhttp3.internal.tls
A index of trusted root certificates that exploits knowledge of Android implementation details.
AndroidTrustRootIndex(X509TrustManager, Method) - Constructor for class okhttp3 .internal .tls . AndroidTrustRootIndex
 
appendingSink(File) - Method in interface okhttp3 .internal .io . FileSystem
Writes to file, appending if data is already present.
apply(ConnectionSpec, SSLSocket, boolean) - Method in class okhttp3 .internal . Internal
 
authenticate(Route, Response) - Method in interface okhttp3 . Authenticator
Returns a request that includes a credential to satisfy an authentication challenge in response.
Authenticator - Interface in okhttp3
Responds to an authentication challenge from either a remote web server or a proxy server.
authenticator() - Method in class okhttp3 . OkHttpClient
 
authenticator(Authenticator) - Method in class okhttp3 . OkHttpClient.Builder
Sets the authenticator used to respond to challenges from origin servers.

B

basic(String, String) - Static method in class okhttp3 . Credentials
Returns an auth credential for the Basic scheme.
body() - Method in interface okhttp3 .internal .http . CacheRequest
 
body() - Method in class okhttp3 . Request
 
body() - Method in class okhttp3 . Response
 
body(ResponseBody) - Method in class okhttp3 . Response.Builder
 
boundary() - Method in class okhttp3 . MultipartBody
 
bufferRequestBody - Variable in class okhttp3 .internal .http . HttpEngine
True if the request body must be completely buffered before transmission; false if it can be streamed.
build() - Method in class okhttp3 . CacheControl.Builder
 
build() - Method in class okhttp3 . CertificatePinner.Builder
 
build() - Method in class okhttp3 . ConnectionSpec.Builder
 
build() - Method in class okhttp3 . Cookie.Builder
 
build() - Method in class okhttp3 . FormBody.Builder
 
build() - Method in class okhttp3 . Headers.Builder
 
build() - Method in class okhttp3 . HttpUrl.Builder
 
build() - Method in class okhttp3 .internal .framed . FramedConnection.Builder
 
build() - Method in class okhttp3 . MultipartBody.Builder
Assemble the specified parts into a request body.
build() - Method in class okhttp3 . OkHttpClient.Builder
 
build() - Method in class okhttp3 . Request.Builder
 
build() - Method in class okhttp3 . Response.Builder
 
Builder() - Constructor for class okhttp3 . CacheControl.Builder
 
Builder() - Constructor for class okhttp3 . CertificatePinner.Builder
 
Builder(ConnectionSpec) - Constructor for class okhttp3 . ConnectionSpec.Builder
 
Builder() - Constructor for class okhttp3 . Cookie.Builder
 
Builder() - Constructor for class okhttp3 . FormBody.Builder
 
Builder() - Constructor for class okhttp3 . Headers.Builder
 
Builder() - Constructor for class okhttp3 . HttpUrl.Builder
 
Builder(boolean) - Constructor for class okhttp3 .internal .framed . FramedConnection.Builder
 
Builder() - Constructor for class okhttp3 . MultipartBody.Builder
 
Builder(String) - Constructor for class okhttp3 . MultipartBody.Builder
 
Builder() - Constructor for class okhttp3 . OkHttpClient.Builder
 
Builder() - Constructor for class okhttp3 . Request.Builder
 
Builder() - Constructor for class okhttp3 . Response.Builder
 
bytes() - Method in class okhttp3 . ResponseBody
 
byteStream() - Method in class okhttp3 . ResponseBody
 

C

Cache - Class in okhttp3
Caches HTTP and HTTPS responses to the filesystem so they may be reused, saving time and bandwidth.
Cache(File, long) - Constructor for class okhttp3 . Cache
 
cache(Cache) - Method in class okhttp3 . OkHttpClient.Builder
 
cache() - Method in class okhttp3 . OkHttpClient
 
CacheControl - Class in okhttp3
A Cache-Control header with cache directives from a server or client.
cacheControl(CacheControl) - Method in class okhttp3 . Request.Builder
Sets this request's Cache-Control header, replacing any cache control headers already present.
cacheControl() - Method in class okhttp3 . Request
Returns the cache control directives for this response.
cacheControl() - Method in class okhttp3 . Response
Returns the cache control directives for this response.
CacheControl.Builder - Class in okhttp3
Builds a Cache-Control request header.
CacheRequest - Interface in okhttp3.internal.http
 
cacheResponse - Variable in class okhttp3 .internal .http . CacheStrategy
The cached response to return or validate; or null if this call doesn't use a cache.
cacheResponse(Response) - Method in class okhttp3 . Response.Builder
 
cacheResponse() - Method in class okhttp3 . Response
Returns the raw response received from the cache.
CacheStrategy - Class in okhttp3.internal.http
Given a request and cached response, this figures out whether to use the network, the cache, or both.
CacheStrategy.Factory - Class in okhttp3.internal.http
 
Call - Interface in okhttp3
A call is a request that has been prepared for execution.
Call.Factory - Interface in okhttp3
 
Callback - Interface in okhttp3
 
callEngineGetStreamAllocation(Call) - Method in class okhttp3 .internal . Internal
 
callEnqueue(Call, Callback, boolean) - Method in class okhttp3 .internal . Internal
 
cancel() - Method in interface okhttp3 . Call
Cancels the request, if possible.
CANCEL - Static variable in interface okhttp3 .internal .framed . PushObserver
 
cancel() - Method in class okhttp3 .internal .http . Http1xStream
 
cancel() - Method in class okhttp3 .internal .http . Http2xStream
 
cancel() - Method in class okhttp3 .internal .http . HttpEngine
Immediately closes the socket connection if it's currently held by this engine.
cancel() - Method in interface okhttp3 .internal .http . HttpStream
Cancel this stream.
cancel() - Method in class okhttp3 .internal .http . StreamAllocation
 
cancel() - Method in class okhttp3 .internal .io . RealConnection
 
cancelAll() - Method in class okhttp3 . Dispatcher
Cancel all calls currently enqueued or executing.
CertificateChainCleaner - Class in okhttp3.internal.tls
Computes the effective certificate chain from the raw array returned by Java's built in TLS APIs.
CertificateChainCleaner(TrustRootIndex) - Constructor for class okhttp3 .internal .tls . CertificateChainCleaner
 
certificatePinner() - Method in class okhttp3 . Address
Returns this address's certificate pinner, or null if this is not an HTTPS address.
CertificatePinner - Class in okhttp3
Constrains which certificates are trusted.
certificatePinner(CertificatePinner) - Method in class okhttp3 . OkHttpClient.Builder
Sets the certificate pinner that constrains which certificates are trusted.
certificatePinner() - Method in class okhttp3 . OkHttpClient
 
CertificatePinner.Builder - Class in okhttp3
Builds a configured certificate pinner.
Challenge - Class in okhttp3
An RFC 2617 challenge.
Challenge(String, String) - Constructor for class okhttp3 . Challenge
 
challenges() - Method in class okhttp3 . Response
Returns the authorization challenges appropriate for this response's code.
charset() - Method in class okhttp3 . MediaType
Returns the charset of this media type, or null if this media type doesn't specify a charset.
charset(Charset) - Method in class okhttp3 . MediaType
Returns the charset of this media type, or defaultValue if this media type doesn't specify a charset.
charStream() - Method in class okhttp3 . ResponseBody
Returns the response as a character stream decoded with the charset of the Content-Type header.
check(String, List<Certificate>) - Method in class okhttp3 . CertificatePinner
Confirms that at least one of the certificates pinned for hostname is in peerCertificates.
check(String, Certificate...) - Method in class okhttp3 . CertificatePinner
Deprecated.
checkOffsetAndCount(long, long, long) - Static method in class okhttp3 .internal . Util
 
CipherSuite - Enum in okhttp3
cipherSuite() - Method in class okhttp3 . Handshake
Returns the cipher suite used for the connection.
cipherSuites(CipherSuite...) - Method in class okhttp3 . ConnectionSpec.Builder
 
cipherSuites(String...) - Method in class okhttp3 . ConnectionSpec.Builder
 
cipherSuites() - Method in class okhttp3 . ConnectionSpec
Returns the cipher suites to use for a connection.
clean(List<Certificate>) - Method in class okhttp3 .internal .tls . CertificateChainCleaner
Returns a cleaned chain for chain.
CLEARTEXT - Static variable in class okhttp3 . ConnectionSpec
Unencrypted, unauthenticated connections for http: URLs.
close() - Method in class okhttp3 . Cache
 
close() - Method in class okhttp3 .internal . DiskLruCache
Closes this cache.
close() - Method in class okhttp3 .internal . DiskLruCache.Snapshot
 
close() - Method in class okhttp3 .internal .framed . FramedConnection
Closes this connection.
close(ErrorCode) - Method in class okhttp3 .internal .framed . FramedStream
Abnormally terminate this stream.
close() - Method in class okhttp3 .internal .http . HttpEngine
Release any resources held by this engine.
close() - Method in class okhttp3 .internal .http . RetryableSink
 
close() - Method in class okhttp3 . ResponseBody
 
closeAll(Closeable, Closeable) - Static method in class okhttp3 .internal . Util
Closes a and b.
closeLater(ErrorCode) - Method in class okhttp3 .internal .framed . FramedStream
Abnormally terminate this stream.
closeQuietly(Closeable) - Static method in class okhttp3 .internal . Util
Closes closeable, ignoring any checked exceptions.
closeQuietly(Socket) - Static method in class okhttp3 .internal . Util
Closes socket, ignoring any checked exceptions.
closeQuietly(ServerSocket) - Static method in class okhttp3 .internal . Util
Closes serverSocket, ignoring any checked exceptions.
code - Variable in class okhttp3 .internal .http . StatusLine
 
code(int) - Method in class okhttp3 . Response.Builder
 
code() - Method in class okhttp3 . Response
Returns the HTTP status code.
commit() - Method in class okhttp3 .internal . DiskLruCache.Editor
Commits this edit so it is visible to readers.
COMPATIBLE_TLS - Static variable in class okhttp3 . ConnectionSpec
A backwards-compatible fallback connection for interop with obsolete servers.
concat(String[], String) - Static method in class okhttp3 .internal . Util
 
configureSecureSocket(SSLSocket) - Method in class okhttp3 .internal . ConnectionSpecSelector
Configures the supplied SSLSocket to connect to the specified host using an appropriate ConnectionSpec.
configureTlsExtensions(SSLSocket, String, List<Protocol>) - Method in class okhttp3 .internal . Platform
Configure TLS extensions on sslSocket for route.
connect(int, int, int, List<ConnectionSpec>, boolean) - Method in class okhttp3 .internal .io . RealConnection
 
connected(Route) - Method in class okhttp3 .internal . RouteDatabase
Records success connecting to failedRoute.
connectFailed(Route, IOException) - Method in class okhttp3 .internal .http . RouteSelector
Clients should invoke this method when they encounter a connectivity failure on a connection returned by this route selector.
Connection - Interface in okhttp3
The sockets and streams of an HTTP, HTTPS, or HTTPS+SPDY connection.
connection() - Method in interface okhttp3 . Interceptor.Chain
 
connection() - Method in class okhttp3 .internal .http . StreamAllocation
 
connectionBecameIdle(ConnectionPool, RealConnection) - Method in class okhttp3 .internal . Internal
 
connectionCount() - Method in class okhttp3 . ConnectionPool
Returns total number of connections in the pool.
connectionFailed(IOException) - Method in class okhttp3 .internal . ConnectionSpecSelector
Reports a failure to complete a connection.
connectionFailed(IOException) - Method in class okhttp3 .internal .http . StreamAllocation
 
ConnectionPool - Class in okhttp3
Manages reuse of HTTP and SPDY connections for reduced network latency.
ConnectionPool() - Constructor for class okhttp3 . ConnectionPool
Create a new connection pool with tuning parameters appropriate for a single-user application.
ConnectionPool(int, long, TimeUnit) - Constructor for class okhttp3 . ConnectionPool
 
connectionPool(ConnectionPool) - Method in class okhttp3 . OkHttpClient.Builder
Sets the connection pool used to recycle HTTP and HTTPS connections.
connectionPool() - Method in class okhttp3 . OkHttpClient
 
connectionPreface() - Method in interface okhttp3 .internal .framed . FrameWriter
HTTP/2 only.
ConnectionSpec - Class in okhttp3
Specifies configuration for the socket connection that HTTP traffic travels through.
ConnectionSpec.Builder - Class in okhttp3
 
connectionSpecs() - Method in class okhttp3 . Address
 
connectionSpecs(List<ConnectionSpec>) - Method in class okhttp3 . OkHttpClient.Builder
 
connectionSpecs() - Method in class okhttp3 . OkHttpClient
 
ConnectionSpecSelector - Class in okhttp3.internal
Handles the connection spec fallback strategy: When a secure socket connection fails due to a handshake / protocol problem the connection may be retried with different protocols.
ConnectionSpecSelector(List<ConnectionSpec>) - Constructor for class okhttp3 .internal . ConnectionSpecSelector
 
connectSocket(Socket, InetSocketAddress, int) - Method in class okhttp3 .internal . Platform
 
connectTimeout(long, TimeUnit) - Method in class okhttp3 . OkHttpClient.Builder
Sets the default connect timeout for new connections.
connectTimeoutMillis() - Method in class okhttp3 . OkHttpClient
Default connect timeout (in milliseconds).
contains(String[], String) - Static method in class okhttp3 .internal . Util
 
contentLength() - Method in class okhttp3 . FormBody
 
contentLength(Request) - Static method in class okhttp3 .internal .http . OkHeaders
 
contentLength(Response) - Static method in class okhttp3 .internal .http . OkHeaders
 
contentLength(Headers) - Static method in class okhttp3 .internal .http . OkHeaders
 
contentLength() - Method in class okhttp3 .internal .http . RealResponseBody
 
contentLength() - Method in class okhttp3 .internal .http . RetryableSink
 
contentLength() - Method in class okhttp3 . MultipartBody
 
contentLength() - Method in class okhttp3 . RequestBody
Returns the number of bytes that will be written to out in a call to RequestBody.writeTo(okio.BufferedSink), or -1 if that count is unknown.
contentLength() - Method in class okhttp3 . ResponseBody
Returns the number of bytes in that will returned by ResponseBody.bytes(), or ResponseBody.byteStream(), or -1 if unknown.
contentType() - Method in class okhttp3 . FormBody
 
contentType() - Method in class okhttp3 .internal .http . RealResponseBody
 
contentType() - Method in class okhttp3 . MultipartBody
contentType() - Method in class okhttp3 . RequestBody
Returns the Content-Type header for this body.
contentType() - Method in class okhttp3 . ResponseBody
 
Cookie - Class in okhttp3
An RFC 6265 Cookie.
Cookie.Builder - Class in okhttp3
Builds a cookie.
CookieJar - Interface in okhttp3
Provides policy and persistence for HTTP cookies.
cookieJar(CookieJar) - Method in class okhttp3 . OkHttpClient.Builder
Sets the handler that can accept cookies from incoming HTTP responses and provides cookies to outgoing HTTP requests.
cookieJar() - Method in class okhttp3 . OkHttpClient
 
create(FileSystem, File, int, int, long) - Static method in class okhttp3 .internal . DiskLruCache
Create a cache which will reside in directory.
create(RequestBody) - Static method in class okhttp3 . MultipartBody.Part
 
create(Headers, RequestBody) - Static method in class okhttp3 . MultipartBody.Part
 
create(MediaType, String) - Static method in class okhttp3 . RequestBody
Returns a new request body that transmits content.
create(MediaType, ByteString) - Static method in class okhttp3 . RequestBody
Returns a new request body that transmits content.
create(MediaType, byte[]) - Static method in class okhttp3 . RequestBody
Returns a new request body that transmits content.
create(MediaType, byte[], int, int) - Static method in class okhttp3 . RequestBody
Returns a new request body that transmits content.
create(MediaType, File) - Static method in class okhttp3 . RequestBody
Returns a new request body that transmits the content of file.
create(MediaType, String) - Static method in class okhttp3 . ResponseBody
Returns a new response body that transmits content.
create(MediaType, byte[]) - Static method in class okhttp3 . ResponseBody
Returns a new response body that transmits content.
create(MediaType, long, BufferedSource) - Static method in class okhttp3 . ResponseBody
Returns a new response body that transmits content.
createFormData(String, String) - Static method in class okhttp3 . MultipartBody.Part
 
createFormData(String, String, RequestBody) - Static method in class okhttp3 . MultipartBody.Part
 
createRequestBody(Request, long) - Method in class okhttp3 .internal .http . Http1xStream
 
createRequestBody(Request, long) - Method in class okhttp3 .internal .http . Http2xStream
 
createRequestBody(Request, long) - Method in interface okhttp3 .internal .http . HttpStream
Returns an output stream where the request body can be streamed.
Credentials - Class in okhttp3
Factory for HTTP authorization credentials.

D

data(boolean, int, BufferedSource, int) - Method in interface okhttp3 .internal .framed . FrameReader.Handler
 
data(boolean, int, Buffer, int) - Method in interface okhttp3 .internal .framed . FrameWriter
source.length may be longer than the max length of the variant's data frame.
DEFAULT - Static variable in class okhttp3 . CertificatePinner
 
defaultPort(String) - Static method in class okhttp3 . HttpUrl
Returns 80 if scheme.equals("http"), 443 if scheme.equals("https") and -1 otherwise.
delete() - Method in class okhttp3 . Cache
Closes the cache and deletes all of its stored values.
delete() - Method in class okhttp3 .internal . DiskLruCache
Closes the cache and deletes all of its stored values.
delete(File) - Method in interface okhttp3 .internal .io . FileSystem
Deletes file if it exists.
delete(RequestBody) - Method in class okhttp3 . Request.Builder
 
delete() - Method in class okhttp3 . Request.Builder
 
deleteContents(File) - Method in interface okhttp3 .internal .io . FileSystem
Recursively delete the contents of directory.
delimiterOffset(String, int, int, String) - Static method in class okhttp3 .internal . Util
Returns the index of the first character in input that contains a character in delimiters.
delimiterOffset(String, int, int, char) - Static method in class okhttp3 .internal . Util
Returns the index of the first character in input that is delimiter.
DIGEST - Static variable in class okhttp3 . MultipartBody
This type is syntactically identical to "multipart/mixed", but the semantics are different.
directory() - Method in class okhttp3 . Cache
 
discard(Source, int, TimeUnit) - Static method in class okhttp3 .internal . Util
Attempts to exhaust source, returning true if successful.
DISCARD_STREAM_TIMEOUT_MILLIS - Static variable in interface okhttp3 .internal .http . HttpStream
The timeout to use while discarding a stream of input data.
DiskLruCache - Class in okhttp3.internal
A cache that uses a bounded amount of space on a filesystem.
DiskLruCache.Editor - Class in okhttp3.internal
Edits the values for an entry.
DiskLruCache.Snapshot - Class in okhttp3.internal
A snapshot of the values for an entry.
Dispatcher - Class in okhttp3
Policy on when async requests are executed.
Dispatcher(ExecutorService) - Constructor for class okhttp3 . Dispatcher
 
Dispatcher() - Constructor for class okhttp3 . Dispatcher
 
dispatcher(Dispatcher) - Method in class okhttp3 . OkHttpClient.Builder
Sets the dispatcher used to set policy and execute asynchronous requests.
dispatcher() - Method in class okhttp3 . OkHttpClient
 
dns() - Method in class okhttp3 . Address
Returns the service that will be used to resolve IP addresses for hostnames.
Dns - Interface in okhttp3
A domain name service that resolves IP addresses for host names.
dns(Dns) - Method in class okhttp3 . OkHttpClient.Builder
Sets the DNS service used to lookup IP addresses for hostnames.
dns() - Method in class okhttp3 . OkHttpClient
 
domain(String) - Method in class okhttp3 . Cookie.Builder
Set the domain pattern for this cookie.
domain() - Method in class okhttp3 . Cookie
Returns the cookie's domain.
domainToAscii(String) - Static method in class okhttp3 .internal . Util
Performs IDN ToASCII encoding and canonicalize the result to lowercase.

E

edit(String) - Method in class okhttp3 .internal . DiskLruCache
Returns an editor for the entry named key, or null if another edit is in progress.
edit() - Method in class okhttp3 .internal . DiskLruCache.Snapshot
Returns an editor for this snapshot's entry, or null if either the entry has changed since this snapshot was created or if another edit is in progress.
EMPTY_BYTE_ARRAY - Static variable in class okhttp3 .internal . Util
 
EMPTY_STRING_ARRAY - Static variable in class okhttp3 .internal . Util
 
encodedFragment(String) - Method in class okhttp3 . HttpUrl.Builder
 
encodedFragment() - Method in class okhttp3 . HttpUrl
 
encodedName(int) - Method in class okhttp3 . FormBody
 
encodedPassword(String) - Method in class okhttp3 . HttpUrl.Builder
 
encodedPassword() - Method in class okhttp3 . HttpUrl
Returns the password, or an empty string if none is set.
encodedPath(String) - Method in class okhttp3 . HttpUrl.Builder
 
encodedPath() - Method in class okhttp3 . HttpUrl
Returns the entire path of this URL, encoded for use in HTTP resource resolution.
encodedPathSegments() - Method in class okhttp3 . HttpUrl
 
encodedQuery(String) - Method in class okhttp3 . HttpUrl.Builder
 
encodedQuery() - Method in class okhttp3 . HttpUrl
Returns the query of this URL, encoded for use in HTTP resource resolution.
encodedUsername(String) - Method in class okhttp3 . HttpUrl.Builder
 
encodedUsername() - Method in class okhttp3 . HttpUrl
Returns the username, or an empty string if none is set.
encodedValue(int) - Method in class okhttp3 . FormBody
 
enqueue(Callback) - Method in interface okhttp3 . Call
Schedules the request to be executed at some point in the future.
equal(Object, Object) - Static method in class okhttp3 .internal . Util
Returns true if two possibly-null objects are equal.
equals(Object) - Method in class okhttp3 . Address
 
equals(Object) - Method in class okhttp3 . Challenge
 
equals(Object) - Method in class okhttp3 . ConnectionSpec
 
equals(Object) - Method in class okhttp3 . Cookie
 
equals(Object) - Method in class okhttp3 . Handshake
 
equals(Object) - Method in class okhttp3 . HttpUrl
 
equals(Object) - Method in class okhttp3 .internal .framed . Header
 
equals(Object) - Method in class okhttp3 . MediaType
 
equals(Object) - Method in class okhttp3 . Route
 
ErrorCode - Enum in okhttp3.internal.framed
 
evictAll() - Method in class okhttp3 . Cache
Deletes all values stored in the cache.
evictAll() - Method in class okhttp3 . ConnectionPool
Close and remove all idle connections in the pool.
evictAll() - Method in class okhttp3 .internal . DiskLruCache
Deletes all stored values from the cache.
execute() - Method in interface okhttp3 . Call
Invokes the request immediately, and blocks until the response can be processed or is in error.
execute() - Method in class okhttp3 .internal . NamedRunnable
 
executorService() - Method in class okhttp3 . Dispatcher
 
exists(File) - Method in interface okhttp3 .internal .io . FileSystem
Returns true if file exists on the file system.
expiresAt(long) - Method in class okhttp3 . Cookie.Builder
 
expiresAt() - Method in class okhttp3 . Cookie
Returns the time that this cookie expires, in the same format as System.currentTimeMillis().

F

Factory(long, Request, Response) - Constructor for class okhttp3 .internal .http . CacheStrategy.Factory
 
failed(Route) - Method in class okhttp3 .internal . RouteDatabase
Records a failure connecting to failedRoute.
failedRoutesCount() - Method in class okhttp3 .internal . RouteDatabase
 
failIfHeadersAbsent() - Method in enum okhttp3 .internal .framed . HeadersMode
Returns true if it is an error these headers to be the initial headers of a response.
failIfHeadersPresent() - Method in enum okhttp3 .internal .framed . HeadersMode
Returns true if it is an error these headers to be update existing headers of a response.
failIfStreamAbsent() - Method in enum okhttp3 .internal .framed . HeadersMode
Returns true if it is an error these headers to create a new stream.
failIfStreamPresent() - Method in enum okhttp3 .internal .framed . HeadersMode
Returns true if it is an error these headers to update an existing stream.
FileSystem - Interface in okhttp3.internal.io
Access to read and write files on a hierarchical data store.
findByIssuerAndSignature(X509Certificate) - Method in class okhttp3 .internal .tls . AndroidTrustRootIndex
 
findByIssuerAndSignature(X509Certificate) - Method in class okhttp3 .internal .tls . RealTrustRootIndex
 
findByIssuerAndSignature(X509Certificate) - Method in interface okhttp3 .internal .tls . TrustRootIndex
Returns the trusted CA certificate that signed cert.
finishRequest() - Method in class okhttp3 .internal .http . Http1xStream
 
finishRequest() - Method in class okhttp3 .internal .http . Http2xStream
 
finishRequest() - Method in interface okhttp3 .internal .http . HttpStream
Flush the request to the underlying socket.
flush() - Method in class okhttp3 . Cache
 
flush() - Method in class okhttp3 .internal . DiskLruCache
Force buffered operations to the filesystem.
flush() - Method in class okhttp3 .internal .framed . FramedConnection
 
flush() - Method in interface okhttp3 .internal .framed . FrameWriter
SPDY/3 only.
flush() - Method in class okhttp3 .internal .http . RetryableSink
 
followRedirects(boolean) - Method in class okhttp3 . OkHttpClient.Builder
Configure this client to follow redirects.
followRedirects() - Method in class okhttp3 . OkHttpClient
 
followSslRedirects(boolean) - Method in class okhttp3 . OkHttpClient.Builder
Configure this client to follow redirects from HTTPS to HTTP and from HTTP to HTTPS.
followSslRedirects() - Method in class okhttp3 . OkHttpClient
 
followUpRequest() - Method in class okhttp3 .internal .http . HttpEngine
Figures out the HTTP request to make in response to receiving this engine's response.
FORCE_CACHE - Static variable in class okhttp3 . CacheControl
Cache control request directives that uses the cache only, even if the cached response is stale.
FORCE_NETWORK - Static variable in class okhttp3 . CacheControl
Cache control request directives that require network validation of responses.
forJavaName(String) - Static method in enum okhttp3 . CipherSuite
 
forJavaName(String) - Static method in enum okhttp3 . TlsVersion
 
FORM - Static variable in class okhttp3 . MultipartBody
The media-type multipart/form-data follows the rules of all multipart MIME data streams as outlined in RFC 2046.
format(Date) - Static method in class okhttp3 .internal .http . HttpDate
Returns the string for value.
FormBody - Class in okhttp3
 
FormBody.Builder - Class in okhttp3
 
fragment(String) - Method in class okhttp3 . HttpUrl.Builder
 
fragment() - Method in class okhttp3 . HttpUrl
 
FramedConnection - Class in okhttp3.internal.framed
A socket connection to a remote peer.
framedConnection - Variable in class okhttp3 .internal .io . RealConnection
 
FramedConnection.Builder - Class in okhttp3.internal.framed
 
FramedConnection.Listener - Class in okhttp3.internal.framed
Listener of streams and settings initiated by the peer.
FramedStream - Class in okhttp3.internal.framed
A logical bidirectional stream.
FrameReader - Interface in okhttp3.internal.framed
Reads transport frames for SPDY/3 or HTTP/2.
FrameReader.Handler - Interface in okhttp3.internal.framed
 
FrameWriter - Interface in okhttp3.internal.framed
Writes transport frames for SPDY/3 or HTTP/2.
fromHttp2(int) - Static method in enum okhttp3 .internal .framed . ErrorCode
 
fromSpdy3Rst(int) - Static method in enum okhttp3 .internal .framed . ErrorCode
 
fromSpdyGoAway(int) - Static method in enum okhttp3 .internal .framed . ErrorCode
 

G

get(SSLSession) - Static method in class okhttp3 . Handshake
 
get(TlsVersion, CipherSuite, List<Certificate>, List<Certificate>) - Static method in class okhttp3 . Handshake
 
get(String) - Method in class okhttp3 . Headers.Builder
Equivalent to build().get(name), but potentially faster.
get(String) - Method in class okhttp3 . Headers
Returns the last value corresponding to the specified field, or null.
get(URL) - Static method in class okhttp3 . HttpUrl
Returns an HttpUrl for url if its protocol is http or https, or null if it has any other protocol.
get(URI) - Static method in class okhttp3 . HttpUrl
 
get(String) - Method in class okhttp3 .internal . DiskLruCache
Returns a snapshot of the entry named key, or null if it doesn't exist is not currently readable.
get() - Method in class okhttp3 .internal .http . CacheStrategy.Factory
Returns a strategy to satisfy request using the a cached response response.
get(Response) - Static method in class okhttp3 .internal .http . StatusLine
 
get(ConnectionPool, Address, StreamAllocation) - Method in class okhttp3 .internal . Internal
 
get(Request) - Method in interface okhttp3 .internal . InternalCache
 
get() - Static method in class okhttp3 .internal . Platform
 
get(X509TrustManager) - Static method in class okhttp3 .internal .tls . AndroidTrustRootIndex
 
get(String) - Static method in enum okhttp3 . Protocol
Returns the protocol identified by protocol.
get() - Method in class okhttp3 . Request.Builder
 
getBufferedRequestBody() - Method in class okhttp3 .internal .http . HttpEngine
 
getCause() - Method in exception okhttp3 .internal .http . RequestException
 
getConnection() - Method in class okhttp3 .internal .framed . FramedStream
 
getConnection() - Method in class okhttp3 .internal .http . HttpEngine
 
getDate(String) - Method in class okhttp3 . Headers
Returns the last value corresponding to the specified field parsed as an HTTP date, or null if either the field is absent or cannot be parsed as a date.
getDirectory() - Method in class okhttp3 .internal . DiskLruCache
Returns the directory where this cache stores its data.
getErrorCode() - Method in class okhttp3 .internal .framed . FramedStream
Returns the reason why this stream was closed, or null if it closed normally or has not yet been closed.
getHttpUrlChecked(String) - Method in class okhttp3 .internal . Internal
 
getId() - Method in class okhttp3 .internal .framed . FramedStream
 
getIdleStartTimeNs() - Method in class okhttp3 .internal .framed . FramedConnection
Returns the time in ns when this connection became idle or Long.MAX_VALUE if connection is not idle.
getLastConnectException() - Method in exception okhttp3 .internal .http . RouteException
 
getLength(int) - Method in class okhttp3 .internal . DiskLruCache.Snapshot
Returns the byte length of the value for index.
getMaxRequests() - Method in class okhttp3 . Dispatcher
 
getMaxRequestsPerHost() - Method in class okhttp3 . Dispatcher
 
getMaxSize() - Method in class okhttp3 .internal . DiskLruCache
Returns the maximum number of bytes that this cache should use to store its data.
getPrefix() - Method in class okhttp3 .internal . Platform
Prefix used on custom headers.
getProtocol() - Method in class okhttp3 .internal .framed . FramedConnection
The protocol as selected using ALPN.
getProtocol() - Method in class okhttp3 .internal .framed . Http2
 
getProtocol() - Method in class okhttp3 .internal .framed . Spdy3
 
getProtocol() - Method in interface okhttp3 .internal .framed . Variant
The protocol as selected using ALPN.
getRequest() - Method in class okhttp3 .internal .http . HttpEngine
 
getRequestBody() - Method in class okhttp3 .internal .http . HttpEngine
Returns the request body or null if this request doesn't have a body.
getRequestHeaders() - Method in class okhttp3 .internal .framed . FramedStream
 
getResponse() - Method in class okhttp3 .internal .http . HttpEngine
Returns the engine's response.
getResponseHeaders() - Method in class okhttp3 .internal .framed . FramedStream
Returns the stream's response headers, blocking if necessary if they have not been received yet.
getSelectedProtocol(SSLSocket) - Method in class okhttp3 .internal . Platform
Returns the negotiated protocol, or null if no protocol was negotiated.
getSink() - Method in class okhttp3 .internal .framed . FramedStream
Returns a sink that can be used to write data to the peer.
getSource(int) - Method in class okhttp3 .internal . DiskLruCache.Snapshot
Returns the unbuffered stream with the value for index.
getSource() - Method in class okhttp3 .internal .framed . FramedStream
Returns a source that reads data from the peer.
goAway(int, ErrorCode, ByteString) - Method in interface okhttp3 .internal .framed . FrameReader.Handler
The peer tells us to stop creating streams.
goAway(int, ErrorCode, byte[]) - Method in interface okhttp3 .internal .framed . FrameWriter
Tell the peer to stop creating streams and that we last processed lastGoodStreamId, or zero if no streams were processed.

H

handshake() - Method in interface okhttp3 . Connection
Returns the TLS handshake used to establish this connection, or null if the connection is not HTTPS.
Handshake - Class in okhttp3
A record of a TLS handshake.
handshake() - Method in class okhttp3 .internal .io . RealConnection
 
handshake(Handshake) - Method in class okhttp3 . Response.Builder
 
handshake() - Method in class okhttp3 . Response
Returns the TLS handshake of the connection that carried this response, or null if the response was received without TLS.
hasBody(Response) - Static method in class okhttp3 .internal .http . HttpEngine
Returns true if the response must have a (possibly 0-length) body.
hashCode() - Method in class okhttp3 . Address
 
hashCode() - Method in class okhttp3 . Challenge
 
hashCode() - Method in class okhttp3 . ConnectionSpec
 
hashCode() - Method in class okhttp3 . Cookie
 
hashCode() - Method in class okhttp3 . Handshake
 
hashCode() - Method in class okhttp3 . HttpUrl
 
hashCode() - Method in class okhttp3 .internal .framed . Header
 
hashCode() - Method in class okhttp3 . MediaType
 
hashCode() - Method in class okhttp3 . Route
 
hasNext() - Method in class okhttp3 .internal .http . RouteSelector
Returns true if there's another route to attempt.
hasResponse() - Method in class okhttp3 .internal .http . HttpEngine
 
hasVaryAll(Response) - Static method in class okhttp3 .internal .http . OkHeaders
Returns true if a Vary header contains an asterisk.
hasVaryAll(Headers) - Static method in class okhttp3 .internal .http . OkHeaders
Returns true if a Vary header contains an asterisk.
head() - Method in class okhttp3 . Request.Builder
 
Header - Class in okhttp3.internal.framed
HTTP header: the name is an ASCII string, but the value can be UTF-8.
Header(String, String) - Constructor for class okhttp3 .internal .framed . Header
 
Header(ByteString, String) - Constructor for class okhttp3 .internal .framed . Header
 
Header(ByteString, ByteString) - Constructor for class okhttp3 .internal .framed . Header
 
header(String, String) - Method in class okhttp3 . Request.Builder
Sets the header named name to value.
header(String) - Method in class okhttp3 . Request
 
header(String, String) - Method in class okhttp3 . Response.Builder
Sets the header named name to value.
header(String) - Method in class okhttp3 . Response
 
header(String, String) - Method in class okhttp3 . Response
 
HeaderParser - Class in okhttp3.internal.http
 
Headers - Class in okhttp3
The header fields of a single HTTP message.
headers(boolean, boolean, int, int, List<Header>, HeadersMode) - Method in interface okhttp3 .internal .framed . FrameReader.Handler
Create or update incoming headers, creating the corresponding streams if necessary.
headers(int, List<Header>) - Method in interface okhttp3 .internal .framed . FrameWriter
 
headers(Headers) - Method in class okhttp3 . Request.Builder
Removes all headers on this builder and adds headers.
headers() - Method in class okhttp3 . Request
 
headers(String) - Method in class okhttp3 . Request
 
headers(Headers) - Method in class okhttp3 . Response.Builder
Removes all headers on this builder and adds headers.
headers(String) - Method in class okhttp3 . Response
 
headers() - Method in class okhttp3 . Response
 
Headers.Builder - Class in okhttp3
 
HeadersMode - Enum in okhttp3.internal.framed
 
hitCount() - Method in class okhttp3 . Cache
 
host(String) - Method in class okhttp3 . HttpUrl.Builder
 
host() - Method in class okhttp3 . HttpUrl
Returns the host address suitable for use with InetAddress.getAllByName(String).
hostHeader(HttpUrl, boolean) - Static method in class okhttp3 .internal . Util
 
hostnameVerifier() - Method in class okhttp3 . Address
Returns the hostname verifier, or null if this is not an HTTPS address.
hostnameVerifier(HostnameVerifier) - Method in class okhttp3 . OkHttpClient.Builder
Sets the verifier used to confirm that response certificates apply to requested hostnames for HTTPS connections.
hostnameVerifier() - Method in class okhttp3 . OkHttpClient
 
hostOnly() - Method in class okhttp3 . Cookie
Returns true if this cookie's domain should be interpreted as a single host name, or false if it should be interpreted as a pattern.
hostOnlyDomain(String) - Method in class okhttp3 . Cookie.Builder
Set the host-only domain for this cookie.
Http1xStream - Class in okhttp3.internal.http
A socket connection that can be used to send HTTP/1.1 messages.
Http1xStream(StreamAllocation, BufferedSource, BufferedSink) - Constructor for class okhttp3 .internal .http . Http1xStream
 
Http2 - Class in okhttp3.internal.framed
Read and write HTTP/2 frames.
Http2() - Constructor for class okhttp3 .internal .framed . Http2
 
http2HeadersList(Request) - Static method in class okhttp3 .internal .http . Http2xStream
 
Http2xStream - Class in okhttp3.internal.http
An HTTP stream for HTTP/2 and SPDY.
Http2xStream(StreamAllocation, FramedConnection) - Constructor for class okhttp3 .internal .http . Http2xStream
 
HTTP_CONTINUE - Static variable in class okhttp3 .internal .http . StatusLine
 
HTTP_PERM_REDIRECT - Static variable in class okhttp3 .internal .http . StatusLine
 
HTTP_TEMP_REDIRECT - Static variable in class okhttp3 .internal .http . StatusLine
Numeric status code, 307: Temporary Redirect.
httpCode - Variable in enum okhttp3 .internal .framed . ErrorCode
 
HttpDate - Class in okhttp3.internal.http
Best-effort parser for HTTP dates.
HttpEngine - Class in okhttp3.internal.http
Handles a single HTTP request/response pair.
HttpEngine(OkHttpClient, Request, boolean, boolean, boolean, StreamAllocation, RetryableSink, Response) - Constructor for class okhttp3 .internal .http . HttpEngine
 
HttpMethod - Class in okhttp3.internal.http
 
httpOnly() - Method in class okhttp3 . Cookie.Builder
 
httpOnly() - Method in class okhttp3 . Cookie
Returns true if this cookie should be limited to only HTTP APIs.
HttpStream - Interface in okhttp3.internal.http
 
HttpUrl - Class in okhttp3
A uniform resource locator (URL) with a scheme of either http or https.
HttpUrl.Builder - Class in okhttp3
 

I

idleAtNanos - Variable in class okhttp3 .internal .io . RealConnection
 
idleConnectionCount() - Method in class okhttp3 . ConnectionPool
Returns the number of idle connections in the pool.
immutableList(List<T>) - Static method in class okhttp3 .internal . Util
Returns an immutable copy of list.
immutableList(T...) - Static method in class okhttp3 .internal . Util
Returns an immutable list containing elements.
immutableMap(Map<K, V>) - Static method in class okhttp3 .internal . Util
Returns an immutable copy of map.
initialize() - Method in class okhttp3 . Cache
Initialize the cache.
initialize() - Method in class okhttp3 .internal . DiskLruCache
 
initializeInstanceForTests() - Static method in class okhttp3 .internal . Internal
 
instance - Static variable in class okhttp3 .internal . Internal
 
INSTANCE - Static variable in class okhttp3 .internal .tls . OkHostnameVerifier
 
intercept(Interceptor.Chain) - Method in interface okhttp3 . Interceptor
 
Interceptor - Interface in okhttp3
Observes, modifies, and potentially short-circuits requests going out and the corresponding requests coming back in.
Interceptor.Chain - Interface in okhttp3
 
interceptors() - Method in class okhttp3 . OkHttpClient.Builder
Returns a modifiable list of interceptors that observe the full span of each call: from before the connection is established (if any) until after the response source is selected (either the origin server, cache, or both).
interceptors() - Method in class okhttp3 . OkHttpClient
Returns an immutable list of interceptors that observe the full span of each call: from before the connection is established (if any) until after the response source is selected (either the origin server, cache, or both).
Internal - Class in okhttp3.internal
Escalate internal APIs in okhttp3 so they can be used from OkHttp's implementation packages.
Internal() - Constructor for class okhttp3 .internal . Internal
 
internalCache(OkHttpClient) - Method in class okhttp3 .internal . Internal
 
InternalCache - Interface in okhttp3.internal
OkHttp's internal cache interface.
intersect(Class<T>, T[], T[]) - Static method in class okhttp3 .internal . Util
Returns an array containing containing only elements found in first and also in second.
invalidatesCache(String) - Static method in class okhttp3 .internal .http . HttpMethod
 
isAndroidGetsocknameError(AssertionError) - Static method in class okhttp3 .internal . Util
Returns true if e is due to a firmware bug fixed after Android 4.2.2.
isCacheable(Response, Request) - Static method in class okhttp3 .internal .http . CacheStrategy
Returns true if response can be stored to later serve another request.
isCanceled() - Method in interface okhttp3 . Call
 
isClosed() - Method in class okhttp3 . Cache
 
isClosed() - Method in class okhttp3 .internal . DiskLruCache
Returns true if this cache has been closed.
isClosed() - Method in class okhttp3 .internal .http . Http1xStream
Returns true if this connection is closed.
isCompatible(SSLSocket) - Method in class okhttp3 . ConnectionSpec
Returns true if the socket, as currently configured, supports this connection spec.
isExecuted() - Method in interface okhttp3 . Call
Returns true if this call has been either executed or enqueued.
isHealthy(boolean) - Method in class okhttp3 .internal .io . RealConnection
Returns true if this connection is ready to host new streams.
isHttps() - Method in class okhttp3 . HttpUrl
 
isHttps() - Method in class okhttp3 . Request
 
isIdle() - Method in class okhttp3 .internal .framed . FramedConnection
Returns true if this connection is idle.
isLocallyInitiated() - Method in class okhttp3 .internal .framed . FramedStream
Returns true if this stream was created by this peer.
isMultiplexed() - Method in class okhttp3 .internal .io . RealConnection
Returns true if this is a SPDY connection.
isOpen() - Method in class okhttp3 .internal .framed . FramedStream
Returns true if this stream is open.
isPrivate() - Method in class okhttp3 . CacheControl
 
isPublic() - Method in class okhttp3 . CacheControl
 
isRedirect() - Method in class okhttp3 . Response
Returns true if this response redirects to another resource.
isSuccessful() - Method in class okhttp3 . Response
Returns true if the code is in [200..300), which means the request was successfully received, understood, and accepted.
isTls() - Method in class okhttp3 . ConnectionSpec
 

J

javaName() - Method in enum okhttp3 . CipherSuite
Returns the Java name of this cipher suite.
javaName() - Method in enum okhttp3 . TlsVersion
 

K

key() - Method in class okhttp3 .internal . DiskLruCache.Snapshot
 

L

listener(FramedConnection.Listener) - Method in class okhttp3 .internal .framed . FramedConnection.Builder
 
Listener() - Constructor for class okhttp3 .internal .framed . FramedConnection.Listener
 
loadForRequest(HttpUrl) - Method in interface okhttp3 . CookieJar
Load cookies from the jar for an HTTP request to url.
localCertificates() - Method in class okhttp3 . Handshake
Returns a possibly-empty list of certificates that identify this peer.
localPrincipal() - Method in class okhttp3 . Handshake
Returns the local principle, or null if this peer is anonymous.
log(String) - Method in class okhttp3 .internal . Platform
 
logger - Static variable in class okhttp3 .internal . Internal
 
logW(String) - Method in class okhttp3 .internal . Platform
 
lookup(String) - Method in interface okhttp3 . Dns
Returns the IP addresses of hostname, in the order they will be attempted by OkHttp.

M

matches(HttpUrl) - Method in class okhttp3 . Cookie
Returns true if this cookie should be included on a request to url.
MAX_DATE - Static variable in class okhttp3 .internal .http . HttpDate
The last four-digit year: "Fri, 31 Dec 9999 23:59:59 GMT".
MAX_FOLLOW_UPS - Static variable in class okhttp3 .internal .http . HttpEngine
How many redirects and auth challenges should we attempt? Chrome follows 21 redirects; Firefox, curl, and wget follow 20; Safari follows 16; and HTTP/1.0 recommends 5.
maxAge(int, TimeUnit) - Method in class okhttp3 . CacheControl.Builder
Sets the maximum age of a cached response.
maxAgeSeconds() - Method in class okhttp3 . CacheControl
The duration past the response's served date that it can be served without validation.
maxConcurrentStreams() - Method in class okhttp3 .internal .framed . FramedConnection
 
maxDataLength() - Method in interface okhttp3 .internal .framed . FrameWriter
The maximum size of bytes that may be sent in a single call to FrameWriter.data(boolean, int, okio.Buffer, int).
maxSize() - Method in class okhttp3 . Cache
 
maxStale(int, TimeUnit) - Method in class okhttp3 . CacheControl.Builder
Accept cached responses that have exceeded their freshness lifetime by up to maxStale.
maxStaleSeconds() - Method in class okhttp3 . CacheControl
 
md5Hex(String) - Static method in class okhttp3 .internal . Util
Returns a 32 character string containing an MD5 hash of s.
MediaType - Class in okhttp3
An RFC 2045 Media Type, appropriate to describe the content type of an HTTP request or response body.
message - Variable in class okhttp3 .internal .http . StatusLine
 
message(String) - Method in class okhttp3 . Response.Builder
 
message() - Method in class okhttp3 . Response
Returns the HTTP status message or null if it is unknown.
method(String, RequestBody) - Method in class okhttp3 . Request.Builder
 
method() - Method in class okhttp3 . Request
 
minFresh(int, TimeUnit) - Method in class okhttp3 . CacheControl.Builder
Sets the minimum number of seconds that a response will continue to be fresh for.
minFreshSeconds() - Method in class okhttp3 . CacheControl
 
MIXED - Static variable in class okhttp3 . MultipartBody
The "mixed" subtype of "multipart" is intended for use when the body parts are independent and need to be bundled in a particular order.
MODERN_TLS - Static variable in class okhttp3 . ConnectionSpec
A modern TLS connection with extensions like SNI and ALPN available.
MultipartBody - Class in okhttp3
An RFC 2387-compliant request body.
MultipartBody.Builder - Class in okhttp3
 
MultipartBody.Part - Class in okhttp3
 
mustRevalidate() - Method in class okhttp3 . CacheControl
 

N

name(String) - Method in class okhttp3 . Cookie.Builder
 
name() - Method in class okhttp3 . Cookie
Returns a non-empty string with this cookie's name.
name(int) - Method in class okhttp3 . FormBody
 
name(int) - Method in class okhttp3 . Headers
Returns the field at position.
name - Variable in class okhttp3 .internal .framed . Header
Name in case-insensitive ASCII encoding.
name - Variable in class okhttp3 .internal . NamedRunnable
 
NamedRunnable - Class in okhttp3.internal
Runnable implementation which always sets its thread name.
NamedRunnable(String, Object...) - Constructor for class okhttp3 .internal . NamedRunnable
 
names() - Method in class okhttp3 . Headers
Returns an immutable case-insensitive set of header names.
networkCount() - Method in class okhttp3 . Cache
 
networkInterceptors() - Method in class okhttp3 . OkHttpClient.Builder
Returns a modifiable list of interceptors that observe a single network request and response.
networkInterceptors() - Method in class okhttp3 . OkHttpClient
Returns an immutable list of interceptors that observe a single network request and response.
networkRequest - Variable in class okhttp3 .internal .http . CacheStrategy
The request to send on the network, or null if this call doesn't use the network.
networkResponse(Response) - Method in class okhttp3 . Response.Builder
 
networkResponse() - Method in class okhttp3 . Response
Returns the raw response received from the network.
newBuilder() - Method in class okhttp3 . Headers
 
newBuilder() - Method in class okhttp3 . HttpUrl
 
newBuilder(String) - Method in class okhttp3 . HttpUrl
Returns a builder for the URL that would be retrieved by following link from this URL, or null if the resulting URL is not well-formed.
newBuilder() - Method in class okhttp3 . OkHttpClient
 
newBuilder() - Method in class okhttp3 . Request
 
newBuilder() - Method in class okhttp3 . Response
 
newCall(Request) - Method in interface okhttp3 . Call.Factory
 
newCall(Request) - Method in class okhttp3 . OkHttpClient
Prepares the request to be executed at some point in the future.
newChunkedSink() - Method in class okhttp3 .internal .http . Http1xStream
 
newChunkedSource(HttpEngine) - Method in class okhttp3 .internal .http . Http1xStream
 
newFixedLengthSink(long) - Method in class okhttp3 .internal .http . Http1xStream
 
newFixedLengthSource(long) - Method in class okhttp3 .internal .http . Http1xStream
 
newReader(BufferedSource, boolean) - Method in class okhttp3 .internal .framed . Http2
Creates a frame reader with max header table size of 4096 and data frame compression disabled.
newReader(BufferedSource, boolean) - Method in class okhttp3 .internal .framed . Spdy3
 
newReader(BufferedSource, boolean) - Method in interface okhttp3 .internal .framed . Variant
 
newSink(int) - Method in class okhttp3 .internal . DiskLruCache.Editor
Returns a new unbuffered output stream to write the value at index.
newSource(int) - Method in class okhttp3 .internal . DiskLruCache.Editor
Returns an unbuffered input stream to read the last committed value, or null if no value has been committed.
newStream(List<Header>, boolean, boolean) - Method in class okhttp3 .internal .framed . FramedConnection
Returns a new locally-initiated stream.
newStream(int, int, int, boolean, boolean) - Method in class okhttp3 .internal .http . StreamAllocation
 
newUnknownLengthSource() - Method in class okhttp3 .internal .http . Http1xStream
 
newWriter(BufferedSink, boolean) - Method in class okhttp3 .internal .framed . Http2
 
newWriter(BufferedSink, boolean) - Method in class okhttp3 .internal .framed . Spdy3
 
newWriter(BufferedSink, boolean) - Method in interface okhttp3 .internal .framed . Variant
 
next() - Method in class okhttp3 .internal .http . RouteSelector
 
nextFrame(FrameReader.Handler) - Method in interface okhttp3 .internal .framed . FrameReader
 
NO_COOKIES - Static variable in interface okhttp3 . CookieJar
A cookie jar that never accepts any cookies.
noCache() - Method in class okhttp3 . CacheControl.Builder
Don't accept an unvalidated cached response.
noCache() - Method in class okhttp3 . CacheControl
In a response, this field's name "no-cache" is misleading.
NONE - Static variable in interface okhttp3 . Authenticator
An authenticator that knows no credentials and makes no attempt to authenticate.
noNewStreams() - Method in class okhttp3 .internal .http . StreamAllocation
Forbid new streams from being created on the connection that hosts this allocation.
noNewStreams - Variable in class okhttp3 .internal .io . RealConnection
 
noStore() - Method in class okhttp3 . CacheControl.Builder
Don't store the server's response in any cache.
noStore() - Method in class okhttp3 . CacheControl
If true, this response should not be cached.
noTransform() - Method in class okhttp3 . CacheControl.Builder
Don't accept a transformed response.
noTransform() - Method in class okhttp3 . CacheControl
 

O

of(String...) - Static method in class okhttp3 . Headers
Returns headers for the alternating header names and values.
of(Map<String, String>) - Static method in class okhttp3 . Headers
Returns headers for the header names and values in the Map.
OkHeaders - Class in okhttp3.internal.http
Headers and utilities for internal use by OkHttp.
OkHostnameVerifier - Class in okhttp3.internal.tls
A HostnameVerifier consistent with RFC 2818.
okhttp3 - package okhttp3
 
okhttp3.internal - package okhttp3.internal
 
okhttp3.internal.framed - package okhttp3.internal.framed
 
okhttp3.internal.http - package okhttp3.internal.http
 
okhttp3.internal.io - package okhttp3.internal.io
 
okhttp3.internal.tls - package okhttp3.internal.tls
 
OkHttpClient - Class in okhttp3
Factory for calls, which can be used to send HTTP requests and read their responses.
OkHttpClient() - Constructor for class okhttp3 . OkHttpClient
 
OkHttpClient.Builder - Class in okhttp3
 
onData(int, BufferedSource, int, boolean) - Method in interface okhttp3 .internal .framed . PushObserver
A chunk of response data corresponding to a pushed request.
onFailure(Call, IOException) - Method in interface okhttp3 . Callback
Called when the request could not be executed due to cancellation, a connectivity problem or timeout.
onHeaders(int, List<Header>, boolean) - Method in interface okhttp3 .internal .framed . PushObserver
The response headers corresponding to a pushed request.
onlyIfCached() - Method in class okhttp3 . CacheControl.Builder
Only accept the response if it is in the cache.
onlyIfCached() - Method in class okhttp3 . CacheControl
This field's name "only-if-cached" is misleading.
onRequest(int, List<Header>) - Method in interface okhttp3 .internal .framed . PushObserver
Describes the request that the server intends to push a response for.
onReset(int, ErrorCode) - Method in interface okhttp3 .internal .framed . PushObserver
Indicates the reason why this stream was canceled.
onResponse(Call, Response) - Method in interface okhttp3 . Callback
Called when the HTTP response was successfully returned by the remote server.
onSettings(FramedConnection) - Method in class okhttp3 .internal .framed . FramedConnection.Listener
Notification that the connection's peer's settings may have changed.
onSettings(FramedConnection) - Method in class okhttp3 .internal .io . RealConnection
When settings are received, adjust the allocation limit.
onStream(FramedStream) - Method in class okhttp3 .internal .framed . FramedConnection.Listener
Handle a new stream from this connection's peer.
onStream(FramedStream) - Method in class okhttp3 .internal .io . RealConnection
Refuse incoming streams.
openResponseBody(Response) - Method in class okhttp3 .internal .http . Http1xStream
 
openResponseBody(Response) - Method in class okhttp3 .internal .http . Http2xStream
 
openResponseBody(Response) - Method in interface okhttp3 .internal .http . HttpStream
Returns a stream that reads the response body.
openStreamCount() - Method in class okhttp3 .internal .framed . FramedConnection
Returns the number of open streams on this connection.

P

PARALLEL - Static variable in class okhttp3 . MultipartBody
This type is syntactically identical to "multipart/mixed", but the semantics are different.
parse(Headers) - Static method in class okhttp3 . CacheControl
Returns the cache directives of headers.
parse(HttpUrl, String) - Static method in class okhttp3 . Cookie
Attempt to parse a Set-Cookie HTTP header value setCookie as a cookie.
parse(String) - Static method in class okhttp3 . HttpUrl
Returns a new HttpUrl representing url if it is a well-formed HTTP or HTTPS URL, or null if it isn't.
parse(String) - Static method in class okhttp3 .internal .http . HttpDate
Returns the date for value.
parse(String) - Static method in class okhttp3 .internal .http . StatusLine
 
parse(String) - Static method in class okhttp3 . MediaType
Returns a media type for string, or null if string is not a well-formed media type.
parseAll(HttpUrl, Headers) - Static method in class okhttp3 . Cookie
Returns all of the cookies from a set of HTTP response headers.
parseChallenges(Headers, String) - Static method in class okhttp3 .internal .http . OkHeaders
Parse RFC 2617 challenges.
parseSeconds(String, int) - Static method in class okhttp3 .internal .http . HeaderParser
Returns value as a positive integer, or 0 if it is negative, or defaultValue if it cannot be parsed.
part(int) - Method in class okhttp3 . MultipartBody
 
parts() - Method in class okhttp3 . MultipartBody
 
password(String) - Method in class okhttp3 . HttpUrl.Builder
 
password() - Method in class okhttp3 . HttpUrl
Returns the decoded password, or an empty string if none is present.
patch(RequestBody) - Method in class okhttp3 . Request.Builder
 
path(String) - Method in class okhttp3 . Cookie.Builder
 
path() - Method in class okhttp3 . Cookie
Returns this cookie's path.
pathSegments() - Method in class okhttp3 . HttpUrl
 
pathSize() - Method in class okhttp3 . HttpUrl
 
peekBody(long) - Method in class okhttp3 . Response
Peeks up to byteCount bytes from the response body and returns them as a new response body.
peerCertificates() - Method in class okhttp3 . Handshake
Returns a possibly-empty list of certificates that identify the remote peer.
peerPrincipal() - Method in class okhttp3 . Handshake
Returns the remote peer's principle, or null if that peer is anonymous.
permitsRequestBody(String) - Static method in class okhttp3 .internal .http . HttpMethod
 
persistent() - Method in class okhttp3 . Cookie
Returns true if this cookie expires at the end of the current session.
pin(Certificate) - Static method in class okhttp3 . CertificatePinner
Returns the SHA-256 of certificate's public key.
ping() - Method in class okhttp3 .internal .framed . FramedConnection
Sends a ping frame to the peer.
ping(boolean, int, int) - Method in interface okhttp3 .internal .framed . FrameReader.Handler
Read a connection-level ping from the peer.
ping(boolean, int, int) - Method in interface okhttp3 .internal .framed . FrameWriter
Send a connection-level ping to the peer.
Ping - Class in okhttp3.internal.framed
A locally-originated ping.
Platform - Class in okhttp3.internal
Access to platform-specific features.
Platform() - Constructor for class okhttp3 .internal . Platform
 
port(int) - Method in class okhttp3 . HttpUrl.Builder
 
port() - Method in class okhttp3 . HttpUrl
Returns the explicitly-specified port if one was provided, or the default port for this URL's scheme.
post(RequestBody) - Method in class okhttp3 . Request.Builder
 
priority(int, int, int, boolean) - Method in interface okhttp3 .internal .framed . FrameReader.Handler
Called when reading a headers or priority frame.
priorResponse(Response) - Method in class okhttp3 . Response.Builder
 
priorResponse() - Method in class okhttp3 . Response
Returns the response for the HTTP redirect or authorization challenge that triggered this response, or null if this response wasn't triggered by an automatic retry.
proceed(Request) - Method in interface okhttp3 . Interceptor.Chain
 
protocol() - Method in interface okhttp3 . Connection
Returns the protocol negotiated by this connection, or Protocol.HTTP_1_1 if no protocol has been negotiated.
protocol(Protocol) - Method in class okhttp3 .internal .framed . FramedConnection.Builder
 
protocol - Variable in class okhttp3 .internal .http . StatusLine
 
protocol() - Method in class okhttp3 .internal .io . RealConnection
 
Protocol - Enum in okhttp3
Protocols that OkHttp implements for ALPN selection.
protocol(Protocol) - Method in class okhttp3 . Response.Builder
 
protocol() - Method in class okhttp3 . Response
Returns the HTTP protocol, such as Protocol.HTTP_1_1 or Protocol.HTTP_1_0.
protocols() - Method in class okhttp3 . Address
Returns the protocols the client supports.
protocols(List<Protocol>) - Method in class okhttp3 . OkHttpClient.Builder
Configure the protocols used by this client to communicate with remote servers.
protocols() - Method in class okhttp3 . OkHttpClient
 
proxy() - Method in class okhttp3 . Address
Returns this address's explicitly-specified HTTP proxy, or null to delegate to the proxy selector.
proxy(Proxy) - Method in class okhttp3 . OkHttpClient.Builder
Sets the HTTP proxy that will be used by connections created by this client.
proxy() - Method in class okhttp3 . OkHttpClient
 
proxy() - Method in class okhttp3 . Route
Returns the Proxy of this route.
proxyAuthenticator() - Method in class okhttp3 . Address
Returns the client's proxy authenticator.
proxyAuthenticator(Authenticator) - Method in class okhttp3 . OkHttpClient.Builder
Sets the authenticator used to respond to challenges from proxy servers.
proxyAuthenticator() - Method in class okhttp3 . OkHttpClient
 
proxySelector() - Method in class okhttp3 . Address
Returns this address's proxy selector.
proxySelector(ProxySelector) - Method in class okhttp3 . OkHttpClient.Builder
Sets the proxy selection policy to be used if no proxy is specified explicitly.
proxySelector() - Method in class okhttp3 . OkHttpClient
 
pushObserver(PushObserver) - Method in class okhttp3 .internal .framed . FramedConnection.Builder
 
PushObserver - Interface in okhttp3.internal.framed
HTTP/2 only.
pushPromise(int, int, List<Header>) - Method in interface okhttp3 .internal .framed . FrameReader.Handler
HTTP/2 only.
pushPromise(int, int, List<Header>) - Method in interface okhttp3 .internal .framed . FrameWriter
HTTP/2 only.
pushStream(int, List<Header>, boolean) - Method in class okhttp3 .internal .framed . FramedConnection
Returns a new server-initiated stream.
put(ConnectionPool, RealConnection) - Method in class okhttp3 .internal . Internal
 
put(Response) - Method in interface okhttp3 .internal . InternalCache
 
put(RequestBody) - Method in class okhttp3 . Request.Builder
 

Q

query(String) - Method in class okhttp3 . HttpUrl.Builder
 
query() - Method in class okhttp3 . HttpUrl
 
queryParameter(String) - Method in class okhttp3 . HttpUrl
Returns the first query parameter named name decoded using UTF-8, or null if there is no such query parameter.
queryParameterName(int) - Method in class okhttp3 . HttpUrl
 
queryParameterNames() - Method in class okhttp3 . HttpUrl
 
queryParameterValue(int) - Method in class okhttp3 . HttpUrl
 
queryParameterValues(String) - Method in class okhttp3 . HttpUrl
 
querySize() - Method in class okhttp3 . HttpUrl
 
queuedCalls() - Method in class okhttp3 . Dispatcher
Returns a snapshot of the calls currently awaiting execution.
queuedCallsCount() - Method in class okhttp3 . Dispatcher
 

R

readConnectionPreface() - Method in interface okhttp3 .internal .framed . FrameReader
 
readHeaders() - Method in class okhttp3 .internal .http . Http1xStream
Reads headers or trailers.
readHttp2HeadersList(List<Header>) - Static method in class okhttp3 .internal .http . Http2xStream
Returns headers for a name value block containing an HTTP/2 response.
readResponse() - Method in class okhttp3 .internal .http . Http1xStream
Parses bytes of a response header from an HTTP transport.
readResponse() - Method in class okhttp3 .internal .http . HttpEngine
Flushes the remaining request header and body, parses the HTTP response headers and starts reading the HTTP response body if it exists.
readResponseHeaders() - Method in class okhttp3 .internal .http . Http1xStream
 
readResponseHeaders() - Method in class okhttp3 .internal .http . Http2xStream
 
readResponseHeaders() - Method in interface okhttp3 .internal .http . HttpStream
Read and return response headers.
readSpdy3HeadersList(List<Header>) - Static method in class okhttp3 .internal .http . Http2xStream
Returns headers for a name value block containing a SPDY response.
readTimeout() - Method in class okhttp3 .internal .framed . FramedStream
 
readTimeout(long, TimeUnit) - Method in class okhttp3 . OkHttpClient.Builder
Sets the default read timeout for new connections.
readTimeoutMillis() - Method in class okhttp3 . OkHttpClient
Default read timeout (in milliseconds).
RealConnection - Class in okhttp3.internal.io
 
RealConnection(Route) - Constructor for class okhttp3 .internal .io . RealConnection
 
realm() - Method in class okhttp3 . Challenge
Returns the protection space.
RealResponseBody - Class in okhttp3.internal.http
 
RealResponseBody(Headers, BufferedSource) - Constructor for class okhttp3 .internal .http . RealResponseBody
 
RealTrustRootIndex - Class in okhttp3.internal.tls
 
RealTrustRootIndex(X509Certificate...) - Constructor for class okhttp3 .internal .tls . RealTrustRootIndex
 
RECEIVED_MILLIS - Static variable in class okhttp3 .internal .http . OkHeaders
Synthetic response header: the local time when the response was received.
receiveHeaders(Headers) - Method in class okhttp3 .internal .http . HttpEngine
 
recover(IOException, Sink) - Method in class okhttp3 .internal .http . HttpEngine
Report and attempt to recover from a failure to communicate with a server.
recover(IOException) - Method in class okhttp3 .internal .http . HttpEngine
 
recover(IOException, Sink) - Method in class okhttp3 .internal .http . StreamAllocation
 
redirectsToGet(String) - Static method in class okhttp3 .internal .http . HttpMethod
 
REFUSE_INCOMING_STREAMS - Static variable in class okhttp3 .internal .framed . FramedConnection.Listener
 
release() - Method in class okhttp3 .internal .http . StreamAllocation
 
releaseStreamAllocation() - Method in class okhttp3 .internal .http . HttpEngine
Configure the socket connection to be either pooled or closed when it is either exhausted or closed.
remove(String) - Method in class okhttp3 .internal . DiskLruCache
Drops the entry for key if it exists and can be removed.
remove(Request) - Method in interface okhttp3 .internal . InternalCache
Remove any cache entries for the supplied request.
removeAll(String) - Method in class okhttp3 . Headers.Builder
 
removeAllEncodedQueryParameters(String) - Method in class okhttp3 . HttpUrl.Builder
 
removeAllQueryParameters(String) - Method in class okhttp3 . HttpUrl.Builder
 
removeHeader(String) - Method in class okhttp3 . Request.Builder
 
removeHeader(String) - Method in class okhttp3 . Response.Builder
 
removePathSegment(int) - Method in class okhttp3 . HttpUrl.Builder
 
rename(File, File) - Method in interface okhttp3 .internal .io . FileSystem
Renames from to to.
reply(List<Header>, boolean) - Method in class okhttp3 .internal .framed . FramedStream
Sends a reply to an incoming stream.
request() - Method in interface okhttp3 . Call
Returns the original request that initiated this call.
request() - Method in interface okhttp3 . Interceptor.Chain
 
Request - Class in okhttp3
An HTTP request.
request(Request) - Method in class okhttp3 . Response.Builder
 
request() - Method in class okhttp3 . Response
The wire-level request that initiated this HTTP response.
Request.Builder - Class in okhttp3
 
RequestBody - Class in okhttp3
 
RequestBody() - Constructor for class okhttp3 . RequestBody
 
requestCount() - Method in class okhttp3 . Cache
 
RequestException - Exception in okhttp3.internal.http
Indicates a problem with interpreting a request.
RequestException(IOException) - Constructor for exception okhttp3 .internal .http . RequestException
 
RequestLine - Class in okhttp3.internal.http
 
requestPath(HttpUrl) - Static method in class okhttp3 .internal .http . RequestLine
Returns the path to request, like the '/' in 'GET / HTTP/1.1'.
requiresRequestBody(String) - Static method in class okhttp3 .internal .http . HttpMethod
 
requiresTunnel() - Method in class okhttp3 . Route
Returns true if this route tunnels HTTPS through an HTTP proxy.
resolve(String) - Method in class okhttp3 . HttpUrl
Returns the URL that would be retrieved by following link from this URL, or null if the resulting URL is not well-formed.
Response - Class in okhttp3
An HTTP response.
Response.Builder - Class in okhttp3
 
RESPONSE_SOURCE - Static variable in class okhttp3 .internal .http . OkHeaders
Synthetic response header: the location from which the response was loaded.
RESPONSE_STATUS - Static variable in class okhttp3 .internal .framed . Header
 
ResponseBody - Class in okhttp3
A one-shot stream from the origin server to the client application with the raw bytes of the response body.
ResponseBody() - Constructor for class okhttp3 . ResponseBody
 
RetryableSink - Class in okhttp3.internal.http
An HTTP request body that's completely buffered in memory.
RetryableSink(int) - Constructor for class okhttp3 .internal .http . RetryableSink
 
RetryableSink() - Constructor for class okhttp3 .internal .http . RetryableSink
 
retryOnConnectionFailure(boolean) - Method in class okhttp3 . OkHttpClient.Builder
Configure this client to retry or not when a connectivity problem is encountered.
retryOnConnectionFailure() - Method in class okhttp3 . OkHttpClient
 
roundTripTime() - Method in class okhttp3 .internal .framed . Ping
Returns the round trip time for this ping in nanoseconds, waiting for the response to arrive if necessary.
roundTripTime(long, TimeUnit) - Method in class okhttp3 .internal .framed . Ping
Returns the round trip time for this ping in nanoseconds, or -1 if the response was canceled, or -2 if the timeout elapsed before the round trip completed.
route() - Method in interface okhttp3 . Connection
Returns the route used by this connection.
route() - Method in class okhttp3 .internal .io . RealConnection
 
Route - Class in okhttp3
The concrete route used by a connection to reach an abstract origin server.
Route(Address, Proxy, InetSocketAddress) - Constructor for class okhttp3 . Route
 
routeDatabase(ConnectionPool) - Method in class okhttp3 .internal . Internal
 
RouteDatabase - Class in okhttp3.internal
A blacklist of failed routes to avoid when creating a new connection to a target address.
RouteDatabase() - Constructor for class okhttp3 .internal . RouteDatabase
 
RouteException - Exception in okhttp3.internal.http
An exception thrown to indicate a problem connecting via a single Route.
RouteException(IOException) - Constructor for exception okhttp3 .internal .http . RouteException
 
RouteSelector - Class in okhttp3.internal.http
Selects routes to connect to an origin server.
RouteSelector(Address, RouteDatabase) - Constructor for class okhttp3 .internal .http . RouteSelector
 
rstStream(int, ErrorCode) - Method in interface okhttp3 .internal .framed . FrameReader.Handler
 
rstStream(int, ErrorCode) - Method in interface okhttp3 .internal .framed . FrameWriter
 
run() - Method in class okhttp3 .internal . NamedRunnable
 
runningCalls() - Method in class okhttp3 . Dispatcher
Returns a snapshot of the calls currently being executed.
runningCallsCount() - Method in class okhttp3 . Dispatcher
 

S

sameConnection(HttpUrl) - Method in class okhttp3 .internal .http . HttpEngine
Returns true if an HTTP request for followUp can reuse the connection used by this engine.
saveFromResponse(HttpUrl, List<Cookie>) - Method in interface okhttp3 . CookieJar
Saves cookies from an HTTP response to this store according to this jar's policy.
scheme() - Method in class okhttp3 . Challenge
Returns the authentication scheme, like Basic.
scheme(String) - Method in class okhttp3 . HttpUrl.Builder
 
scheme() - Method in class okhttp3 . HttpUrl
Returns either "http" or "https".
secure() - Method in class okhttp3 . Cookie.Builder
 
secure() - Method in class okhttp3 . Cookie
Returns true if this cookie should be limited to only HTTPS requests.
SELECTED_PROTOCOL - Static variable in class okhttp3 .internal .http . OkHeaders
Synthetic response header: the selected protocol ("spdy/3.1", "http/1.1", etc).
sendConnectionPreface() - Method in class okhttp3 .internal .framed . FramedConnection
Sends a connection header if the current variant requires it.
sendRequest() - Method in class okhttp3 .internal .http . HttpEngine
Figures out what the response source will be, and opens a socket to that source if necessary.
SENT_MILLIS - Static variable in class okhttp3 .internal .http . OkHeaders
Synthetic response header: the local time when the request was sent.
set(String, String) - Method in class okhttp3 . Headers.Builder
Set a field with the specified value.
setCache(OkHttpClient.Builder, InternalCache) - Method in class okhttp3 .internal . Internal
 
setEncodedPathSegment(int, String) - Method in class okhttp3 . HttpUrl.Builder
 
setEncodedQueryParameter(String, String) - Method in class okhttp3 . HttpUrl.Builder
 
setHttpEngine(HttpEngine) - Method in class okhttp3 .internal .http . Http1xStream
 
setHttpEngine(HttpEngine) - Method in class okhttp3 .internal .http . Http2xStream
 
setHttpEngine(HttpEngine) - Method in interface okhttp3 .internal .http . HttpStream
 
setMaxRequests(int) - Method in class okhttp3 . Dispatcher
Set the maximum number of requests to execute concurrently.
setMaxRequestsPerHost(int) - Method in class okhttp3 . Dispatcher
Set the maximum number of requests for each host to execute concurrently.
setMaxSize(long) - Method in class okhttp3 .internal . DiskLruCache
Changes the maximum number of bytes the cache can store and queues a job to trim the existing store, if necessary.
setPathSegment(int, String) - Method in class okhttp3 . HttpUrl.Builder
 
setQueryParameter(String, String) - Method in class okhttp3 . HttpUrl.Builder
 
setSettings(Settings) - Method in class okhttp3 .internal .framed . FramedConnection
Merges settings into this peer's settings and sends them to the remote peer.
settings(boolean, Settings) - Method in interface okhttp3 .internal .framed . FrameReader.Handler
 
settings(Settings) - Method in interface okhttp3 .internal .framed . FrameWriter
Write okhttp's settings to the peer.
Settings - Class in okhttp3.internal.framed
Settings describe characteristics of the sending peer, which are used by the receiving peer.
Settings() - Constructor for class okhttp3 .internal .framed . Settings
 
setType(MediaType) - Method in class okhttp3 . MultipartBody.Builder
Set the MIME type.
sha1(ByteString) - Static method in class okhttp3 .internal . Util
Returns a SHA-1 hash of s.
sha256(ByteString) - Static method in class okhttp3 .internal . Util
Returns a SHA-256 hash of s.
shaBase64(String) - Static method in class okhttp3 .internal . Util
Returns a Base 64-encoded string containing a SHA-1 hash of s.
shouldPostpone(Route) - Method in class okhttp3 .internal . RouteDatabase
Returns true if route has failed recently and should be avoided.
shutdown(ErrorCode) - Method in class okhttp3 .internal .framed . FramedConnection
Degrades this connection such that new streams can neither be created locally, nor accepted from the remote peer.
sink(File) - Method in interface okhttp3 .internal .io . FileSystem
Writes to file, discarding any data already present.
sink - Variable in class okhttp3 .internal .io . RealConnection
 
size() - Method in class okhttp3 . Cache
 
size() - Method in class okhttp3 . FormBody
The number of key-value pairs in this form-encoded body.
size() - Method in class okhttp3 . Headers
Returns the number of field values.
size() - Method in class okhttp3 .internal . DiskLruCache
Returns the number of bytes currently being used to store the values in this cache.
size(File) - Method in interface okhttp3 .internal .io . FileSystem
Returns the number of bytes stored in file, or 0 if it does not exist.
size() - Method in class okhttp3 . MultipartBody
The number of parts in this multipart body.
skipAll(Source, int, TimeUnit) - Static method in class okhttp3 .internal . Util
Reads until in is exhausted or the deadline has been reached.
skipLeadingAsciiWhitespace(String, int, int) - Static method in class okhttp3 .internal . Util
Increments pos until input[pos] is not ASCII whitespace.
skipTrailingAsciiWhitespace(String, int, int) - Static method in class okhttp3 .internal . Util
Decrements limit until input[limit - 1] is not ASCII whitespace.
skipUntil(String, int, String) - Static method in class okhttp3 .internal .http . HeaderParser
Returns the next index in input at or after pos that contains a character from characters.
skipWhitespace(String, int) - Static method in class okhttp3 .internal .http . HeaderParser
Returns the next non-whitespace character in input that is white space.
sMaxAgeSeconds() - Method in class okhttp3 . CacheControl
The "s-maxage" directive is the max age for shared caches.
snapshots() - Method in class okhttp3 .internal . DiskLruCache
Returns an iterator over the cache's current entries.
socket() - Method in interface okhttp3 . Connection
Returns the socket that this connection is using.
socket(Socket) - Method in class okhttp3 .internal .framed . FramedConnection.Builder
 
socket(Socket, String, BufferedSource, BufferedSink) - Method in class okhttp3 .internal .framed . FramedConnection.Builder
 
socket - Variable in class okhttp3 .internal .io . RealConnection
The application layer socket.
socket() - Method in class okhttp3 .internal .io . RealConnection
 
socketAddress() - Method in class okhttp3 . Route
 
socketFactory() - Method in class okhttp3 . Address
Returns the socket factory for new connections.
socketFactory(SocketFactory) - Method in class okhttp3 . OkHttpClient.Builder
Sets the socket factory used to create connections.
socketFactory() - Method in class okhttp3 . OkHttpClient
 
source() - Method in class okhttp3 .internal .http . RealResponseBody
 
source(File) - Method in interface okhttp3 .internal .io . FileSystem
Reads from file.
source - Variable in class okhttp3 .internal .io . RealConnection
 
source() - Method in class okhttp3 . ResponseBody
 
Spdy3 - Class in okhttp3.internal.framed
Read and write spdy/3.1 frames.
Spdy3() - Constructor for class okhttp3 .internal .framed . Spdy3
 
spdy3HeadersList(Request) - Static method in class okhttp3 .internal .http . Http2xStream
Returns a list of alternating names and values containing a SPDY request.
spdyGoAwayCode - Variable in enum okhttp3 .internal .framed . ErrorCode
 
spdyRstCode - Variable in enum okhttp3 .internal .framed . ErrorCode
 
sslSocketFactory() - Method in class okhttp3 . Address
Returns the SSL socket factory, or null if this is not an HTTPS address.
sslSocketFactory(SSLSocketFactory) - Method in class okhttp3 . OkHttpClient.Builder
Sets the socket factory used to secure HTTPS connections.
sslSocketFactory() - Method in class okhttp3 . OkHttpClient
 
StatusLine - Class in okhttp3.internal.http
An HTTP response status line like "HTTP/1.1 200 OK".
StatusLine(Protocol, int, String) - Constructor for class okhttp3 .internal .http . StatusLine
 
stream() - Method in class okhttp3 .internal .http . StreamAllocation
 
streamAllocation - Variable in class okhttp3 .internal .http . HttpEngine
 
StreamAllocation - Class in okhttp3.internal.http
This class coordinates the relationship between three entities: Connections: physical socket connections to remote servers.
StreamAllocation(ConnectionPool, Address) - Constructor for class okhttp3 .internal .http . StreamAllocation
 
streamFinished(boolean, HttpStream) - Method in class okhttp3 .internal .http . StreamAllocation
 
string() - Method in class okhttp3 . ResponseBody
Returns the response as a string decoded with the charset of the Content-Type header.
subtype() - Method in class okhttp3 . MediaType
Returns a specific media subtype, such as "plain" or "png", "mpeg", "mp4" or "xml".
successCount - Variable in class okhttp3 .internal .io . RealConnection
 
supportsTlsExtensions(boolean) - Method in class okhttp3 . ConnectionSpec.Builder
 
supportsTlsExtensions() - Method in class okhttp3 . ConnectionSpec
 
synReply(boolean, int, List<Header>) - Method in interface okhttp3 .internal .framed . FrameWriter
 
synStream(boolean, boolean, int, int, List<Header>) - Method in interface okhttp3 .internal .framed . FrameWriter
 
SYSTEM - Static variable in interface okhttp3 . Dns
A DNS that uses InetAddress.getAllByName(java.lang.String) to ask the underlying operating system to lookup IP addresses.
SYSTEM - Static variable in interface okhttp3 .internal .io . FileSystem
The host machine's local file system.

T

tag(Object) - Method in class okhttp3 . Request.Builder
Attaches tag to the request.
tag() - Method in class okhttp3 . Request
 
TARGET_AUTHORITY - Static variable in class okhttp3 .internal .framed . Header
 
TARGET_HOST - Static variable in class okhttp3 .internal .framed . Header
 
TARGET_METHOD - Static variable in class okhttp3 .internal .framed . Header
 
TARGET_PATH - Static variable in class okhttp3 .internal .framed . Header
 
TARGET_SCHEME - Static variable in class okhttp3 .internal .framed . Header
 
threadFactory(String, boolean) - Static method in class okhttp3 .internal . Util
 
timeout() - Method in class okhttp3 .internal .http . RetryableSink
 
tlsVersion() - Method in class okhttp3 . Handshake
Returns the TLS version used for this connection.
TlsVersion - Enum in okhttp3
Versions of TLS that can be offered when negotiating a secure socket.
tlsVersions(TlsVersion...) - Method in class okhttp3 . ConnectionSpec.Builder
 
tlsVersions(String...) - Method in class okhttp3 . ConnectionSpec.Builder
 
tlsVersions() - Method in class okhttp3 . ConnectionSpec
Returns the TLS versions to use when negotiating a connection.
toHumanReadableAscii(String) - Static method in class okhttp3 .internal . Util
Returns s with control characters and non-ASCII characters replaced with '?'.
toMultimap() - Method in class okhttp3 . Headers
 
toString() - Method in class okhttp3 . CacheControl
 
toString() - Method in class okhttp3 . Challenge
 
toString() - Method in class okhttp3 . ConnectionSpec
 
toString() - Method in class okhttp3 . Cookie
 
toString() - Method in class okhttp3 . Headers
 
toString() - Method in class okhttp3 . HttpUrl.Builder
 
toString() - Method in class okhttp3 . HttpUrl
 
toString() - Method in class okhttp3 .internal .framed . Header
 
toString() - Method in class okhttp3 .internal .http . StatusLine
 
toString() - Method in class okhttp3 .internal .http . StreamAllocation
 
toString() - Method in class okhttp3 .internal .io . RealConnection
 
toString() - Method in class okhttp3 . MediaType
Returns the encoded media type, like "text/plain; charset=utf-8", appropriate for use in a Content-Type header.
toString() - Method in enum okhttp3 . Protocol
Returns the string used to identify this protocol for ALPN, like "http/1.1", "spdy/3.1" or "h2".
toString() - Method in class okhttp3 . Request
 
toString() - Method in class okhttp3 . Response
 
trackConditionalCacheHit() - Method in interface okhttp3 .internal . InternalCache
Track an conditional GET that was satisfied by this cache.
trackResponse(CacheStrategy) - Method in interface okhttp3 .internal . InternalCache
Track an HTTP response being satisfied with cacheStrategy.
trimSubstring(String, int, int) - Static method in class okhttp3 .internal . Util
Equivalent to string.substring(pos, limit).trim().
trustManager(SSLSocketFactory) - Method in class okhttp3 .internal . Platform
 
trustRootIndex(TrustRootIndex) - Method in class okhttp3 . CertificatePinner.Builder
 
trustRootIndex(X509TrustManager) - Method in class okhttp3 .internal . Platform
 
TrustRootIndex - Interface in okhttp3.internal.tls
 
type() - Method in class okhttp3 . MediaType
Returns the high-level media type, such as "text", "image", "audio", "video", or "application".
type() - Method in class okhttp3 . MultipartBody
 

U

update(Response, Response) - Method in interface okhttp3 .internal . InternalCache
Handles a conditional request hit by updating the stored cache response with the headers from network.
uri() - Method in class okhttp3 . HttpUrl
Returns this URL as a java.net.URI.
url() - Method in class okhttp3 . Address
Returns a URL with the hostname and port of the origin server.
url() - Method in class okhttp3 . HttpUrl
Returns this URL as a java.net.URL.
url(HttpUrl) - Method in class okhttp3 . Request.Builder
 
url(String) - Method in class okhttp3 . Request.Builder
Sets the URL target of this request.
url(URL) - Method in class okhttp3 . Request.Builder
Sets the URL target of this request.
url() - Method in class okhttp3 . Request
 
urls() - Method in class okhttp3 . Cache
Returns an iterator over the URLs in this cache.
userAgent() - Static method in class okhttp3 .internal . Version
 
username(String) - Method in class okhttp3 . HttpUrl.Builder
 
username() - Method in class okhttp3 . HttpUrl
 
UTC - Static variable in class okhttp3 .internal . Util
GMT and UTC are equivalent for our purposes.
UTF_8 - Static variable in class okhttp3 .internal . Util
A cheap and type-safe constant for the UTF-8 Charset.
Util - Class in okhttp3.internal
Junk drawer of utility methods.

V

value(String) - Method in class okhttp3 . Cookie.Builder
 
value() - Method in class okhttp3 . Cookie
Returns a possibly-empty string with this cookie's value.
value(int) - Method in class okhttp3 . FormBody
 
value(int) - Method in class okhttp3 . Headers
Returns the value at index.
value - Variable in class okhttp3 .internal .framed . Header
Value in UTF-8 encoding.
valueOf(String) - Static method in enum okhttp3 . CipherSuite
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum okhttp3 .internal .framed . ErrorCode
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum okhttp3 .internal .framed . HeadersMode
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum okhttp3 . Protocol
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum okhttp3 . TlsVersion
Returns the enum constant of this type with the specified name.
values() - Static method in enum okhttp3 . CipherSuite
Returns an array containing the constants of this enum type, in the order they are declared.
values(String) - Method in class okhttp3 . Headers
Returns an immutable list of the header values for name.
values() - Static method in enum okhttp3 .internal .framed . ErrorCode
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum okhttp3 .internal .framed . HeadersMode
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum okhttp3 . Protocol
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum okhttp3 . TlsVersion
Returns an array containing the constants of this enum type, in the order they are declared.
Variant - Interface in okhttp3.internal.framed
A version and dialect of the framed socket protocol.
varyFields(Headers) - Static method in class okhttp3 .internal .http . OkHeaders
Returns the names of the request headers that need to be checked for equality when caching.
varyHeaders(Response) - Static method in class okhttp3 .internal .http . OkHeaders
Returns the subset of the headers in response's request that impact the content of response's body.
varyHeaders(Headers, Headers) - Static method in class okhttp3 .internal .http . OkHeaders
Returns the subset of the headers in requestHeaders that impact the content of response's body.
varyMatches(Response, Headers, Request) - Static method in class okhttp3 .internal .http . OkHeaders
Returns true if none of the Vary headers have changed between cachedRequest and newRequest.
verify(String, SSLSession) - Method in class okhttp3 .internal .tls . OkHostnameVerifier
 
verify(String, X509Certificate) - Method in class okhttp3 .internal .tls . OkHostnameVerifier
 
verifyAsIpAddress(String) - Static method in class okhttp3 .internal . Util
Returns true if host is not a host name and might be an IP address.
VERSION - Static variable in class okhttp3 .internal .framed . Header
 
Version - Class in okhttp3.internal
 

W

windowUpdate(int, long) - Method in interface okhttp3 .internal .framed . FrameReader.Handler
Notifies that an additional windowSizeIncrement bytes can be sent on streamId, or the connection if streamId is zero.
windowUpdate(int, long) - Method in interface okhttp3 .internal .framed . FrameWriter
Inform peer that an additional windowSizeIncrement bytes can be sent on streamId, or the connection if streamId is zero.
write(Buffer, long) - Method in class okhttp3 .internal .http . RetryableSink
 
writeAbortCount() - Method in class okhttp3 . Cache
 
writeData(int, boolean, Buffer, long) - Method in class okhttp3 .internal .framed . FramedConnection
Callers of this method are not thread safe, and sometimes on application threads.
writeRequest(Headers, String) - Method in class okhttp3 .internal .http . Http1xStream
Returns bytes of a request header for sending on an HTTP transport.
writeRequestBody(RetryableSink) - Method in class okhttp3 .internal .http . Http1xStream
 
writeRequestBody(RetryableSink) - Method in class okhttp3 .internal .http . Http2xStream
 
writeRequestBody(RetryableSink) - Method in interface okhttp3 .internal .http . HttpStream
Sends the request body returned by HttpStream.createRequestBody(okhttp3.Request, long) to the remote peer.
writeRequestHeaders(Request) - Method in class okhttp3 .internal .http . Http1xStream
Prepares the HTTP headers and sends them to the server.
writeRequestHeaders(Request) - Method in class okhttp3 .internal .http . Http2xStream
 
writeRequestHeaders(Request) - Method in interface okhttp3 .internal .http . HttpStream
This should update the HTTP engine's sentRequestMillis field.
writeSuccessCount() - Method in class okhttp3 . Cache
 
writeTimeout() - Method in class okhttp3 .internal .framed . FramedStream
 
writeTimeout(long, TimeUnit) - Method in class okhttp3 . OkHttpClient.Builder
Sets the default write timeout for new connections.
writeTimeoutMillis() - Method in class okhttp3 . OkHttpClient
Default write timeout (in milliseconds).
writeTo(BufferedSink) - Method in class okhttp3 . FormBody
 
writeTo(BufferedSink) - Method in class okhttp3 . MultipartBody
 
writeTo(BufferedSink) - Method in class okhttp3 . RequestBody
Writes the content of this request to out.
writeToSocket(Sink) - Method in class okhttp3 .internal .http . RetryableSink
 
writingRequestHeaders() - Method in class okhttp3 .internal .http . HttpEngine
Called immediately before the transport transmits HTTP request headers.
A  B  C  D  E  F  G  H  I  J  K  L  M  N  O  P  Q  R  S  T  U  V  W