| OLD | NEW |
| 1 // Copyright (c) 2006-2008 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 // A class to help filter URLRequest jobs based on the URL of the request | 5 // A class to help filter URLRequest jobs based on the URL of the request |
| 6 // rather than just the scheme. Example usage: | 6 // rather than just the scheme. Example usage: |
| 7 // | 7 // |
| 8 // // Use as an "http" handler. | 8 // // Use as an "http" handler. |
| 9 // URLRequest::RegisterProtocolFactory("http", &URLRequestFilter::Factory); | 9 // URLRequest::RegisterProtocolFactory("http", &URLRequestFilter::Factory); |
| 10 // // Add special handling for the URL http://foo.com/ | 10 // // Add special handling for the URL http://foo.com/ |
| 11 // URLRequestFilter::GetInstance()->AddUrlHandler( | 11 // URLRequestFilter::GetInstance()->AddUrlHandler( |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 72 | 72 |
| 73 // Maps URLs to factories. | 73 // Maps URLs to factories. |
| 74 UrlHandlerMap url_handler_map_; | 74 UrlHandlerMap url_handler_map_; |
| 75 | 75 |
| 76 int hit_count_; | 76 int hit_count_; |
| 77 | 77 |
| 78 private: | 78 private: |
| 79 // Singleton instance. | 79 // Singleton instance. |
| 80 static URLRequestFilter* shared_instance_; | 80 static URLRequestFilter* shared_instance_; |
| 81 | 81 |
| 82 DISALLOW_EVIL_CONSTRUCTORS(URLRequestFilter); | 82 DISALLOW_COPY_AND_ASSIGN(URLRequestFilter); |
| 83 }; | 83 }; |
| 84 | 84 |
| 85 #endif // NET_URL_REQUEST_URL_REQUEST_FILTER_H_ | 85 #endif // NET_URL_REQUEST_URL_REQUEST_FILTER_H_ |
| OLD | NEW |