You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
1.4 KiB
C#

using EntrustSettle.Model;
using System.Collections.Generic;
using System.Threading.Tasks;
namespace EntrustSettle.Common.Http.HttpPolly
{
public interface IHttpPollyHelper
{
Task<T> PostAsync<T, R>(HttpEnum httpEnum, string url, R request, Dictionary<string, string> headers = null);
Task<T> PostAsync<T>(HttpEnum httpEnum, string url, string request, Dictionary<string, string> headers = null);
Task<R> PostAsync<R>(HttpEnum httpEnum, string url, object request, Dictionary<string, string> headers = null);
Task<string> PostAsync(HttpEnum httpEnum, string url, string request, Dictionary<string, string> headers = null);
Task<string> PostAsync<R>(HttpEnum httpEnum, string url, R request, Dictionary<string, string> headers = null);
Task<T> GetAsync<T>(HttpEnum httpEnum, string url, Dictionary<string, string> queryParams = null, Dictionary<string, string> headers = null);
Task<string> GetAsync(HttpEnum httpEnum, string url, Dictionary<string, string> queryParams = null, Dictionary<string, string> headers = null);
Task<T> PutAsync<T, R>(HttpEnum httpEnum, string url, R request, Dictionary<string, string> headers = null);
Task<T> PutAsync<T>(HttpEnum httpEnum, string url, string request, Dictionary<string, string> headers = null);
Task<T> DeleteAsync<T>(HttpEnum httpEnum, string url, Dictionary<string, string> headers = null);
}
}