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

Side by Side Diff: chrome/browser/chromeos/policy/policy_cert_service_factory.h

Issue 1308823002: Move Singleton and related structs to namespace base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ToT Created 5 years, 3 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_CHROMEOS_POLICY_POLICY_CERT_SERVICE_FACTORY_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_POLICY_CERT_SERVICE_FACTORY_H_
6 #define CHROME_BROWSER_CHROMEOS_POLICY_POLICY_CERT_SERVICE_FACTORY_H_ 6 #define CHROME_BROWSER_CHROMEOS_POLICY_POLICY_CERT_SERVICE_FACTORY_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
11 #include "base/compiler_specific.h" 11 #include "base/compiler_specific.h"
12 #include "base/memory/scoped_ptr.h" 12 #include "base/memory/scoped_ptr.h"
13 #include "components/keyed_service/content/browser_context_keyed_service_factory .h" 13 #include "components/keyed_service/content/browser_context_keyed_service_factory .h"
14 14
15 template <typename T> struct DefaultSingletonTraits; 15 namespace base {
16 template <typename T>
17 struct DefaultSingletonTraits;
18 } // namespace base
16 19
17 class PrefRegistrySimple; 20 class PrefRegistrySimple;
18 class Profile; 21 class Profile;
19 22
20 namespace policy { 23 namespace policy {
21 24
22 class PolicyCertService; 25 class PolicyCertService;
23 class PolicyCertVerifier; 26 class PolicyCertVerifier;
24 27
25 // Factory to create PolicyCertServices. 28 // Factory to create PolicyCertServices.
(...skipping 16 matching lines...) Expand all
42 45
43 // Used to mark or clear |user_id| as having used certificates pushed by 46 // Used to mark or clear |user_id| as having used certificates pushed by
44 // policy before. 47 // policy before.
45 static void SetUsedPolicyCertificates(const std::string& user_id); 48 static void SetUsedPolicyCertificates(const std::string& user_id);
46 static void ClearUsedPolicyCertificates(const std::string& user_id); 49 static void ClearUsedPolicyCertificates(const std::string& user_id);
47 static bool UsedPolicyCertificates(const std::string& user_id); 50 static bool UsedPolicyCertificates(const std::string& user_id);
48 51
49 static void RegisterPrefs(PrefRegistrySimple* local_state); 52 static void RegisterPrefs(PrefRegistrySimple* local_state);
50 53
51 private: 54 private:
52 friend struct DefaultSingletonTraits<PolicyCertServiceFactory>; 55 friend struct base::DefaultSingletonTraits<PolicyCertServiceFactory>;
53 56
54 PolicyCertServiceFactory(); 57 PolicyCertServiceFactory();
55 ~PolicyCertServiceFactory() override; 58 ~PolicyCertServiceFactory() override;
56 59
57 // BrowserContextKeyedServiceFactory: 60 // BrowserContextKeyedServiceFactory:
58 KeyedService* BuildServiceInstanceFor( 61 KeyedService* BuildServiceInstanceFor(
59 content::BrowserContext* context) const override; 62 content::BrowserContext* context) const override;
60 content::BrowserContext* GetBrowserContextToUse( 63 content::BrowserContext* GetBrowserContextToUse(
61 content::BrowserContext* context) const override; 64 content::BrowserContext* context) const override;
62 void RegisterProfilePrefs( 65 void RegisterProfilePrefs(
63 user_prefs::PrefRegistrySyncable* registry) override; 66 user_prefs::PrefRegistrySyncable* registry) override;
64 bool ServiceIsNULLWhileTesting() const override; 67 bool ServiceIsNULLWhileTesting() const override;
65 68
66 DISALLOW_COPY_AND_ASSIGN(PolicyCertServiceFactory); 69 DISALLOW_COPY_AND_ASSIGN(PolicyCertServiceFactory);
67 }; 70 };
68 71
69 } // namespace policy 72 } // namespace policy
70 73
71 #endif // CHROME_BROWSER_CHROMEOS_POLICY_POLICY_CERT_SERVICE_FACTORY_H_ 74 #endif // CHROME_BROWSER_CHROMEOS_POLICY_POLICY_CERT_SERVICE_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698