public GithubRequestWithReturnType(Services.ILogProvider logProvider,
                                    Services.ICacheProvider cacheProvider,
                                    Services.IAuthProvider authProvider,
                                    string path,
                                    GithubSharpHttpVerbs method)
     : base(logProvider, cacheProvider, authProvider, path, method)
 {
 }
Ejemplo n.º 2
0
 protected IGithubResponse Get(
     string path,
     GithubSharpHttpVerbs method)
 {
     return(new GithubRequest(
                LogProvider,
                CacheProvider,
                AuthProvider,
                path,
                method).GetResponse());
 }
Ejemplo n.º 3
0
 protected IGithubResponseWithReturnType <TReturnType> Get <TReturnType>(
     string path,
     GithubSharpHttpVerbs method)
     where TReturnType : class
 {
     return(new GithubRequestWithReturnType <TReturnType>(
                LogProvider,
                CacheProvider,
                AuthProvider,
                path,
                method)
            .GetResponseWithReturnType());
 }
 public GithubRequestWithInputAndReturnType(
     ILogProvider logProvider,
     ICacheProvider cacheProvider,
     IAuthProvider authProvider,
     string path,
     GithubSharpHttpVerbs method,
     TInputType input)
     : base(logProvider,
            cacheProvider,
            authProvider,
            path,
            method)
 {
     ModelToSend = input;
 }
Ejemplo n.º 5
0
 public GithubRequest(
         Services.ILogProvider logProvider,
         Services.ICacheProvider cacheProvider,
         Services.IAuthProvider authProvider,
         string path,
         GithubSharpHttpVerbs method)
     : this(logProvider,
         cacheProvider,
         authProvider,
         path,
         method,
         null,
         null)
 {
 }
Ejemplo n.º 6
0
 public GithubRequest(
     Services.ILogProvider logProvider,
     Services.ICacheProvider cacheProvider,
     Services.IAuthProvider authProvider,
     string path,
     GithubSharpHttpVerbs method)
     : this(
         logProvider,
         cacheProvider,
         authProvider,
         path,
         method,
         null,
         null)
 {
 }
Ejemplo n.º 7
0
        public static string ToString(this GithubSharpHttpVerbs verb)
        {
            switch (verb)
            {
            case GithubSharpHttpVerbs.Get: return("GET");

            case GithubSharpHttpVerbs.Post: return("POST");

            case GithubSharpHttpVerbs.Patch: return("PATCH");

            case GithubSharpHttpVerbs.Delete: return("DELETE");

            case GithubSharpHttpVerbs.Put: return("PUT");

            case GithubSharpHttpVerbs.Head: return("HEAD");

            default: return("OPTIONS");
            }
        }
Ejemplo n.º 8
0
 public GithubRequest(
     Services.ILogProvider logProvider,
     Services.ICacheProvider cacheProvider,
     Services.IAuthProvider authProvider,
     string path,
     GithubSharpHttpVerbs method,
     int?pagingLimit,
     int?currentPage,
     GithubSharpMimeTypes mime)
 {
     LogProvider         = logProvider;
     CacheProvider       = cacheProvider;
     AuthProvider        = authProvider;
     Path                = path;
     Method              = method;
     PagingCurrentPage   = currentPage;
     PagingRequestAmount = pagingLimit;
     GithubSharpMimeType = mime;
 }
Ejemplo n.º 9
0
 public GithubRequest(
     Services.ILogProvider logProvider,
     Services.ICacheProvider cacheProvider,
     Services.IAuthProvider authProvider,
     string path,
     GithubSharpHttpVerbs method,
     int?pagingLimit,
     int?currentPage)
     : this(
         logProvider,
         cacheProvider,
         authProvider,
         path,
         method,
         pagingLimit,
         currentPage,
         GithubSharpMimeTypes.Json
         )
 {
 }
Ejemplo n.º 10
0
        public GithubRequest(
                Services.ILogProvider logProvider,
                Services.ICacheProvider cacheProvider,
                Services.IAuthProvider authProvider,
                string path,
                GithubSharpHttpVerbs method,
                int? pagingLimit,
                int? currentPage)
            : this(
                logProvider,
                cacheProvider,
                authProvider,
                path,
                method,
                pagingLimit,
                currentPage,
                GithubSharpMimeTypes.Json
                )
        {

        }
Ejemplo n.º 11
0
 public GithubRequest(
         Services.ILogProvider logProvider,
         Services.ICacheProvider cacheProvider,
         Services.IAuthProvider authProvider,
         string path,
         GithubSharpHttpVerbs method,
         int? pagingLimit,
         int? currentPage,
         GithubSharpMimeTypes mime)
 {
     LogProvider = logProvider;
     CacheProvider = cacheProvider;
     AuthProvider = authProvider;
     Path = path;
     Method = method;
     PagingCurrentPage = currentPage;
     PagingRequestAmount = pagingLimit;
     GithubSharpMimeType = mime;
 }