| 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/url_request/url_request_context_builder.h" | 5 #include "net/url_request/url_request_context_builder.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <utility> | 8 #include <utility> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 118 return true; | 118 return true; |
| 119 } | 119 } |
| 120 | 120 |
| 121 bool OnCanSetCookie(const URLRequest& request, | 121 bool OnCanSetCookie(const URLRequest& request, |
| 122 const std::string& cookie_line, | 122 const std::string& cookie_line, |
| 123 CookieOptions* options) override { | 123 CookieOptions* options) override { |
| 124 return true; | 124 return true; |
| 125 } | 125 } |
| 126 | 126 |
| 127 bool OnCanAccessFile(const URLRequest& request, | 127 bool OnCanAccessFile(const URLRequest& request, |
| 128 const base::FilePath& path) const override { | 128 const base::FilePath& original_path, |
| 129 const base::FilePath& absolute_path) const override { |
| 129 return true; | 130 return true; |
| 130 } | 131 } |
| 131 | 132 |
| 132 DISALLOW_COPY_AND_ASSIGN(BasicNetworkDelegate); | 133 DISALLOW_COPY_AND_ASSIGN(BasicNetworkDelegate); |
| 133 }; | 134 }; |
| 134 | 135 |
| 135 // Define a context class that can self-manage the ownership of its components | 136 // Define a context class that can self-manage the ownership of its components |
| 136 // via a UrlRequestContextStorage object. | 137 // via a UrlRequestContextStorage object. |
| 137 class ContainerURLRequestContext : public URLRequestContext { | 138 class ContainerURLRequestContext : public URLRequestContext { |
| 138 public: | 139 public: |
| (...skipping 380 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 519 } | 520 } |
| 520 url_request_interceptors_.clear(); | 521 url_request_interceptors_.clear(); |
| 521 } | 522 } |
| 522 storage->set_job_factory(std::move(top_job_factory)); | 523 storage->set_job_factory(std::move(top_job_factory)); |
| 523 // TODO(willchan): Support sdch. | 524 // TODO(willchan): Support sdch. |
| 524 | 525 |
| 525 return std::move(context); | 526 return std::move(context); |
| 526 } | 527 } |
| 527 | 528 |
| 528 } // namespace net | 529 } // namespace net |
| OLD | NEW |