Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(275)

Side by Side Diff: Src/GoogleApis/Apis/Http/ConfigurableMessageHandler.cs

Issue 12566043: Issue 369: Change default behavior of an HTTP request (Closed) Base URL: https://google-api-dotnet-client.googlecode.com/hg/
Patch Set: Miceli review Created 10 years, 11 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 Copyright 2013 Google Inc 2 Copyright 2013 Google Inc
3 3
4 Licensed under the Apache License, Version 2.0 (the "License"); 4 Licensed under the Apache License, Version 2.0 (the "License");
5 you may not use this file except in compliance with the License. 5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at 6 You may obtain a copy of the License at
7 7
8 http://www.apache.org/licenses/LICENSE-2.0 8 http://www.apache.org/licenses/LICENSE-2.0
9 9
10 Unless required by applicable law or agreed to in writing, software 10 Unless required by applicable law or agreed to in writing, software
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 } 77 }
78 78
79 /// <summary> Gets a list of <see cref="IHttpExecuteInterceptor"/>. </su mmary> 79 /// <summary> Gets a list of <see cref="IHttpExecuteInterceptor"/>. </su mmary>
80 public IList<IHttpExecuteInterceptor> ExecuteInterceptors 80 public IList<IHttpExecuteInterceptor> ExecuteInterceptors
81 { 81 {
82 get { return executeInterceptors; } 82 get { return executeInterceptors; }
83 } 83 }
84 84
85 #endregion 85 #endregion
86 86
87 /// <summary> Number of tries. Default is <c>10</c>. </summary> 87 /// <summary> Number of tries. Default is <c>3</c>. </summary>
88 private int numTries = 10; 88 private int numTries = 3;
89 89
90 /// <summary>· 90 /// <summary>·
91 /// Gets or sets the number of tries that will be allowed to execute. Re tries occur as a result of either 91 /// Gets or sets the number of tries that will be allowed to execute. Re tries occur as a result of either
92 /// <see cref="IHttpUnsuccessfulResponseHandler"/> or <see cref="IHttpEx ceptionHandler"/> which handles the 92 /// <see cref="IHttpUnsuccessfulResponseHandler"/> or <see cref="IHttpEx ceptionHandler"/> which handles the
93 /// abnormal Http response or exception, before being terminated.· 93 /// abnormal Http response or exception, before being terminated.·
94 /// Set <c>1</c> for not retrying requests. The default value is <c>10</ c>". 94 /// Set <c>1</c> for not retrying requests. The default value is <c>3</c >".
95 /// </summary> 95 /// </summary>
96 public int NumTries 96 public int NumTries
97 { 97 {
98 get { return numTries; } 98 get { return numTries; }
99 set 99 set
100 { 100 {
101 if (value > MaxAllowedNumTries || value < 1) 101 if (value > MaxAllowedNumTries || value < 1)
102 { 102 {
103 throw new ArgumentOutOfRangeException("NumRetries"); 103 throw new ArgumentOutOfRangeException("NumTries");
104 } 104 }
105 numTries = value; 105 numTries = value;
106 } 106 }
107 } 107 }
108 108
109 /// <summary>· 109 /// <summary>·
110 /// Gets or sets whether the handler should follow a redirect when a red irect response is received. Default· 110 /// Gets or sets whether the handler should follow a redirect when a red irect response is received. Default·
111 /// value is <c>true</c>. 111 /// value is <c>true</c>.
112 /// </summary> 112 /// </summary>
113 public bool FollowRedirect { get; set; } 113 public bool FollowRedirect { get; set; }
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
306 request.Headers.Remove("Authorization"); 306 request.Headers.Remove("Authorization");
307 request.Headers.IfMatch.Clear(); 307 request.Headers.IfMatch.Clear();
308 request.Headers.IfNoneMatch.Clear(); 308 request.Headers.IfNoneMatch.Clear();
309 request.Headers.IfModifiedSince = null; 309 request.Headers.IfModifiedSince = null;
310 request.Headers.IfUnmodifiedSince = null; 310 request.Headers.IfUnmodifiedSince = null;
311 request.Headers.Remove("If-Range"); 311 request.Headers.Remove("If-Range");
312 return true; 312 return true;
313 } 313 }
314 } 314 }
315 } 315 }
OLDNEW
« no previous file with comments | « Src/GoogleApis/Apis/Http/BackOffHandler.cs ('k') | Src/GoogleApis/Apis/Services/BaseClientService.cs » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b