using RestSharp; using System; namespace EntrustSettle.Common.HttpRestSharp { /// /// API请求执行者接口 /// public interface IRestSharp { /// /// 同步执行方法 /// /// /// IRestResponse Execute(IRestRequest request); /// /// 同步执行方法 /// /// 返回值 /// 请求参数 /// T Execute(IRestRequest request) where T : new(); /// /// 异步执行方法 /// /// 请求参数 /// /// RestRequestAsyncHandle ExecuteAsync(IRestRequest request, Action callback); /// /// 异步执行方法 /// /// /// /// /// RestRequestAsyncHandle ExecuteAsync(IRestRequest request, Action> callback) where T : new(); } }