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

Side by Side Diff: chrome/browser/invalidation/profile_invalidation_provider_factory.h

Issue 828953004: Add AffiliatedInvalidationServiceProvider (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Style fixes. Created 5 years, 10 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
OLDNEW
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 CHROME_BROWSER_INVALIDATION_PROFILE_INVALIDATION_PROVIDER_FACTORY_H_ 5 #ifndef CHROME_BROWSER_INVALIDATION_PROFILE_INVALIDATION_PROVIDER_FACTORY_H_
6 #define CHROME_BROWSER_INVALIDATION_PROFILE_INVALIDATION_PROVIDER_FACTORY_H_ 6 #define CHROME_BROWSER_INVALIDATION_PROFILE_INVALIDATION_PROVIDER_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 "components/keyed_service/content/browser_context_keyed_service_factory .h" 10 #include "components/keyed_service/content/browser_context_keyed_service_factory .h"
11 11
12 namespace policy { 12 namespace policy {
13 class AffiliatedInvalidationServiceProviderTest;
13 class DeviceCloudPolicyInvalidatorTest; 14 class DeviceCloudPolicyInvalidatorTest;
14 } 15 }
15 16
16 namespace user_prefs { 17 namespace user_prefs {
17 class PrefRegistrySyncable; 18 class PrefRegistrySyncable;
18 } 19 }
19 20
20 namespace syncer { 21 namespace syncer {
21 class Invalidator; 22 class Invalidator;
22 } 23 }
(...skipping 18 matching lines...) Expand all
41 static ProfileInvalidationProvider* GetForProfile(Profile* profile); 42 static ProfileInvalidationProvider* GetForProfile(Profile* profile);
42 43
43 static ProfileInvalidationProviderFactory* GetInstance(); 44 static ProfileInvalidationProviderFactory* GetInstance();
44 45
45 // Switches service creation to go through |testing_factory| for all browser 46 // Switches service creation to go through |testing_factory| for all browser
46 // contexts. 47 // contexts.
47 void RegisterTestingFactory(TestingFactoryFunction testing_factory); 48 void RegisterTestingFactory(TestingFactoryFunction testing_factory);
48 49
49 private: 50 private:
50 friend class ProfileInvalidationProviderFactoryTestBase; 51 friend class ProfileInvalidationProviderFactoryTestBase;
52 friend class policy::AffiliatedInvalidationServiceProviderTest;
51 friend class policy::DeviceCloudPolicyInvalidatorTest; 53 friend class policy::DeviceCloudPolicyInvalidatorTest;
52 friend struct DefaultSingletonTraits<ProfileInvalidationProviderFactory>; 54 friend struct DefaultSingletonTraits<ProfileInvalidationProviderFactory>;
53 55
54 ProfileInvalidationProviderFactory(); 56 ProfileInvalidationProviderFactory();
55 ~ProfileInvalidationProviderFactory() override; 57 ~ProfileInvalidationProviderFactory() override;
56 58
57 // BrowserContextKeyedServiceFactory: 59 // BrowserContextKeyedServiceFactory:
58 KeyedService* BuildServiceInstanceFor( 60 KeyedService* BuildServiceInstanceFor(
59 content::BrowserContext* context) const override; 61 content::BrowserContext* context) const override;
60 void RegisterProfilePrefs( 62 void RegisterProfilePrefs(
61 user_prefs::PrefRegistrySyncable* registry) override; 63 user_prefs::PrefRegistrySyncable* registry) override;
62 64
63 TestingFactoryFunction testing_factory_; 65 TestingFactoryFunction testing_factory_;
64 66
65 DISALLOW_COPY_AND_ASSIGN(ProfileInvalidationProviderFactory); 67 DISALLOW_COPY_AND_ASSIGN(ProfileInvalidationProviderFactory);
66 }; 68 };
67 69
68 } // namespace invalidation 70 } // namespace invalidation
69 71
70 #endif // CHROME_BROWSER_INVALIDATION_PROFILE_INVALIDATION_PROVIDER_FACTORY_H_ 72 #endif // CHROME_BROWSER_INVALIDATION_PROFILE_INVALIDATION_PROVIDER_FACTORY_H_
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/policy/browser_policy_connector_chromeos.cc ('k') | chrome/chrome_browser_chromeos.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698