OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef CONTENT_BROWSER_APPCACHE_APPCACHE_INTERCEPTOR_H_ | 5 #ifndef CONTENT_BROWSER_APPCACHE_APPCACHE_INTERCEPTOR_H_ |
6 #define CONTENT_BROWSER_APPCACHE_APPCACHE_INTERCEPTOR_H_ | 6 #define CONTENT_BROWSER_APPCACHE_APPCACHE_INTERCEPTOR_H_ |
7 | 7 |
8 #include "base/memory/singleton.h" | 8 #include "base/memory/singleton.h" |
9 #include "content/common/content_export.h" | 9 #include "content/common/content_export.h" |
10 #include "content/public/common/resource_type.h" | 10 #include "content/public/common/resource_type.h" |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 static void CompleteCrossSiteTransfer(net::URLRequest* request, | 45 static void CompleteCrossSiteTransfer(net::URLRequest* request, |
46 int new_process_id, | 46 int new_process_id, |
47 int new_host_id); | 47 int new_host_id); |
48 | 48 |
49 static AppCacheInterceptor* GetInstance(); | 49 static AppCacheInterceptor* GetInstance(); |
50 | 50 |
51 protected: | 51 protected: |
52 // Override from net::URLRequest::Interceptor: | 52 // Override from net::URLRequest::Interceptor: |
53 virtual net::URLRequestJob* MaybeIntercept( | 53 virtual net::URLRequestJob* MaybeIntercept( |
54 net::URLRequest* request, | 54 net::URLRequest* request, |
55 net::NetworkDelegate* network_delegate) OVERRIDE; | 55 net::NetworkDelegate* network_delegate) override; |
56 virtual net::URLRequestJob* MaybeInterceptResponse( | 56 virtual net::URLRequestJob* MaybeInterceptResponse( |
57 net::URLRequest* request, | 57 net::URLRequest* request, |
58 net::NetworkDelegate* network_delegate) OVERRIDE; | 58 net::NetworkDelegate* network_delegate) override; |
59 virtual net::URLRequestJob* MaybeInterceptRedirect( | 59 virtual net::URLRequestJob* MaybeInterceptRedirect( |
60 net::URLRequest* request, | 60 net::URLRequest* request, |
61 net::NetworkDelegate* network_delegate, | 61 net::NetworkDelegate* network_delegate, |
62 const GURL& location) OVERRIDE; | 62 const GURL& location) override; |
63 | 63 |
64 private: | 64 private: |
65 friend struct DefaultSingletonTraits<AppCacheInterceptor>; | 65 friend struct DefaultSingletonTraits<AppCacheInterceptor>; |
66 | 66 |
67 AppCacheInterceptor(); | 67 AppCacheInterceptor(); |
68 virtual ~AppCacheInterceptor(); | 68 virtual ~AppCacheInterceptor(); |
69 | 69 |
70 static void SetHandler(net::URLRequest* request, | 70 static void SetHandler(net::URLRequest* request, |
71 AppCacheRequestHandler* handler); | 71 AppCacheRequestHandler* handler); |
72 static AppCacheRequestHandler* GetHandler(net::URLRequest* request); | 72 static AppCacheRequestHandler* GetHandler(net::URLRequest* request); |
73 | 73 |
74 DISALLOW_COPY_AND_ASSIGN(AppCacheInterceptor); | 74 DISALLOW_COPY_AND_ASSIGN(AppCacheInterceptor); |
75 }; | 75 }; |
76 | 76 |
77 } // namespace content | 77 } // namespace content |
78 | 78 |
79 #endif // CONTENT_BROWSER_APPCACHE_APPCACHE_INTERCEPTOR_H_ | 79 #endif // CONTENT_BROWSER_APPCACHE_APPCACHE_INTERCEPTOR_H_ |
OLD | NEW |