public interface ClientEngine extends Closeable
Modifier and Type | Method and Description |
---|---|
Object |
getRawEngine()
获取原始引擎的钩子方法,用于自定义特殊属性,如插件等
|
ClientEngine |
init(ClientConfig config)
设置客户端引擎参数,如超时、代理等信息
对不同引擎个性化配置,使用对应的
ClientConfig 子类:
HttpClient4和HttpClient5使用ApacheHttpClientConfig
OkHttp使用OkHttpClientConfig
如果混用这些配置,则个性配置不生效 |
Response |
send(Request message)
发送HTTP请求
|
ClientEngine init(ClientConfig config)
ClientConfig
子类:
ApacheHttpClientConfig
OkHttpClientConfig
如果混用这些配置,则个性配置不生效
config
- 客户端设置Object getRawEngine()
Copyright © 2025. All rights reserved.