@@ -25,14 +25,13 @@ Strophe.addConnectionPlugin('ping', {
25
25
} ,
26
26
27
27
/**
28
- * Function: ping
29
- *
30
- * Parameters:
31
- * (String) to - The JID you want to ping
32
- * (Function) success - Callback function on success
33
- * (Function) error - Callback function on error
34
- * (Integer) timeout - Timeout in milliseconds
35
- */
28
+ * Function: ping
29
+ *
30
+ * @param {string } to - The JID you want to ping
31
+ * @param {function } success - Callback function on success
32
+ * @param {function } error - Callback function on error
33
+ * @param {number } timeout - Timeout in milliseconds
34
+ */
36
35
ping : function ( jid , success , error , timeout ) {
37
36
var id = this . _c . getUniqueId ( 'ping' ) ;
38
37
var iq = $iq ( { type : 'get' , to : jid , id : id } ) . c (
@@ -41,11 +40,10 @@ Strophe.addConnectionPlugin('ping', {
41
40
} ,
42
41
43
42
/**
44
- * Function: pong
45
- *
46
- * Parameters:
47
- * (Object) ping - The ping stanza from the server.
48
- */
43
+ * Function: pong
44
+ *
45
+ * @param {Object } ping - The ping stanza from the server
46
+ */
49
47
pong : function ( ping ) {
50
48
var from = ping . getAttribute ( 'from' ) ;
51
49
var id = ping . getAttribute ( 'id' ) ;
@@ -54,14 +52,12 @@ Strophe.addConnectionPlugin('ping', {
54
52
} ,
55
53
56
54
/**
57
- * Function: addPingHandler
58
- *
59
- * Parameters:
60
- * (Function) handler - Ping handler
61
- *
62
- * Returns:
63
- * A reference to the handler that can be used to remove it.
64
- */
55
+ * Function: addPingHandler
56
+ *
57
+ * @param {Function } handler - Ping handler
58
+ *
59
+ * @returns A reference to the handler that can be used to remove it.
60
+ */
65
61
addPingHandler : function ( handler ) {
66
62
return this . _c . addHandler ( handler , Strophe . NS . PING , "iq" , "get" ) ;
67
63
}
0 commit comments