All Downloads are FREE. Search and download functionalities are using the official Maven repository.

cn.hyperchain.sdk.provider.Provider Maven / Gradle / Ivy

There is a newer version: 1.4.3
Show newest version
package cn.hyperchain.sdk.provider;

import cn.hyperchain.sdk.request.Request;
import cn.hyperchain.sdk.response.Response;

import java.io.IOException;
import java.util.concurrent.Future;


// 由于ProviderManager的需要,此Provider可能无法抽象支持多种连接方式,暂时保留,每一种协议一个接口,每种协议可以有多个实现方式
public interface Provider {
     T send(Request request, Class responseType) throws IOException;


     Future sendAsync(Request request, Class responseType);


//    > Flowable subscribe(
//            Request request,
//            String unsubscribeMethod,
//            Class responseType);

    /**
     * Closes resources used by the service.
     *
     * @throws IOException thrown if a service failed to close all resources
     */
    void close() throws IOException;
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy