com.aliyuncs.http.IHttpClient Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of aliyun-java-sdk-core Show documentation
Show all versions of aliyun-java-sdk-core Show documentation
Aliyun Open API SDK for Java
Copyright (C) Alibaba Cloud Computing
All rights reserved.
版权所有 (C)阿里云计算有限公司
http://www.aliyun.com
The newest version!
package com.aliyuncs.http;
import com.aliyuncs.exceptions.ClientException;
import java.io.Closeable;
import java.io.IOException;
import java.util.concurrent.Future;
public abstract class IHttpClient implements Closeable {
protected HttpClientConfig clientConfig;
public IHttpClient(HttpClientConfig clientConfig) throws ClientException {
if (clientConfig == null) {
clientConfig = HttpClientConfig.getDefault();
}
this.clientConfig = clientConfig;
init(clientConfig);
}
public IHttpClient() {
// do nothing
}
protected abstract void init(HttpClientConfig clientConfig) throws ClientException;
public abstract HttpResponse syncInvoke(HttpRequest apiRequest) throws IOException, ClientException;
public abstract Future asyncInvoke(final HttpRequest apiRequest, final CallBack callback)
throws IOException;
@Deprecated
public abstract void ignoreSSLCertificate();
@Deprecated
public abstract void restoreSSLCertificate();
public abstract boolean isSingleton();
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy