Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(140)

Side by Side Diff: chrome/common/net/url_fetcher.h

Issue 3171019: Reland r56483 - Monitor network change in GoogleURLTracker (Closed)
Patch Set: check Chrome Frame Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chrome/common/net/test_url_fetcher_factory.h ('k') | chrome/common/net/url_fetcher_protect.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 // 4 //
5 // This file contains URLFetcher, a wrapper around URLRequest that handles 5 // This file contains URLFetcher, a wrapper around URLRequest that handles
6 // low-level details like thread safety, ref counting, and incremental buffer 6 // low-level details like thread safety, ref counting, and incremental buffer
7 // reading. This is useful for callers who simply want to get the data from a 7 // reading. This is useful for callers who simply want to get the data from a
8 // URL and don't care about all the nitty-gritty details. 8 // URL and don't care about all the nitty-gritty details.
9 9
10 #ifndef CHROME_COMMON_NET_URL_FETCHER_H_ 10 #ifndef CHROME_COMMON_NET_URL_FETCHER_H_
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 133
134 // Returns the current load flags. 134 // Returns the current load flags.
135 int load_flags() const; 135 int load_flags() const;
136 136
137 // Set extra headers on the request. Must be called before the request 137 // Set extra headers on the request. Must be called before the request
138 // is started. 138 // is started.
139 void set_extra_request_headers(const std::string& extra_request_headers); 139 void set_extra_request_headers(const std::string& extra_request_headers);
140 140
141 // Set the URLRequestContext on the request. Must be called before the 141 // Set the URLRequestContext on the request. Must be called before the
142 // request is started. 142 // request is started.
143 void set_request_context(URLRequestContextGetter* request_context_getter); 143 virtual void set_request_context(
144 URLRequestContextGetter* request_context_getter);
144 145
145 // If |retry| is false, 5xx responses will be propagated to the observer, 146 // If |retry| is false, 5xx responses will be propagated to the observer,
146 // if it is true URLFetcher will automatically re-execute the request, 147 // if it is true URLFetcher will automatically re-execute the request,
147 // after backoff_delay() elapses. URLFetcher has it set to true by default. 148 // after backoff_delay() elapses. URLFetcher has it set to true by default.
148 void set_automatcally_retry_on_5xx(bool retry); 149 void set_automatcally_retry_on_5xx(bool retry);
149 150
150 // Returns the back-off delay before the request will be retried, 151 // Returns the back-off delay before the request will be retried,
151 // when a 5xx response was received. 152 // when a 5xx response was received.
152 base::TimeDelta backoff_delay() const { return backoff_delay_; } 153 base::TimeDelta backoff_delay() const { return backoff_delay_; }
153 154
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
190 bool automatically_retry_on_5xx_; 191 bool automatically_retry_on_5xx_;
191 // Back-off time delay. 0 by default. 192 // Back-off time delay. 0 by default.
192 base::TimeDelta backoff_delay_; 193 base::TimeDelta backoff_delay_;
193 194
194 static bool g_interception_enabled; 195 static bool g_interception_enabled;
195 196
196 DISALLOW_COPY_AND_ASSIGN(URLFetcher); 197 DISALLOW_COPY_AND_ASSIGN(URLFetcher);
197 }; 198 };
198 199
199 #endif // CHROME_COMMON_NET_URL_FETCHER_H_ 200 #endif // CHROME_COMMON_NET_URL_FETCHER_H_
OLDNEW
« no previous file with comments | « chrome/common/net/test_url_fetcher_factory.h ('k') | chrome/common/net/url_fetcher_protect.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698