예제 #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ApiRequestHandler" /> class.
 /// </summary>
 /// <param name="uriBuilder">The URI builder.</param>
 public ApiRequestHandler(IApiUriBuilder uriBuilder)
 {
     this.UriBuilder = uriBuilder;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="FailedMockApiRequestHandler" /> class.
 /// </summary>
 public FailedMockApiRequestHandler()
 {
     this._uriBuilder = new ApiUriBuilder();
 }
예제 #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ApiRequestHandler" /> class.
 /// </summary>
 /// <param name="uriBuilder">The URI builder.</param>
 /// <param name="gzipHandler">The gzip handler</param>
 public ApiRequestHandler(IApiUriBuilder uriBuilder, IGzipHandler gzipHandler)
 {
     this.UriBuilder   = uriBuilder;
     this._gzipHandler = gzipHandler;
 }
예제 #4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="SuccessfulMockApiRequestHandler" /> class.
 /// </summary>
 public SuccessfulMockApiRequestHandler()
 {
     this._uriBuilder = new ApiUriBuilder();
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="MockApiRequestHandler" /> class.
 /// </summary>
 /// <param name="response">The fake response that should be returned for the first request</param>
 public MockApiRequestHandler(FakeResponse response)
 {
     this._uriBuilder = new ApiUriBuilder();
     this.NextFakeResponse = response;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="SuccessfulMockApiRequestHandler" /> class.
 /// </summary>
 public SuccessfulMockApiRequestHandler()
 {
     this._uriBuilder = new ApiUriBuilder();
 }
예제 #7
0
 /// <summary>
 /// Initializes a new instance of the <see cref="MockApiRequestHandler" /> class.
 /// </summary>
 /// <param name="response">The fake response that should be returned for the first request</param>
 public MockApiRequestHandler(FakeResponse response)
 {
     this._uriBuilder      = new ApiUriBuilder();
     this.NextFakeResponse = response;
 }
예제 #8
0
 /// <summary>
 /// Initializes a new instance of the <see cref="FailedMockApiRequestHandler" /> class.
 /// </summary>
 public FailedMockApiRequestHandler()
 {
     this._uriBuilder = new ApiUriBuilder();
 }
예제 #9
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ApiRequestHandler" /> class.
 /// </summary>
 /// <param name="uriBuilder">The URI builder.</param>
 /// <param name="userAgent">The UserAgent header to be sent in requests.</param>
 /// <param name="requestProxy">The proxy class responsible for making the request</param>
 public ApiRequestHandler(IApiUriBuilder uriBuilder, string userAgent = null, IHttpClientRequestProxy requestProxy = null)
 {
     this.UriBuilder    = uriBuilder;
     this._userAgent    = userAgent;
     this._requestProxy = requestProxy ?? new HttpClientRequestProxy();
 }