Index: remoting/webapp/app_remoting/js/gaia_license_manager.js |
diff --git a/remoting/webapp/app_remoting/js/gaia_license_manager.js b/remoting/webapp/app_remoting/js/gaia_license_manager.js |
new file mode 100644 |
index 0000000000000000000000000000000000000000..af8b48aa3d663f6f96418c6951da1479cdeee43e |
--- /dev/null |
+++ b/remoting/webapp/app_remoting/js/gaia_license_manager.js |
@@ -0,0 +1,38 @@ |
+// Copyright 2015 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. |
+ |
+/** @suppress {duplicate} */ |
+var remoting = remoting || {}; |
+ |
+(function() { |
+ |
+"use strict"; |
+ |
+/** |
+ * A simple implementation of AppRemotingAuth using the user's GAIA token. |
+ * |
+ * @implements{remoting.LicenseManager} |
+ * @constructor |
+ */ |
+remoting.GaiaLicenseManager = function() {}; |
+ |
+/** |
+ * @param {string} oauthToken |
+ * @return {Promise<!string>} |
+ */ |
+remoting.GaiaLicenseManager.prototype.getSubscriptionToken = |
+ function(oauthToken) { |
+ return Promise.resolve(oauthToken); |
+}; |
+ |
+/** |
+ * @param {string} oauthToken |
+ * @return {Promise<!string>} |
+ */ |
+remoting.GaiaLicenseManager.prototype.getAccessToken = function(oauthToken) { |
+ return Promise.resolve(""); |
+}; |
+ |
+})(); |
+ |