public abstract class OkHttpRequest extends Object
| 限定符和类型 | 字段和说明 |
|---|---|
protected String |
body |
protected okhttp3.Request.Builder |
builder |
protected Map<String,String> |
encodedParams |
protected List<PostRequest.FileInfo> |
fileInfos |
protected Map<String,String> |
headers |
protected String |
id |
protected okhttp3.MultipartBody |
multipartBody |
protected Map<String,String> |
params |
protected String |
url |
| 限定符 | 构造器和说明 |
|---|---|
protected |
OkHttpRequest(String url,
Object tag,
Map<String,String> params,
Map<String,String> headers,
List<PostRequest.FileInfo> fileInfos,
String body,
okhttp3.MultipartBody multipartBody,
String id) |
protected |
OkHttpRequest(String url,
Object tag,
Map<String,String> params,
Map<String,String> encodedParams,
Map<String,String> headers,
List<PostRequest.FileInfo> fileInfos,
String body,
okhttp3.MultipartBody multipartBody,
String id) |
| 限定符和类型 | 方法和说明 |
|---|---|
protected void |
appendHeaders() |
RequestCall |
build(okhttp3.OkHttpClient okHttpClient) |
protected abstract okhttp3.Request |
buildRequest(okhttp3.RequestBody requestBody) |
protected abstract okhttp3.RequestBody |
buildRequestBody() |
okhttp3.Request |
createRequest(Callback callback) |
static okhttp3.RequestBody |
createRequestBody(okhttp3.MediaType contentType,
InputStream is)
Returns a new request body that transmits the content of
file. |
String |
getId() |
protected String id
protected String url
protected String body
protected List<PostRequest.FileInfo> fileInfos
protected okhttp3.MultipartBody multipartBody
protected okhttp3.Request.Builder builder
protected OkHttpRequest(String url, Object tag, Map<String,String> params, Map<String,String> headers, List<PostRequest.FileInfo> fileInfos, String body, okhttp3.MultipartBody multipartBody, String id)
protected abstract okhttp3.RequestBody buildRequestBody()
protected abstract okhttp3.Request buildRequest(okhttp3.RequestBody requestBody)
public RequestCall build(okhttp3.OkHttpClient okHttpClient)
public okhttp3.Request createRequest(Callback callback)
protected void appendHeaders()
public String getId()
public static okhttp3.RequestBody createRequestBody(okhttp3.MediaType contentType,
InputStream is)
file.Copyright © 2020. All rights reserved.