OLD | NEW |
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 CHROMECAST_METRICS_PLATFORM_METRICS_PROVIDERS_H_ | 5 #ifndef CHROMECAST_METRICS_PLATFORM_METRICS_PROVIDERS_H_ |
6 #define CHROMECAST_METRICS_PLATFORM_METRICS_PROVIDERS_H_ | 6 #define CHROMECAST_METRICS_PLATFORM_METRICS_PROVIDERS_H_ |
7 | 7 |
8 #include "components/metrics/proto/system_profile.pb.h" | 8 #include "components/metrics/proto/system_profile.pb.h" |
9 | 9 |
| 10 namespace metrics { |
10 class MetricsService; | 11 class MetricsService; |
| 12 } |
11 | 13 |
12 namespace chromecast { | 14 namespace chromecast { |
13 namespace metrics { | 15 namespace metrics { |
14 | 16 |
15 // Build-level hook for different platforms to provide data to MetricsService. | 17 // Build-level hook for different platforms to provide data to MetricsService. |
16 void RegisterPlatformMetricsProviders(MetricsService* metrics_service); | 18 void RegisterPlatformMetricsProviders( |
| 19 ::metrics::MetricsService* metrics_service); |
17 | 20 |
18 // Returns the current release channel. | 21 // Returns the current release channel. |
19 ::metrics::SystemProfileProto::Channel GetPlatformReleaseChannel(); | 22 ::metrics::SystemProfileProto::Channel GetPlatformReleaseChannel(); |
20 | 23 |
21 // Returns a string representing this build's version. | 24 // Returns a string representing this build's version. |
22 std::string GetPlatformVersionString(); | 25 std::string GetPlatformVersionString(); |
23 | 26 |
24 // Returns whether or not metrics reporting should be on. | 27 // Returns whether or not metrics reporting should be on. |
25 bool PlatformIsReportingEnabled(); | 28 bool PlatformIsReportingEnabled(); |
26 | 29 |
27 // Called when the UMA client ID has been set. | 30 // Called when the UMA client ID has been set. |
28 void PlatformSetClientID(const std::string& client_id); | 31 void PlatformSetClientID(const std::string& client_id); |
29 | 32 |
30 // Called when an upload has completed. | 33 // Called when an upload has completed. |
31 void PlatformOnLogUploadComplete(); | 34 void PlatformOnLogUploadComplete(); |
32 | 35 |
33 } // namespace metrics | 36 } // namespace metrics |
34 } // namespace chromecast | 37 } // namespace chromecast |
35 | 38 |
36 #endif // CHROMECAST_METRICS_PLATFORM_METRICS_PROVIDERS_H_ | 39 #endif // CHROMECAST_METRICS_PLATFORM_METRICS_PROVIDERS_H_ |
OLD | NEW |