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

Unified Diff: android_webview/glue/java/src/com/android/webview/chromium/ReflectionEndPoint.java

Issue 2760543002: Add a new class as an entry-point for Java reflection (Closed)
Patch Set: 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/glue/BUILD.gn ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: android_webview/glue/java/src/com/android/webview/chromium/ReflectionEndPoint.java
diff --git a/android_webview/glue/java/src/com/android/webview/chromium/ReflectionEndPoint.java b/android_webview/glue/java/src/com/android/webview/chromium/ReflectionEndPoint.java
new file mode 100644
index 0000000000000000000000000000000000000000..654389d765f10d45b2fbfd03bd46717916f66f8a
--- /dev/null
+++ b/android_webview/glue/java/src/com/android/webview/chromium/ReflectionEndPoint.java
@@ -0,0 +1,22 @@
+// 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.
+
+package com.android.webview.chromium;
Torne 2017/03/20 13:35:49 Let's introduce a new package for this since I sus
Nate Fischer 2017/03/20 19:57:48 done
+
+import org.chromium.android_webview.AwContentsStatics;
+import org.chromium.base.annotations.UsedByReflection;
+
+/**
+ * Entry points for reflection into Android WebView internals.
+ *
+ * Methods in this class are not guaranteed to remain, and may be removed when we no longer wish to
Torne 2017/03/20 13:35:49 Might want to be a bit more explicit in the commen
Nate Fischer 2017/03/20 19:57:48 done
+ * expose the functionality.
+ */
+@UsedByReflection("")
Torne 2017/03/20 13:35:49 Since we want to keep everything here, it might be
Nate Fischer 2017/03/20 19:57:48 While I see the advantages to that, I'd still like
+public class ReflectionEndPoint {
Torne 2017/03/20 13:35:49 If we introduce a dedicated package for this then
Nate Fischer 2017/03/20 19:57:48 WebViewConfig SGTM. I'm open to other suggestions
+ @UsedByReflection("")
+ public static void disableSafeBrowsing() {
+ AwContentsStatics.setSafeBrowsingEnabled(false);
+ }
+}
« no previous file with comments | « android_webview/glue/BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698