|
|
@@ -1,36 +1,32 @@
|
|
1
|
1
|
/**
|
|
2
|
|
- * Enumeration with the events for the connection.
|
|
3
|
|
- * @type {{string: string}}
|
|
|
2
|
+ * The events for the connection.
|
|
4
|
3
|
*/
|
|
5
|
|
-var JitsiConnnectionEvents = {
|
|
6
|
|
- /**
|
|
7
|
|
- * Indicates that the connection has been failed for some reason. The event
|
|
8
|
|
- * proivdes the following parameters to its listeners:
|
|
9
|
|
- *
|
|
10
|
|
- * @param err {string} the error (message) associated with the failure
|
|
11
|
|
- */
|
|
12
|
|
- CONNECTION_FAILED: "connection.connectionFailed",
|
|
13
|
|
- /**
|
|
14
|
|
- * Indicates that the connection has been established. The event provides
|
|
15
|
|
- * the following parameters to its listeners:
|
|
16
|
|
- *
|
|
17
|
|
- * @param id {string} the ID of the local endpoint/participant/peer (within
|
|
18
|
|
- * the context of the established connection)
|
|
19
|
|
- */
|
|
20
|
|
- CONNECTION_ESTABLISHED: "connection.connectionEstablished",
|
|
21
|
|
- /**
|
|
22
|
|
- * Indicates that the connection has been disconnected. The event provides
|
|
23
|
|
- * the following parameters to its listeners:
|
|
24
|
|
- *
|
|
25
|
|
- * @param msg {string} a message associated with the disconnect such as the
|
|
26
|
|
- * last (known) error message
|
|
27
|
|
- */
|
|
28
|
|
- CONNECTION_DISCONNECTED: "connection.connectionDisconnected",
|
|
29
|
|
- /**
|
|
30
|
|
- * Indicates that the perfomed action cannot be executed because the
|
|
31
|
|
- * connection is not in the correct state(connected, disconnected, etc.)
|
|
32
|
|
- */
|
|
33
|
|
- WRONG_STATE: "connection.wrongState"
|
|
34
|
|
-};
|
|
35
|
4
|
|
|
36
|
|
-module.exports = JitsiConnnectionEvents;
|
|
|
5
|
+/**
|
|
|
6
|
+ * Indicates that the connection has been disconnected. The event provides
|
|
|
7
|
+ * the following parameters to its listeners:
|
|
|
8
|
+ *
|
|
|
9
|
+ * @param msg {string} a message associated with the disconnect such as the
|
|
|
10
|
+ * last (known) error message
|
|
|
11
|
+ */
|
|
|
12
|
+export const CONNECTION_DISCONNECTED = "connection.connectionDisconnected";
|
|
|
13
|
+/**
|
|
|
14
|
+ * Indicates that the connection has been established. The event provides
|
|
|
15
|
+ * the following parameters to its listeners:
|
|
|
16
|
+ *
|
|
|
17
|
+ * @param id {string} the ID of the local endpoint/participant/peer (within
|
|
|
18
|
+ * the context of the established connection)
|
|
|
19
|
+ */
|
|
|
20
|
+export const CONNECTION_ESTABLISHED = "connection.connectionEstablished";
|
|
|
21
|
+/**
|
|
|
22
|
+ * Indicates that the connection has been failed for some reason. The event
|
|
|
23
|
+ * proivdes the following parameters to its listeners:
|
|
|
24
|
+ *
|
|
|
25
|
+ * @param err {string} the error (message) associated with the failure
|
|
|
26
|
+ */
|
|
|
27
|
+export const CONNECTION_FAILED = "connection.connectionFailed";
|
|
|
28
|
+/**
|
|
|
29
|
+ * Indicates that the perfomed action cannot be executed because the
|
|
|
30
|
+ * connection is not in the correct state(connected, disconnected, etc.)
|
|
|
31
|
+ */
|
|
|
32
|
+export const WRONG_STATE = "connection.wrongState";
|