Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(248)

Side by Side Diff: chrome/browser/predictors/resource_prefetch_predictor_factory.h

Issue 14967003: Drop more dependencies of ProfileKeyedService infrastructure on chrome. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: trybots Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 #ifndef CHROME_BROWSER_PREDICTORS_RESOURCE_PREFETCH_PREDICTOR_FACTORY_H_ 5 #ifndef CHROME_BROWSER_PREDICTORS_RESOURCE_PREFETCH_PREDICTOR_FACTORY_H_
6 #define CHROME_BROWSER_PREDICTORS_RESOURCE_PREFETCH_PREDICTOR_FACTORY_H_ 6 #define CHROME_BROWSER_PREDICTORS_RESOURCE_PREFETCH_PREDICTOR_FACTORY_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/singleton.h" 9 #include "base/memory/singleton.h"
10 #include "chrome/browser/profiles/profile_keyed_service_factory.h" 10 #include "chrome/browser/profiles/profile_keyed_service_factory.h"
11 11
12 class Profile;
13
12 namespace predictors { 14 namespace predictors {
13 15
14 class ResourcePrefetchPredictor; 16 class ResourcePrefetchPredictor;
15 17
16 class ResourcePrefetchPredictorFactory : public ProfileKeyedServiceFactory { 18 class ResourcePrefetchPredictorFactory : public ProfileKeyedServiceFactory {
17 public: 19 public:
18 static ResourcePrefetchPredictor* GetForProfile(Profile* profile); 20 static ResourcePrefetchPredictor* GetForProfile(Profile* profile);
19 static ResourcePrefetchPredictorFactory* GetInstance(); 21 static ResourcePrefetchPredictorFactory* GetInstance();
20 22
21 private: 23 private:
22 friend struct DefaultSingletonTraits<ResourcePrefetchPredictorFactory>; 24 friend struct DefaultSingletonTraits<ResourcePrefetchPredictorFactory>;
23 25
24 ResourcePrefetchPredictorFactory(); 26 ResourcePrefetchPredictorFactory();
25 virtual ~ResourcePrefetchPredictorFactory(); 27 virtual ~ResourcePrefetchPredictorFactory();
26 28
27 // RefcountedProfileKeyedServiceFactory: 29 // RefcountedProfileKeyedServiceFactory:
28 virtual ProfileKeyedService* BuildServiceInstanceFor( 30 virtual ProfileKeyedService* BuildServiceInstanceFor(
29 content::BrowserContext* context) const OVERRIDE; 31 content::BrowserContext* context) const OVERRIDE;
30 32
31 DISALLOW_COPY_AND_ASSIGN(ResourcePrefetchPredictorFactory); 33 DISALLOW_COPY_AND_ASSIGN(ResourcePrefetchPredictorFactory);
32 }; 34 };
33 35
34 } // namespace predictors 36 } // namespace predictors
35 37
36 #endif // CHROME_BROWSER_PREDICTORS_RESOURCE_PREFETCH_PREDICTOR_FACTORY_H_ 38 #endif // CHROME_BROWSER_PREDICTORS_RESOURCE_PREFETCH_PREDICTOR_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698