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

Unified Diff: components/metrics/metrics_service_client.h

Issue 2567263003: Basic UkmService implementation (Closed)
Patch Set: Clang-format Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: components/metrics/metrics_service_client.h
diff --git a/components/metrics/metrics_service_client.h b/components/metrics/metrics_service_client.h
index 6a067afe6b89a79207daf65ca3ea6d5cad013c41..0ef5ff3d038bb1ba51d55646703aad8f9c6fd8a9 100644
--- a/components/metrics/metrics_service_client.h
+++ b/components/metrics/metrics_service_client.h
@@ -20,6 +20,10 @@ namespace base {
class FilePath;
}
+namespace ukm {
+class UkmService;
+}
+
namespace metrics {
class MetricsLogUploader;
@@ -37,6 +41,9 @@ class MetricsServiceClient {
// implementation will own the MetricsService instance being returned).
virtual MetricsService* GetMetricsService() = 0;
+ // Returns the UkmService instance that this client is associated with.
+ virtual ukm::UkmService* GetUkmService() = 0;
Alexei Svitkine (slow) 2017/01/06 16:34:32 There's a bunch of other implementations of Metric
Steven Holte 2017/01/06 20:21:26 Made the default null, added null checks in metric
+
// Registers the client id with other services (e.g. crash reporting), called
// when metrics recording gets enabled.
virtual void SetMetricsClientId(const std::string& client_id) = 0;
@@ -85,6 +92,8 @@ class MetricsServiceClient {
// Creates a MetricsLogUploader with the specified parameters (see comments on
// MetricsLogUploader for details).
virtual std::unique_ptr<MetricsLogUploader> CreateUploader(
+ const std::string& server_url,
+ const std::string& mime_type,
const base::Callback<void(int)>& on_upload_complete) = 0;
// Returns the standard interval between upload attempts.

Powered by Google App Engine
This is Rietveld 408576698