mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-04-19 03:01:48 +08:00
fix code
This commit is contained in:
parent
1eb629bc3b
commit
01dc2450a0
@ -4,6 +4,7 @@ import cn.hutool.core.lang.Singleton;
|
|||||||
import cn.hutool.core.text.StrUtil;
|
import cn.hutool.core.text.StrUtil;
|
||||||
import cn.hutool.core.util.ServiceLoaderUtil;
|
import cn.hutool.core.util.ServiceLoaderUtil;
|
||||||
import cn.hutool.http.HttpException;
|
import cn.hutool.http.HttpException;
|
||||||
|
import cn.hutool.http.client.ClientConfig;
|
||||||
import cn.hutool.http.client.ClientEngine;
|
import cn.hutool.http.client.ClientEngine;
|
||||||
import cn.hutool.log.StaticLog;
|
import cn.hutool.log.StaticLog;
|
||||||
|
|
||||||
@ -24,6 +25,18 @@ public class ClientEngineFactory {
|
|||||||
return Singleton.get(ClientEngine.class.getName(), ClientEngineFactory::of);
|
return Singleton.get(ClientEngine.class.getName(), ClientEngineFactory::of);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据用户引入的HTTP客户端引擎jar,自动创建对应的拼音引擎对象<br>
|
||||||
|
* 推荐创建的引擎单例使用,此方法每次调用会返回新的引擎
|
||||||
|
*
|
||||||
|
* @param config Http客户端配置
|
||||||
|
* @return {@code ClientEngine}
|
||||||
|
*/
|
||||||
|
@SuppressWarnings("resource")
|
||||||
|
public static ClientEngine of(final ClientConfig config) {
|
||||||
|
return of().setConfig(config);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 根据用户引入的HTTP客户端引擎jar,自动创建对应的拼音引擎对象<br>
|
* 根据用户引入的HTTP客户端引擎jar,自动创建对应的拼音引擎对象<br>
|
||||||
* 推荐创建的引擎单例使用,此方法每次调用会返回新的引擎
|
* 推荐创建的引擎单例使用,此方法每次调用会返回新的引擎
|
||||||
|
Loading…
x
Reference in New Issue
Block a user