| OLD | NEW |
| 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 #include "net/base/network_delegate.h" | 5 #include "net/base/network_delegate.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "net/base/load_flags.h" | 8 #include "net/base/load_flags.h" |
| 9 #include "net/url_request/url_request.h" | 9 #include "net/url_request/url_request.h" |
| 10 | 10 |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 | 85 |
| 86 NetworkDelegate::AuthRequiredResponse NetworkDelegate::NotifyAuthRequired( | 86 NetworkDelegate::AuthRequiredResponse NetworkDelegate::NotifyAuthRequired( |
| 87 URLRequest* request, | 87 URLRequest* request, |
| 88 const AuthChallengeInfo& auth_info, | 88 const AuthChallengeInfo& auth_info, |
| 89 const AuthCallback& callback, | 89 const AuthCallback& callback, |
| 90 AuthCredentials* credentials) { | 90 AuthCredentials* credentials) { |
| 91 DCHECK(CalledOnValidThread()); | 91 DCHECK(CalledOnValidThread()); |
| 92 return OnAuthRequired(request, auth_info, callback, credentials); | 92 return OnAuthRequired(request, auth_info, callback, credentials); |
| 93 } | 93 } |
| 94 | 94 |
| 95 bool NetworkDelegate::NotifyReadingCookies( | 95 bool NetworkDelegate::CanGetCookies(const URLRequest& request, |
| 96 const URLRequest* request, | 96 const CookieList& cookie_list) { |
| 97 const CookieList& cookie_list) { | |
| 98 DCHECK(CalledOnValidThread()); | 97 DCHECK(CalledOnValidThread()); |
| 99 DCHECK(!(request->load_flags() & net::LOAD_DO_NOT_SEND_COOKIES)); | 98 DCHECK(!(request.load_flags() & net::LOAD_DO_NOT_SEND_COOKIES)); |
| 100 return CanGetCookies(request, cookie_list); | 99 return OnCanGetCookies(request, cookie_list); |
| 101 } | 100 } |
| 102 | 101 |
| 103 bool NetworkDelegate::NotifySettingCookie( | 102 bool NetworkDelegate::CanSetCookie(const URLRequest& request, |
| 104 const URLRequest* request, | 103 const std::string& cookie_line, |
| 105 const std::string& cookie_line, | 104 CookieOptions* options) { |
| 106 CookieOptions* options) { | |
| 107 DCHECK(CalledOnValidThread()); | 105 DCHECK(CalledOnValidThread()); |
| 108 DCHECK(!(request->load_flags() & net::LOAD_DO_NOT_SAVE_COOKIES)); | 106 DCHECK(!(request.load_flags() & net::LOAD_DO_NOT_SAVE_COOKIES)); |
| 109 return CanSetCookie(request, cookie_line, options); | 107 return OnCanSetCookie(request, cookie_line, options); |
| 108 } |
| 109 |
| 110 bool NetworkDelegate::CanAccessFile(const URLRequest& request, |
| 111 const FilePath& path) const { |
| 112 DCHECK(CalledOnValidThread()); |
| 113 return OnCanAccessFile(request, path); |
| 110 } | 114 } |
| 111 | 115 |
| 112 } // namespace net | 116 } // namespace net |
| OLD | NEW |