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

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/webapps/WebApkInstallClientDelegate.java

Issue 2515293004: Chrome talks to Play to install WebAPKs. (Closed)
Patch Set: Move play install-related code out of WebApkInstaller. Created 4 years 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: chrome/android/java/src/org/chromium/chrome/browser/webapps/WebApkInstallClientDelegate.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/webapps/WebApkInstallClientDelegate.java b/chrome/android/java/src/org/chromium/chrome/browser/webapps/WebApkInstallClientDelegate.java
new file mode 100644
index 0000000000000000000000000000000000000000..635cdae9907de1c11b02237f114cad58bf29ab00
--- /dev/null
+++ b/chrome/android/java/src/org/chromium/chrome/browser/webapps/WebApkInstallClientDelegate.java
@@ -0,0 +1,30 @@
+// Copyright 2016 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.chrome.browser.webapps;
+
+import org.chromium.base.Callback;
+
+/**
+ * Define an interface of client delegate which binds to Phonesky's PlayInstallService to install
+ * WebAPKs.
pkotwicz 2016/12/02 02:23:59 How about: "Defines an interface for installing We
Xi Han 2016/12/02 20:45:36 Done.
+ */
pkotwicz 2016/12/02 02:23:59 How about: GooglePlayWebApkInstallDelegate Client
Xi Han 2016/12/02 20:45:36 Done.
+public interface WebApkInstallClientDelegate {
+ /**
+ * Binds to Phonesky's PlayInstallService and installs WebAPKs asynchronously.
pkotwicz 2016/12/02 02:23:59 How about: "Uses Google Play to install WebAPK asy
Xi Han 2016/12/02 20:45:36 Done.
+ * @param packageName The package name of WebAPK to install.
+ * @param version The version of WebAPK to install.
+ * @param title The title of the WebAPK to display during installation.
+ * @param wamToken The token from WebAPK Minter Server.
pkotwicz 2016/12/02 02:23:59 Nit: wamToken -> token People outside of our team
Xi Han 2016/12/02 20:45:36 Done.
+ * @return True if either successfully binded to the PlayInstallService or the install was
+ * started. A "true" return value does not guarantee that the install succeeds.
pkotwicz 2016/12/02 02:23:59 How about: True if the install was started. A "tru
Xi Han 2016/12/02 20:45:36 Well, I think we can count the "bind to the PlayIn
+ */
+ boolean installAsync(String packageName, int version, String title, String wamToken,
+ Callback<Boolean> callback);
+
+ /**
+ * Destroy the delegate, cleaning up any open hooks.
+ */
+ void reset();
pkotwicz 2016/12/02 02:23:59 reset() does not seem to be called by any of the o
Xi Han 2016/12/02 20:45:36 Yes, that is what I find when I am polishing the i
+}

Powered by Google App Engine
This is Rietveld 408576698