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