Package | Description |
---|---|
okhttp3 |
An HTTP+HTTP/2 client for Android and Java applications.
|
okhttp3.internal | |
okhttp3.internal.cache | |
okhttp3.internal.http | |
okhttp3.internal.http1 | |
okhttp3.internal.http2 | |
okhttp3.internal.ws |
Modifier and Type | Method and Description |
---|---|
Request |
JavaNetAuthenticator.authenticate(Route route,
Response response) |
Request |
Authenticator.authenticate(Route route,
Response response)
Returns a request that includes a credential to satisfy an authentication challenge in
response . |
Request |
Request.Builder.build() |
Request |
Call.request()
Returns the original request that initiated this call.
|
Request |
Interceptor.Chain.request() |
Request |
WebSocket.request()
Returns the original request that initiated this web socket.
|
Request |
Response.request()
The wire-level request that initiated this HTTP response.
|
Modifier and Type | Method and Description |
---|---|
Call |
OkHttpClient.newCall(Request request)
Prepares the
request to be executed at some point in the future. |
Call |
Call.Factory.newCall(Request request) |
WebSocket |
OkHttpClient.newWebSocket(Request request,
WebSocketListener listener)
Uses
request to connect a new web socket. |
WebSocket |
WebSocket.Factory.newWebSocket(Request request,
WebSocketListener listener)
Creates a new web socket and immediately returns it.
|
Response |
Interceptor.Chain.proceed(Request request) |
Response.Builder |
Response.Builder.request(Request request) |
void |
EventListener.requestHeadersEnd(Call call,
Request request)
Invoked immediately after sending request headers.
|
Modifier and Type | Method and Description |
---|---|
abstract Call |
Internal.newWebSocketCall(OkHttpClient client,
Request request) |
Modifier and Type | Field and Description |
---|---|
Request |
CacheStrategy.networkRequest
The request to send on the network, or null if this call doesn't use the network.
|
Modifier and Type | Method and Description |
---|---|
Response |
InternalCache.get(Request request) |
static boolean |
CacheStrategy.isCacheable(Response response,
Request request)
Returns true if
response can be stored to later serve another request. |
void |
InternalCache.remove(Request request)
Remove any cache entries for the supplied
request . |
Constructor and Description |
---|
Factory(long nowMillis,
Request request,
Response cacheResponse) |
Modifier and Type | Method and Description |
---|---|
Request |
RealInterceptorChain.request() |
Modifier and Type | Method and Description |
---|---|
okio.Sink |
HttpCodec.createRequestBody(Request request,
long contentLength)
Returns an output stream where the request body can be streamed.
|
static String |
RequestLine.get(Request request,
Proxy.Type proxyType)
Returns the request status line, like "GET / HTTP/1.1".
|
Response |
RealInterceptorChain.proceed(Request request) |
Response |
RealInterceptorChain.proceed(Request request,
StreamAllocation streamAllocation,
HttpCodec httpCodec,
RealConnection connection) |
static boolean |
HttpHeaders.varyMatches(Response cachedResponse,
Headers cachedRequest,
Request newRequest)
Returns true if none of the Vary headers have changed between
cachedRequest and newRequest . |
void |
HttpCodec.writeRequestHeaders(Request request)
This should update the HTTP engine's sentRequestMillis field.
|
Constructor and Description |
---|
RealInterceptorChain(List<Interceptor> interceptors,
StreamAllocation streamAllocation,
HttpCodec httpCodec,
RealConnection connection,
int index,
Request request,
Call call,
EventListener eventListener,
int connectTimeout,
int readTimeout,
int writeTimeout) |
Modifier and Type | Method and Description |
---|---|
okio.Sink |
Http1Codec.createRequestBody(Request request,
long contentLength) |
void |
Http1Codec.writeRequestHeaders(Request request)
Prepares the HTTP headers and sends them to the server.
|
Modifier and Type | Method and Description |
---|---|
okio.Sink |
Http2Codec.createRequestBody(Request request,
long contentLength) |
static List<Header> |
Http2Codec.http2HeadersList(Request request) |
void |
Http2Codec.writeRequestHeaders(Request request) |
Modifier and Type | Method and Description |
---|---|
Request |
RealWebSocket.request() |
Constructor and Description |
---|
RealWebSocket(Request request,
WebSocketListener listener,
Random random,
long pingIntervalMillis) |
Copyright © 2019. All rights reserved.