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

Side by Side Diff: net/url_request/url_request_context.h

Issue 83433008: Cleanup: Remove legacy accessors from URLRequestContext. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 class represents contextual information (cookies, cache, etc.) 5 // This class represents contextual information (cookies, cache, etc.)
6 // that's useful when processing resource requests. 6 // that's useful when processing resource requests.
7 // The class is reference-counted so that it can be cleaned up after any 7 // The class is reference-counted so that it can be cleaned up after any
8 // requests that are using it have been completed. 8 // requests that are using it have been completed.
9 9
10 #ifndef NET_URL_REQUEST_URL_REQUEST_CONTEXT_H_ 10 #ifndef NET_URL_REQUEST_URL_REQUEST_CONTEXT_H_
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
152 void set_cookie_store(CookieStore* cookie_store); 152 void set_cookie_store(CookieStore* cookie_store);
153 153
154 TransportSecurityState* transport_security_state() const { 154 TransportSecurityState* transport_security_state() const {
155 return transport_security_state_; 155 return transport_security_state_;
156 } 156 }
157 void set_transport_security_state( 157 void set_transport_security_state(
158 TransportSecurityState* state) { 158 TransportSecurityState* state) {
159 transport_security_state_ = state; 159 transport_security_state_ = state;
160 } 160 }
161 161
162 // ---------------------------------------------------------------------------
163 // Legacy accessors that delegate to http_user_agent_settings_.
164 // TODO(pauljensen): Remove after all clients are updated to directly access
165 // http_user_agent_settings_.
166 // Gets the value of 'Accept-Language' header field.
167 std::string GetAcceptLanguage() const;
168 // Gets the UA string to use for the given URL. Pass an invalid URL (such as
169 // GURL()) to get the default UA string.
170 std::string GetUserAgent(const GURL& url) const;
171 // ---------------------------------------------------------------------------
172
173 const URLRequestJobFactory* job_factory() const { return job_factory_; } 162 const URLRequestJobFactory* job_factory() const { return job_factory_; }
174 void set_job_factory(const URLRequestJobFactory* job_factory) { 163 void set_job_factory(const URLRequestJobFactory* job_factory) {
175 job_factory_ = job_factory; 164 job_factory_ = job_factory;
176 } 165 }
177 166
178 // May be NULL. 167 // May be NULL.
179 URLRequestThrottlerManager* throttler_manager() const { 168 URLRequestThrottlerManager* throttler_manager() const {
180 return throttler_manager_; 169 return throttler_manager_;
181 } 170 }
182 void set_throttler_manager(URLRequestThrottlerManager* throttler_manager) { 171 void set_throttler_manager(URLRequestThrottlerManager* throttler_manager) {
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
232 // --------------------------------------------------------------------------- 221 // ---------------------------------------------------------------------------
233 222
234 scoped_ptr<std::set<const URLRequest*> > url_requests_; 223 scoped_ptr<std::set<const URLRequest*> > url_requests_;
235 224
236 DISALLOW_COPY_AND_ASSIGN(URLRequestContext); 225 DISALLOW_COPY_AND_ASSIGN(URLRequestContext);
237 }; 226 };
238 227
239 } // namespace net 228 } // namespace net
240 229
241 #endif // NET_URL_REQUEST_URL_REQUEST_CONTEXT_H_ 230 #endif // NET_URL_REQUEST_URL_REQUEST_CONTEXT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698