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

Unified Diff: remoting/webapp/crd/js/wcs_adapter.js

Issue 855003008: Log signal strategy progress to server. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 5 years, 11 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 | « remoting/webapp/crd/js/signal_strategy.js ('k') | remoting/webapp/crd/js/xmpp_connection.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/webapp/crd/js/wcs_adapter.js
diff --git a/remoting/webapp/crd/js/wcs_adapter.js b/remoting/webapp/crd/js/wcs_adapter.js
index 34a9b45e0f26365b0ba4e737b790f2c241b3f1c0..d68eaf91a81a4d228ee0113d2fd1525643658e6b 100644
--- a/remoting/webapp/crd/js/wcs_adapter.js
+++ b/remoting/webapp/crd/js/wcs_adapter.js
@@ -25,7 +25,7 @@ remoting.WcsAdapter = function() {
this.jid_ = '';
/** @private */
this.error_ = remoting.Error.NONE;
-}
+};
/**
* @param {function(remoting.SignalStrategy.State):void} onStateChangedCallback
@@ -42,7 +42,7 @@ remoting.WcsAdapter.prototype.setStateChangedCallback = function(
remoting.WcsAdapter.prototype.setIncomingStanzaCallback =
function(onIncomingStanzaCallback) {
this.onIncomingStanzaCallback_ = onIncomingStanzaCallback;
-}
+};
/**
* @param {string} server
@@ -55,27 +55,32 @@ remoting.WcsAdapter.prototype.connect = function(server, username, authToken) {
remoting.wcsSandbox.setOnIq(this.onIncomingStanza_.bind(this));
remoting.wcsSandbox.connect(this.onWcsConnected_.bind(this),
this.onError_.bind(this));
-}
+};
/** @return {remoting.SignalStrategy.State} Current state */
remoting.WcsAdapter.prototype.getState = function() {
return this.state_;
-}
+};
/** @return {remoting.Error} Error when in FAILED state. */
remoting.WcsAdapter.prototype.getError = function() {
return this.error_;
-}
+};
/** @return {string} Current JID when in CONNECTED state. */
remoting.WcsAdapter.prototype.getJid = function() {
return this.jid_;
-}
+};
+
+/** @return {remoting.SignalStrategy.Type} The signal strategy type. */
+remoting.WcsAdapter.prototype.getType = function() {
+ return remoting.SignalStrategy.Type.WCS;
+};
remoting.WcsAdapter.prototype.dispose = function() {
this.setState_(remoting.SignalStrategy.State.CLOSED);
remoting.wcsSandbox.setOnIq(null);
-}
+};
/** @param {string} message */
remoting.WcsAdapter.prototype.sendMessage = function(message) {
@@ -95,13 +100,21 @@ remoting.WcsAdapter.prototype.sendMessage = function(message) {
// Send the stanza.
remoting.wcsSandbox.sendIq(message);
-}
+};
+
+/**
+ * @param {remoting.LogToServer} logToServer The LogToServer instance for the
+ * connection.
+ */
+remoting.WcsAdapter.prototype.sendConnectionSetupResults =
+ function(logToServer) {
+};
/** @param {string} jid */
remoting.WcsAdapter.prototype.onWcsConnected_ = function(jid) {
this.jid_ = jid;
this.setState_(remoting.SignalStrategy.State.CONNECTED);
-}
+};
/** @param {string} stanza */
remoting.WcsAdapter.prototype.onIncomingStanza_ = function(stanza) {
@@ -122,13 +135,13 @@ remoting.WcsAdapter.prototype.onIncomingStanza_ = function(stanza) {
if (this.onIncomingStanzaCallback_) {
this.onIncomingStanzaCallback_(parsed);
}
-}
+};
/** @param {remoting.Error} error */
remoting.WcsAdapter.prototype.onError_ = function(error) {
this.error_ = error;
this.setState_(remoting.SignalStrategy.State.FAILED);
-}
+};
/**
* @param {remoting.SignalStrategy.State} newState
« no previous file with comments | « remoting/webapp/crd/js/signal_strategy.js ('k') | remoting/webapp/crd/js/xmpp_connection.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698