Index: chrome/browser/ui/search/new_tab_page_interceptor_service_factory.h |
diff --git a/chrome/browser/ui/search/new_tab_page_interceptor_service_factory.h b/chrome/browser/ui/search/new_tab_page_interceptor_service_factory.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..fe7a78f7a35b2e6caba9651d5a9bae1beece3f9a |
--- /dev/null |
+++ b/chrome/browser/ui/search/new_tab_page_interceptor_service_factory.h |
@@ -0,0 +1,43 @@ |
+// Copyright 2015 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef CHROME_BROWSER_UI_SEARCH_NEW_TAB_PAGE_INTERCEPTOR_SERVICE_FACTORY_H_ |
+#define CHROME_BROWSER_UI_SEARCH_NEW_TAB_PAGE_INTERCEPTOR_SERVICE_FACTORY_H_ |
+ |
+#include "base/memory/singleton.h" |
+#include "components/keyed_service/content/browser_context_keyed_service_factory.h" |
+#include "components/keyed_service/core/keyed_service.h" |
+ |
+class NewTabPageInterceptorService; |
+class Profile; |
+ |
+namespace content { |
+class BrowserContext; |
+} |
+ |
+namespace net { |
+class URLRequestInterceptor; |
+} |
+ |
+// Owns and creates NewTabPageInterceptorService instances. |
+class NewTabPageInterceptorServiceFactory |
+ : public BrowserContextKeyedServiceFactory { |
+ public: |
+ static NewTabPageInterceptorService* GetForProfile(Profile* profile); |
+ static NewTabPageInterceptorServiceFactory* GetInstance(); |
+ |
+ private: |
+ friend struct DefaultSingletonTraits<NewTabPageInterceptorServiceFactory>; |
+ |
+ NewTabPageInterceptorServiceFactory(); |
+ ~NewTabPageInterceptorServiceFactory() override; |
+ |
+ // BrowserContextKeyedServiceFactory: |
+ KeyedService* BuildServiceInstanceFor( |
+ content::BrowserContext* context) const override; |
+ |
+ DISALLOW_COPY_AND_ASSIGN(NewTabPageInterceptorServiceFactory); |
+}; |
+ |
+#endif // CHROME_BROWSER_UI_SEARCH_NEW_TAB_PAGE_INTERCEPTOR_SERVICE_FACTORY_H_ |