top.jfunc.http.smart.JoddSmartHttpClient Maven / Gradle / Ivy
package top.jfunc.http.smart;
import jodd.http.HttpRequest;
import top.jfunc.http.component.*;
import top.jfunc.http.component.jodd.DefaultJoddBodyContentCallbackCreator;
import top.jfunc.http.component.jodd.DefaultJoddUploadContentCallbackCreator;
import top.jfunc.http.component.jodd.JoddHttpRequestExecutor;
/**
* 使用Jodd实现的Http请求类
* @author 熊诗言2020/12/01
*/
public class JoddSmartHttpClient extends AbstractImplementSmartHttpClient {
public JoddSmartHttpClient() {
super(new DefaultJoddBodyContentCallbackCreator(),
new DefaultJoddUploadContentCallbackCreator(),
new JoddHttpRequestExecutor());
}
public JoddSmartHttpClient(ContentCallbackCreator bodyContentCallbackCreator,
ContentCallbackCreator uploadContentCallbackCreator,
HttpRequestExecutor httpRequestExecutor) {
super(bodyContentCallbackCreator, uploadContentCallbackCreator, httpRequestExecutor);
}
public JoddSmartHttpClient(AssemblingFactory assemblingFactory,
ContentCallbackCreator bodyContentCallbackCreator,
ContentCallbackCreator uploadContentCallbackCreator,
HttpRequestExecutor httpRequestExecutor) {
super(assemblingFactory, bodyContentCallbackCreator, uploadContentCallbackCreator, httpRequestExecutor);
}
@Override
public String toString() {
return "SmartHttpClient implemented by Jodd-Http";
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy