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

Unified Diff: content/public/android/java/src/org/chromium/content/browser/TraceController.java

Issue 11647013: Enable Tracing on content shell for Android (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Extend new class from stdio subscriber. Created 7 years, 12 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: content/public/android/java/src/org/chromium/content/browser/TraceController.java
diff --git a/content/public/android/java/src/org/chromium/content/browser/TraceController.java b/content/public/android/java/src/org/chromium/content/browser/TraceController.java
new file mode 100644
index 0000000000000000000000000000000000000000..587f5f5d072ab8e6c091b4c28bfe4197604feec4
--- /dev/null
+++ b/content/public/android/java/src/org/chromium/content/browser/TraceController.java
@@ -0,0 +1,33 @@
+// Copyright (c) 2012 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.
+
+package org.chromium.content.browser;
+
+import org.chromium.base.JNINamespace;
+
+@JNINamespace("content")
Ted C 2013/01/04 17:40:48 Convention is to put the annotations below the jav
+/**
+ * Handler for tracing related intent.
+ */
+public class TraceController {
Ted C 2013/01/04 17:40:48 I would rename this to TracingIntentHandler as wel
+
+ /**
+ * Begin recording trace events.
+ *
+ * @param path Specifies where the trace data will be saved when tracing is stopped.
+ */
+ public static void beginTracing(String path) {
+ nativeBeginTracing(path);
+ }
+
+ /**
+ * Stop recording trace events, and dump the data to the file
+ */
+ public static void endTracing() {
+ nativeEndTracing();
+ }
+
+ private static native void nativeBeginTracing(String path);
+ private static native void nativeEndTracing();
+}

Powered by Google App Engine
This is Rietveld 408576698