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

Unified Diff: android_webview/native/aw_metrics_log_uploader.h

Issue 2778203003: WebView: Create UMA uploader (Closed)
Patch Set: unimplemnet RegisterAwMetricsLogUploader Created 3 years, 9 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
« no previous file with comments | « android_webview/native/BUILD.gn ('k') | android_webview/native/aw_metrics_log_uploader.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: android_webview/native/aw_metrics_log_uploader.h
diff --git a/android_webview/native/aw_metrics_log_uploader.h b/android_webview/native/aw_metrics_log_uploader.h
new file mode 100644
index 0000000000000000000000000000000000000000..24afdda1896db00d18cf4073abb90c27e3992534
--- /dev/null
+++ b/android_webview/native/aw_metrics_log_uploader.h
@@ -0,0 +1,35 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef ANDROID_WEBVIEW_NATIVE_AW_METRICS_LOG_UPLOADER_H_
+#define ANDROID_WEBVIEW_NATIVE_AW_METRICS_LOG_UPLOADER_H_
+
+#include <jni.h>
+#include <string>
+
+#include "components/metrics/metrics_log_uploader.h"
+
+namespace android_webview {
+
+// Uploads UMA logs for WebView using the platform logging mechanism.
+class AwMetricsLogUploader : public ::metrics::MetricsLogUploader {
+ public:
+ explicit AwMetricsLogUploader(
+ const base::Callback<void(int)>& on_upload_complete);
+
+ ~AwMetricsLogUploader() override;
+
+ // ::metrics::MetricsLogUploader:
+ void UploadLog(const std::string& compressed_log_data,
+ const std::string& log_hash) override;
+
+ private:
+ const base::Callback<void(int)> on_upload_complete_;
+
+ DISALLOW_COPY_AND_ASSIGN(AwMetricsLogUploader);
+};
+
+} // namespace android_webview
+
+#endif // ANDROID_WEBVIEW_NATIVE_AW_METRICS_LOG_UPLOADER_H_
« no previous file with comments | « android_webview/native/BUILD.gn ('k') | android_webview/native/aw_metrics_log_uploader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698