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

Side by Side Diff: chrome/browser/metrics/chrome_metrics_service_accessor.h

Issue 603173003: Revert of Remove unneeded Friend from chrome_metrics_service_accessor (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_METRICS_CHROME_METRICS_SERVICE_ACCESSOR_H_ 5 #ifndef CHROME_BROWSER_METRICS_CHROME_METRICS_SERVICE_ACCESSOR_H_
6 #define CHROME_BROWSER_METRICS_CHROME_METRICS_SERVICE_ACCESSOR_H_ 6 #define CHROME_BROWSER_METRICS_CHROME_METRICS_SERVICE_ACCESSOR_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <string> 9 #include <string>
10 10
11 #include "base/gtest_prod_util.h" 11 #include "base/gtest_prod_util.h"
12 #include "base/macros.h" 12 #include "base/macros.h"
13 #include "chrome/browser/metrics/metrics_reporting_state.h" 13 #include "chrome/browser/metrics/metrics_reporting_state.h"
14 #include "chrome/browser/metrics/metrics_service_accessor.h" 14 #include "chrome/browser/metrics/metrics_service_accessor.h"
15 15
16 class ChromeExtensionDownloaderFactory; 16 class ChromeExtensionDownloaderFactory;
17 class PrefService;
17 class Profile; 18 class Profile;
18 19
19 namespace { 20 namespace {
20 class CrashesDOMHandler; 21 class CrashesDOMHandler;
21 class FlashDOMHandler; 22 class FlashDOMHandler;
22 } 23 }
23 24
25 namespace component_updater {
26 class ComponentUpdateService;
27 void RegisterSwReporterComponent(ComponentUpdateService* cus,
28 PrefService* prefs);
29 }
30
24 namespace extensions { 31 namespace extensions {
25 class MetricsPrivateGetIsCrashReportingEnabledFunction; 32 class MetricsPrivateGetIsCrashReportingEnabledFunction;
26 } 33 }
27 34
28 namespace prerender { 35 namespace prerender {
29 bool IsOmniboxEnabled(Profile* profile); 36 bool IsOmniboxEnabled(Profile* profile);
30 } 37 }
31 38
32 namespace system_logs { 39 namespace system_logs {
33 class ChromeInternalLogSource; 40 class ChromeInternalLogSource;
34 } 41 }
35 42
36 namespace options { 43 namespace options {
37 class BrowserOptionsHandler; 44 class BrowserOptionsHandler;
38 } 45 }
39 46
40 // This class limits and documents access to metrics service helper methods. 47 // This class limits and documents access to metrics service helper methods.
41 // Since these methods are private, each user has to be explicitly declared 48 // Since these methods are private, each user has to be explicitly declared
42 // as a 'friend' below. 49 // as a 'friend' below.
43 class ChromeMetricsServiceAccessor : public MetricsServiceAccessor { 50 class ChromeMetricsServiceAccessor : public MetricsServiceAccessor {
44 private: 51 private:
52 friend void component_updater::RegisterSwReporterComponent(
53 component_updater::ComponentUpdateService* cus,
54 PrefService* prefs);
45 friend bool prerender::IsOmniboxEnabled(Profile* profile); 55 friend bool prerender::IsOmniboxEnabled(Profile* profile);
46 friend class ChromeExtensionDownloaderFactory; 56 friend class ChromeExtensionDownloaderFactory;
47 friend class ChromeRenderMessageFilter; 57 friend class ChromeRenderMessageFilter;
48 friend class ::CrashesDOMHandler; 58 friend class ::CrashesDOMHandler;
49 friend class DataReductionProxyChromeSettings; 59 friend class DataReductionProxyChromeSettings;
50 friend class extensions::MetricsPrivateGetIsCrashReportingEnabledFunction; 60 friend class extensions::MetricsPrivateGetIsCrashReportingEnabledFunction;
51 friend class ::FlashDOMHandler; 61 friend class ::FlashDOMHandler;
52 friend class system_logs::ChromeInternalLogSource; 62 friend class system_logs::ChromeInternalLogSource;
53 friend class UmaSessionStats; 63 friend class UmaSessionStats;
54 friend class options::BrowserOptionsHandler; 64 friend class options::BrowserOptionsHandler;
(...skipping 29 matching lines...) Expand all
84 // Same as RegisterSyntheticFieldTrial above, but takes a hash for the trial 94 // Same as RegisterSyntheticFieldTrial above, but takes a hash for the trial
85 // name, rather than computing it from the string. 95 // name, rather than computing it from the string.
86 static bool RegisterSyntheticFieldTrialWithNameHash( 96 static bool RegisterSyntheticFieldTrialWithNameHash(
87 uint32_t trial_name_hash, 97 uint32_t trial_name_hash,
88 const std::string& group_name); 98 const std::string& group_name);
89 99
90 DISALLOW_IMPLICIT_CONSTRUCTORS(ChromeMetricsServiceAccessor); 100 DISALLOW_IMPLICIT_CONSTRUCTORS(ChromeMetricsServiceAccessor);
91 }; 101 };
92 102
93 #endif // CHROME_BROWSER_METRICS_CHROME_METRICS_SERVICE_ACCESSOR_H_ 103 #endif // CHROME_BROWSER_METRICS_CHROME_METRICS_SERVICE_ACCESSOR_H_
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698