@vonage/client-sdk 0.1.3-alpha.16 → 0.1.3-alpha.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Client.d.ts +9 -0
- package/dist/Client.js +14 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +3 -1
- package/dist/kotlin/Kermit-kermit-js-ir.js +53 -52
- package/dist/kotlin/Kermit-kermit-js-ir.js.map +1 -1
- package/dist/kotlin/clientsdk-clientcore.js +10650 -10100
- package/dist/kotlin/clientsdk-clientcore.js.map +1 -1
- package/dist/kotlin/clientsdk-clientcore_js.d.ts +28 -1
- package/dist/kotlin/clientsdk-clientcore_js.js +515 -340
- package/dist/kotlin/clientsdk-clientcore_js.js.map +1 -1
- package/dist/kotlin/kotlin-kotlin-stdlib-js-ir.js +3147 -3796
- package/dist/kotlin/kotlin-kotlin-stdlib-js-ir.js.map +1 -1
- package/dist/kotlin/kotlinx-serialization-kotlinx-serialization-core-js-ir.js +2388 -2579
- package/dist/kotlin/kotlinx-serialization-kotlinx-serialization-core-js-ir.js.map +1 -1
- package/dist/kotlin/kotlinx-serialization-kotlinx-serialization-json-js-ir.js +2065 -2254
- package/dist/kotlin/kotlinx-serialization-kotlinx-serialization-json-js-ir.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,29 +1,38 @@
|
|
|
1
1
|
(function (root, factory) {
|
|
2
2
|
if (typeof define === 'function' && define.amd)
|
|
3
|
-
define(['exports', './kotlin-kotlin-stdlib-js-ir.js'
|
|
3
|
+
define(['exports', './clientsdk-clientcore.js', './kotlin-kotlin-stdlib-js-ir.js'], factory);
|
|
4
4
|
else if (typeof exports === 'object')
|
|
5
|
-
factory(module.exports, require('./
|
|
5
|
+
factory(module.exports, require('./clientsdk-clientcore.js'), require('./kotlin-kotlin-stdlib-js-ir.js'));
|
|
6
6
|
else {
|
|
7
|
-
if (typeof this['kotlin-kotlin-stdlib-js-ir'] === 'undefined') {
|
|
8
|
-
throw new Error("Error loading module 'clientsdk-clientcore_js'. Its dependency 'kotlin-kotlin-stdlib-js-ir' was not found. Please, check whether 'kotlin-kotlin-stdlib-js-ir' is loaded prior to 'clientsdk-clientcore_js'.");
|
|
9
|
-
}
|
|
10
7
|
if (typeof this['clientsdk-clientcore'] === 'undefined') {
|
|
11
8
|
throw new Error("Error loading module 'clientsdk-clientcore_js'. Its dependency 'clientsdk-clientcore' was not found. Please, check whether 'clientsdk-clientcore' is loaded prior to 'clientsdk-clientcore_js'.");
|
|
12
9
|
}
|
|
13
|
-
|
|
10
|
+
if (typeof this['kotlin-kotlin-stdlib-js-ir'] === 'undefined') {
|
|
11
|
+
throw new Error("Error loading module 'clientsdk-clientcore_js'. Its dependency 'kotlin-kotlin-stdlib-js-ir' was not found. Please, check whether 'kotlin-kotlin-stdlib-js-ir' is loaded prior to 'clientsdk-clientcore_js'.");
|
|
12
|
+
}
|
|
13
|
+
root['clientsdk-clientcore_js'] = factory(typeof this['clientsdk-clientcore_js'] === 'undefined' ? {} : this['clientsdk-clientcore_js'], this['clientsdk-clientcore'], this['kotlin-kotlin-stdlib-js-ir']);
|
|
14
14
|
}
|
|
15
|
-
}(this, function (_,
|
|
15
|
+
}(this, function (_, kotlin_com_vonage_clientcore, kotlin_kotlin) {
|
|
16
16
|
'use strict';
|
|
17
17
|
//region block: imports
|
|
18
|
-
var
|
|
18
|
+
var imul = Math.imul;
|
|
19
|
+
var ClientConfigRegion_ASIA_PACIFIC_getInstance = kotlin_com_vonage_clientcore.$_$.p;
|
|
20
|
+
var ClientConfigRegion_EUROPE_getInstance = kotlin_com_vonage_clientcore.$_$.r;
|
|
21
|
+
var ClientConfigRegion_UNITED_STATES_getInstance = kotlin_com_vonage_clientcore.$_$.s;
|
|
22
|
+
var ClientConfigRegion_AUTOMATIC_getInstance = kotlin_com_vonage_clientcore.$_$.q;
|
|
23
|
+
var objectMeta = kotlin_kotlin.$_$.h6;
|
|
24
|
+
var Companion_getInstance = kotlin_com_vonage_clientcore.$_$.t;
|
|
25
|
+
var copyToArray = kotlin_kotlin.$_$.s3;
|
|
19
26
|
var Unit_getInstance = kotlin_kotlin.$_$.o2;
|
|
20
|
-
var SessionListener = kotlin_com_vonage_clientcore.$_$.b;
|
|
21
27
|
var classMeta = kotlin_kotlin.$_$.h5;
|
|
28
|
+
var newThrowable = kotlin_kotlin.$_$.e6;
|
|
29
|
+
var SessionListener = kotlin_com_vonage_clientcore.$_$.b;
|
|
22
30
|
var VoiceClientDelegate = kotlin_com_vonage_clientcore.$_$.c;
|
|
23
31
|
var Builder = kotlin_com_vonage_clientcore.$_$.h;
|
|
24
32
|
var SetConfig = kotlin_com_vonage_clientcore.$_$.g;
|
|
25
33
|
var emptyMap = kotlin_kotlin.$_$.u3;
|
|
26
34
|
var THROW_CCE = kotlin_kotlin.$_$.v7;
|
|
35
|
+
var getStringHashCode = kotlin_kotlin.$_$.m5;
|
|
27
36
|
var equals = kotlin_kotlin.$_$.i5;
|
|
28
37
|
var Exception_init_$Create$ = kotlin_kotlin.$_$.z;
|
|
29
38
|
var HTTPClient = kotlin_com_vonage_clientcore.$_$.d;
|
|
@@ -45,11 +54,103 @@
|
|
|
45
54
|
var isInterface = kotlin_kotlin.$_$.w5;
|
|
46
55
|
var Exception = kotlin_kotlin.$_$.r7;
|
|
47
56
|
var Pair = kotlin_kotlin.$_$.u7;
|
|
48
|
-
var copyToArray = kotlin_kotlin.$_$.s3;
|
|
49
57
|
var json = kotlin_kotlin.$_$.c6;
|
|
50
58
|
//endregion
|
|
51
59
|
//region block: pre-declaration
|
|
52
60
|
//endregion
|
|
61
|
+
function map($this, region) {
|
|
62
|
+
var tmp0_subject = region;
|
|
63
|
+
switch (tmp0_subject) {
|
|
64
|
+
case 'AP':
|
|
65
|
+
return ClientConfigRegion_ASIA_PACIFIC_getInstance();
|
|
66
|
+
case 'EU':
|
|
67
|
+
return ClientConfigRegion_EUROPE_getInstance();
|
|
68
|
+
case 'US':
|
|
69
|
+
return ClientConfigRegion_UNITED_STATES_getInstance();
|
|
70
|
+
default:
|
|
71
|
+
return ClientConfigRegion_AUTOMATIC_getInstance();
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
function Companion() {
|
|
75
|
+
Companion_instance = this;
|
|
76
|
+
}
|
|
77
|
+
Companion.$metadata$ = objectMeta('Companion');
|
|
78
|
+
var Companion_instance;
|
|
79
|
+
function Companion_getInstance_0() {
|
|
80
|
+
if (Companion_instance == null)
|
|
81
|
+
new Companion();
|
|
82
|
+
return Companion_instance;
|
|
83
|
+
}
|
|
84
|
+
function CoreClientConfigJS(region) {
|
|
85
|
+
Companion_getInstance_0();
|
|
86
|
+
this.z2a_1 = Companion_getInstance().v1x(map(Companion_getInstance_0(), region));
|
|
87
|
+
this.a2b_1 = this.z2a_1.y1x_1;
|
|
88
|
+
this.b2b_1 = this.z2a_1.z1x_1;
|
|
89
|
+
this.c2b_1 = this.z2a_1.a1y_1;
|
|
90
|
+
var tmp = this;
|
|
91
|
+
var tmp$ret$0;
|
|
92
|
+
// Inline function 'kotlin.collections.toTypedArray' call
|
|
93
|
+
var tmp0_toTypedArray = this.z2a_1.b1y_1;
|
|
94
|
+
tmp$ret$0 = copyToArray(tmp0_toTypedArray);
|
|
95
|
+
tmp.d2b_1 = tmp$ret$0;
|
|
96
|
+
this.e2b_1 = this.z2a_1.c1y_1;
|
|
97
|
+
}
|
|
98
|
+
CoreClientConfigJS.prototype.f2b = function (_set____db54di) {
|
|
99
|
+
this.a2b_1 = _set____db54di;
|
|
100
|
+
};
|
|
101
|
+
CoreClientConfigJS.prototype.g2b = function () {
|
|
102
|
+
return this.a2b_1;
|
|
103
|
+
};
|
|
104
|
+
CoreClientConfigJS.prototype.h2b = function (_set____db54di) {
|
|
105
|
+
this.b2b_1 = _set____db54di;
|
|
106
|
+
};
|
|
107
|
+
CoreClientConfigJS.prototype.i2b = function () {
|
|
108
|
+
return this.b2b_1;
|
|
109
|
+
};
|
|
110
|
+
CoreClientConfigJS.prototype.j2b = function (_set____db54di) {
|
|
111
|
+
this.c2b_1 = _set____db54di;
|
|
112
|
+
};
|
|
113
|
+
CoreClientConfigJS.prototype.k2b = function () {
|
|
114
|
+
return this.c2b_1;
|
|
115
|
+
};
|
|
116
|
+
CoreClientConfigJS.prototype.l2b = function (_set____db54di) {
|
|
117
|
+
this.d2b_1 = _set____db54di;
|
|
118
|
+
};
|
|
119
|
+
CoreClientConfigJS.prototype.m2b = function () {
|
|
120
|
+
return this.d2b_1;
|
|
121
|
+
};
|
|
122
|
+
CoreClientConfigJS.prototype.n2b = function (_set____db54di) {
|
|
123
|
+
this.e2b_1 = _set____db54di;
|
|
124
|
+
};
|
|
125
|
+
CoreClientConfigJS.prototype.o2b = function () {
|
|
126
|
+
return this.e2b_1;
|
|
127
|
+
};
|
|
128
|
+
CoreClientConfigJS.$metadata$ = classMeta('CoreClientConfigJS');
|
|
129
|
+
Object.defineProperty(CoreClientConfigJS.prototype, 'apiUrl', {
|
|
130
|
+
configurable: true,
|
|
131
|
+
get: CoreClientConfigJS.prototype.g2b,
|
|
132
|
+
set: CoreClientConfigJS.prototype.f2b
|
|
133
|
+
});
|
|
134
|
+
Object.defineProperty(CoreClientConfigJS.prototype, 'websocketUrl', {
|
|
135
|
+
configurable: true,
|
|
136
|
+
get: CoreClientConfigJS.prototype.i2b,
|
|
137
|
+
set: CoreClientConfigJS.prototype.h2b
|
|
138
|
+
});
|
|
139
|
+
Object.defineProperty(CoreClientConfigJS.prototype, 'websocketPath', {
|
|
140
|
+
configurable: true,
|
|
141
|
+
get: CoreClientConfigJS.prototype.k2b,
|
|
142
|
+
set: CoreClientConfigJS.prototype.j2b
|
|
143
|
+
});
|
|
144
|
+
Object.defineProperty(CoreClientConfigJS.prototype, 'iceServerUrls', {
|
|
145
|
+
configurable: true,
|
|
146
|
+
get: CoreClientConfigJS.prototype.m2b,
|
|
147
|
+
set: CoreClientConfigJS.prototype.l2b
|
|
148
|
+
});
|
|
149
|
+
Object.defineProperty(CoreClientConfigJS.prototype, 'autoMediaReoffer', {
|
|
150
|
+
configurable: true,
|
|
151
|
+
get: CoreClientConfigJS.prototype.o2b,
|
|
152
|
+
set: CoreClientConfigJS.prototype.n2b
|
|
153
|
+
});
|
|
53
154
|
function CoreClientJS$createSession$lambda$lambda($reject, $resolve) {
|
|
54
155
|
return function (err, sessionId) {
|
|
55
156
|
if (!(err == null))
|
|
@@ -63,7 +164,7 @@
|
|
|
63
164
|
}
|
|
64
165
|
function CoreClientJS$createSession$lambda(this$0, $token, $sessionId) {
|
|
65
166
|
return function (resolve, reject) {
|
|
66
|
-
this$0.
|
|
167
|
+
this$0.q2b_1.r1a($token, $sessionId, CoreClientJS$createSession$lambda$lambda(reject, resolve));
|
|
67
168
|
return Unit_getInstance();
|
|
68
169
|
};
|
|
69
170
|
}
|
|
@@ -78,7 +179,7 @@
|
|
|
78
179
|
}
|
|
79
180
|
function CoreClientJS$deleteSession$lambda(this$0) {
|
|
80
181
|
return function (resolve, reject) {
|
|
81
|
-
this$0.
|
|
182
|
+
this$0.q2b_1.s1a(CoreClientJS$deleteSession$lambda$lambda(reject, resolve));
|
|
82
183
|
return Unit_getInstance();
|
|
83
184
|
};
|
|
84
185
|
}
|
|
@@ -93,7 +194,7 @@
|
|
|
93
194
|
}
|
|
94
195
|
function CoreClientJS$refreshSession$lambda(this$0, $token) {
|
|
95
196
|
return function (resolve, reject) {
|
|
96
|
-
this$0.
|
|
197
|
+
this$0.q2b_1.t1a($token, CoreClientJS$refreshSession$lambda$lambda(reject, resolve));
|
|
97
198
|
return Unit_getInstance();
|
|
98
199
|
};
|
|
99
200
|
}
|
|
@@ -111,31 +212,31 @@
|
|
|
111
212
|
}
|
|
112
213
|
function CoreClientJS$serverCall$lambda(this$0, $typedContext) {
|
|
113
214
|
return function (resolve, reject) {
|
|
114
|
-
this$0.
|
|
215
|
+
this$0.q2b_1.w1a($typedContext, CoreClientJS$serverCall$lambda$lambda(resolve, reject));
|
|
115
216
|
return Unit_getInstance();
|
|
116
217
|
};
|
|
117
218
|
}
|
|
118
219
|
function CoreClientJS$1(this$0) {
|
|
119
|
-
this.
|
|
220
|
+
this.r2b_1 = this$0;
|
|
120
221
|
}
|
|
121
|
-
CoreClientJS$1.prototype.
|
|
122
|
-
var tmp0_safe_receiver = this.
|
|
222
|
+
CoreClientJS$1.prototype.g1z = function () {
|
|
223
|
+
var tmp0_safe_receiver = this.r2b_1.p2b_1;
|
|
123
224
|
if (tmp0_safe_receiver == null)
|
|
124
225
|
null;
|
|
125
226
|
else {
|
|
126
227
|
tmp0_safe_receiver.reconnecting();
|
|
127
228
|
}
|
|
128
229
|
};
|
|
129
|
-
CoreClientJS$1.prototype.
|
|
130
|
-
var tmp0_safe_receiver = this.
|
|
230
|
+
CoreClientJS$1.prototype.h1z = function () {
|
|
231
|
+
var tmp0_safe_receiver = this.r2b_1.p2b_1;
|
|
131
232
|
if (tmp0_safe_receiver == null)
|
|
132
233
|
null;
|
|
133
234
|
else {
|
|
134
235
|
tmp0_safe_receiver.reconnection();
|
|
135
236
|
}
|
|
136
237
|
};
|
|
137
|
-
CoreClientJS$1.prototype.
|
|
138
|
-
var tmp0_safe_receiver = this.
|
|
238
|
+
CoreClientJS$1.prototype.i1z = function (reason) {
|
|
239
|
+
var tmp0_safe_receiver = this.r2b_1.p2b_1;
|
|
139
240
|
if (tmp0_safe_receiver == null)
|
|
140
241
|
null;
|
|
141
242
|
else {
|
|
@@ -144,55 +245,63 @@
|
|
|
144
245
|
};
|
|
145
246
|
CoreClientJS$1.$metadata$ = classMeta(undefined, [SessionListener]);
|
|
146
247
|
function CoreClientJS$2(this$0) {
|
|
147
|
-
this.
|
|
248
|
+
this.s2b_1 = this$0;
|
|
148
249
|
}
|
|
149
|
-
CoreClientJS$2.prototype.
|
|
150
|
-
var tmp0_safe_receiver = this.
|
|
250
|
+
CoreClientJS$2.prototype.t20 = function (invite) {
|
|
251
|
+
var tmp0_safe_receiver = this.s2b_1.p2b_1;
|
|
151
252
|
if (tmp0_safe_receiver == null)
|
|
152
253
|
null;
|
|
153
254
|
else {
|
|
154
|
-
tmp0_safe_receiver.callInvite(
|
|
255
|
+
tmp0_safe_receiver.callInvite(VoiceInviteJS_init_$Create$(invite, null, 2, null));
|
|
155
256
|
}
|
|
156
257
|
};
|
|
157
|
-
CoreClientJS$2.prototype.
|
|
158
|
-
var tmp0_safe_receiver = this.
|
|
258
|
+
CoreClientJS$2.prototype.u20 = function (call, newConversation, prevConversation) {
|
|
259
|
+
var tmp0_safe_receiver = this.s2b_1.p2b_1;
|
|
159
260
|
if (tmp0_safe_receiver == null)
|
|
160
261
|
null;
|
|
161
262
|
else {
|
|
162
263
|
tmp0_safe_receiver.callTransfer(new VoiceCallJS(call), new ConversationJS(newConversation), new ConversationJS(prevConversation));
|
|
163
264
|
}
|
|
164
265
|
};
|
|
165
|
-
CoreClientJS$2.prototype.
|
|
166
|
-
var tmp0_safe_receiver = this.
|
|
266
|
+
CoreClientJS$2.prototype.v20 = function (call, legId, isMuted) {
|
|
267
|
+
var tmp0_safe_receiver = this.s2b_1.p2b_1;
|
|
167
268
|
if (tmp0_safe_receiver == null)
|
|
168
269
|
null;
|
|
169
270
|
else {
|
|
170
271
|
tmp0_safe_receiver.mute(new VoiceCallJS(call), legId, isMuted);
|
|
171
272
|
}
|
|
172
273
|
};
|
|
173
|
-
CoreClientJS$2.prototype.
|
|
174
|
-
var tmp0_safe_receiver = this.
|
|
274
|
+
CoreClientJS$2.prototype.w20 = function (call, legId, earmuffStatus) {
|
|
275
|
+
var tmp0_safe_receiver = this.s2b_1.p2b_1;
|
|
175
276
|
if (tmp0_safe_receiver == null)
|
|
176
277
|
null;
|
|
177
278
|
else {
|
|
178
279
|
tmp0_safe_receiver.earmuff(new VoiceCallJS(call), legId, earmuffStatus);
|
|
179
280
|
}
|
|
180
281
|
};
|
|
282
|
+
CoreClientJS$2.prototype.x20 = function (call, legId, digits) {
|
|
283
|
+
var tmp0_safe_receiver = this.s2b_1.p2b_1;
|
|
284
|
+
if (tmp0_safe_receiver == null)
|
|
285
|
+
null;
|
|
286
|
+
else {
|
|
287
|
+
tmp0_safe_receiver.dtmf(new VoiceCallJS(call), legId, digits);
|
|
288
|
+
}
|
|
289
|
+
};
|
|
181
290
|
CoreClientJS$2.$metadata$ = classMeta(undefined, [VoiceClientDelegate]);
|
|
182
291
|
function CoreClientJS(http, socket, media) {
|
|
183
|
-
this.
|
|
184
|
-
this.
|
|
185
|
-
this.
|
|
186
|
-
this.
|
|
292
|
+
this.p2b_1 = null;
|
|
293
|
+
this.q2b_1 = (new Builder()).u1b(HttpClientJSAdapter(http)).v1b(SocketClientJSAdapter(socket)).w1b(MediaClientJSAdapter(media));
|
|
294
|
+
this.q2b_1.u1a(new CoreClientJS$1(this));
|
|
295
|
+
this.q2b_1.v1a(new CoreClientJS$2(this));
|
|
187
296
|
}
|
|
188
|
-
CoreClientJS.prototype.
|
|
189
|
-
this.
|
|
297
|
+
CoreClientJS.prototype.t2b = function (_set____db54di) {
|
|
298
|
+
this.p2b_1 = _set____db54di;
|
|
190
299
|
};
|
|
191
|
-
CoreClientJS.prototype.
|
|
192
|
-
return this.
|
|
300
|
+
CoreClientJS.prototype.u2b = function () {
|
|
301
|
+
return this.p2b_1;
|
|
193
302
|
};
|
|
194
|
-
CoreClientJS.prototype.setConfig = function (
|
|
195
|
-
this.
|
|
303
|
+
CoreClientJS.prototype.setConfig = function (config) {
|
|
304
|
+
this.q2b_1.q1a(new SetConfig(config.b2b_1, config.c2b_1, config.a2b_1));
|
|
196
305
|
};
|
|
197
306
|
CoreClientJS.prototype.createSession = function (token, sessionId) {
|
|
198
307
|
return new Promise(CoreClientJS$createSession$lambda(this, token, sessionId));
|
|
@@ -209,9 +318,8 @@
|
|
|
209
318
|
var tmp;
|
|
210
319
|
if (tmp1_elvis_lhs == null) {
|
|
211
320
|
var tmp$ret$0;
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
}
|
|
321
|
+
// Inline function 'kotlin.collections.mapOf' call
|
|
322
|
+
tmp$ret$0 = emptyMap();
|
|
215
323
|
tmp = tmp$ret$0;
|
|
216
324
|
} else {
|
|
217
325
|
tmp = tmp1_elvis_lhs;
|
|
@@ -222,8 +330,8 @@
|
|
|
222
330
|
CoreClientJS.$metadata$ = classMeta('CoreClientJS');
|
|
223
331
|
Object.defineProperty(CoreClientJS.prototype, 'emitter', {
|
|
224
332
|
configurable: true,
|
|
225
|
-
get: CoreClientJS.prototype.
|
|
226
|
-
set: CoreClientJS.prototype.
|
|
333
|
+
get: CoreClientJS.prototype.u2b,
|
|
334
|
+
set: CoreClientJS.prototype.t2b
|
|
227
335
|
});
|
|
228
336
|
function VoiceCallJS$hangup$lambda$lambda($resolve, $reject) {
|
|
229
337
|
return function (it) {
|
|
@@ -238,7 +346,7 @@
|
|
|
238
346
|
}
|
|
239
347
|
function VoiceCallJS$hangup$lambda(this$0) {
|
|
240
348
|
return function (resolve, reject) {
|
|
241
|
-
this$0.
|
|
349
|
+
this$0.v2b_1.c20(VoiceCallJS$hangup$lambda$lambda(resolve, reject));
|
|
242
350
|
return Unit_getInstance();
|
|
243
351
|
};
|
|
244
352
|
}
|
|
@@ -266,7 +374,7 @@
|
|
|
266
374
|
var tmp_3 = tmp3_elvis_lhs == null ? 'amy' : tmp3_elvis_lhs;
|
|
267
375
|
var tmp4_elvis_lhs = get_jsonNullable($params.ssml);
|
|
268
376
|
var tmp_4 = tmp4_elvis_lhs == null ? true : tmp4_elvis_lhs;
|
|
269
|
-
this$0.
|
|
377
|
+
this$0.v2b_1.s20(tmp, tmp_0, tmp_1, tmp_2, tmp_3, tmp_4, VoiceCallJS$say$lambda$lambda(reject, resolve));
|
|
270
378
|
return Unit_getInstance();
|
|
271
379
|
};
|
|
272
380
|
}
|
|
@@ -283,7 +391,7 @@
|
|
|
283
391
|
}
|
|
284
392
|
function VoiceCallJS$mute$lambda(this$0) {
|
|
285
393
|
return function (resolve, reject) {
|
|
286
|
-
this$0.
|
|
394
|
+
this$0.v2b_1.n20(VoiceCallJS$mute$lambda$lambda(reject, resolve));
|
|
287
395
|
return Unit_getInstance();
|
|
288
396
|
};
|
|
289
397
|
}
|
|
@@ -298,7 +406,7 @@
|
|
|
298
406
|
}
|
|
299
407
|
function VoiceCallJS$unmute$lambda(this$0) {
|
|
300
408
|
return function (resolve, reject) {
|
|
301
|
-
this$0.
|
|
409
|
+
this$0.v2b_1.o20(VoiceCallJS$unmute$lambda$lambda(reject, resolve));
|
|
302
410
|
return Unit_getInstance();
|
|
303
411
|
};
|
|
304
412
|
}
|
|
@@ -313,7 +421,7 @@
|
|
|
313
421
|
}
|
|
314
422
|
function VoiceCallJS$enableEarmuff$lambda(this$0) {
|
|
315
423
|
return function (resolve, reject) {
|
|
316
|
-
this$0.
|
|
424
|
+
this$0.v2b_1.p20(VoiceCallJS$enableEarmuff$lambda$lambda(reject, resolve));
|
|
317
425
|
return Unit_getInstance();
|
|
318
426
|
};
|
|
319
427
|
}
|
|
@@ -328,16 +436,31 @@
|
|
|
328
436
|
}
|
|
329
437
|
function VoiceCallJS$disableEarmuff$lambda(this$0) {
|
|
330
438
|
return function (resolve, reject) {
|
|
331
|
-
this$0.
|
|
439
|
+
this$0.v2b_1.q20(VoiceCallJS$disableEarmuff$lambda$lambda(reject, resolve));
|
|
440
|
+
return Unit_getInstance();
|
|
441
|
+
};
|
|
442
|
+
}
|
|
443
|
+
function VoiceCallJS$sendDTMF$lambda$lambda($reject, $resolve) {
|
|
444
|
+
return function (it) {
|
|
445
|
+
if (!(it == null))
|
|
446
|
+
$reject(it);
|
|
447
|
+
else
|
|
448
|
+
$resolve(null);
|
|
449
|
+
return Unit_getInstance();
|
|
450
|
+
};
|
|
451
|
+
}
|
|
452
|
+
function VoiceCallJS$sendDTMF$lambda(this$0, $digits) {
|
|
453
|
+
return function (resolve, reject) {
|
|
454
|
+
this$0.v2b_1.r20($digits, VoiceCallJS$sendDTMF$lambda$lambda(reject, resolve));
|
|
332
455
|
return Unit_getInstance();
|
|
333
456
|
};
|
|
334
457
|
}
|
|
335
458
|
function VoiceCallJS(call) {
|
|
336
|
-
this.
|
|
337
|
-
this.
|
|
459
|
+
this.v2b_1 = call;
|
|
460
|
+
this.w2b_1 = this.v2b_1.v1z_1;
|
|
338
461
|
}
|
|
339
|
-
VoiceCallJS.prototype.
|
|
340
|
-
return this.
|
|
462
|
+
VoiceCallJS.prototype.h1k = function () {
|
|
463
|
+
return this.w2b_1;
|
|
341
464
|
};
|
|
342
465
|
VoiceCallJS.prototype.hangup = function () {
|
|
343
466
|
return new Promise(VoiceCallJS$hangup$lambda(this));
|
|
@@ -357,11 +480,81 @@
|
|
|
357
480
|
VoiceCallJS.prototype.disableEarmuff = function () {
|
|
358
481
|
return new Promise(VoiceCallJS$disableEarmuff$lambda(this));
|
|
359
482
|
};
|
|
483
|
+
VoiceCallJS.prototype.sendDTMF = function (digits) {
|
|
484
|
+
return new Promise(VoiceCallJS$sendDTMF$lambda(this, digits));
|
|
485
|
+
};
|
|
360
486
|
VoiceCallJS.$metadata$ = classMeta('VoiceCallJS');
|
|
361
487
|
Object.defineProperty(VoiceCallJS.prototype, 'id', {
|
|
362
488
|
configurable: true,
|
|
363
|
-
get: VoiceCallJS.prototype.
|
|
489
|
+
get: VoiceCallJS.prototype.h1k
|
|
364
490
|
});
|
|
491
|
+
function VoiceInviteFromInfoJS(id, type) {
|
|
492
|
+
this.x2b_1 = id;
|
|
493
|
+
this.y2b_1 = type;
|
|
494
|
+
}
|
|
495
|
+
VoiceInviteFromInfoJS.prototype.h1k = function () {
|
|
496
|
+
return this.x2b_1;
|
|
497
|
+
};
|
|
498
|
+
VoiceInviteFromInfoJS.prototype.z2b = function () {
|
|
499
|
+
return this.y2b_1;
|
|
500
|
+
};
|
|
501
|
+
VoiceInviteFromInfoJS.prototype.component1 = function () {
|
|
502
|
+
return this.x2b_1;
|
|
503
|
+
};
|
|
504
|
+
VoiceInviteFromInfoJS.prototype.component2 = function () {
|
|
505
|
+
return this.y2b_1;
|
|
506
|
+
};
|
|
507
|
+
VoiceInviteFromInfoJS.prototype.copy = function (id, type) {
|
|
508
|
+
return this.a2c(id === void 1 ? this.x2b_1 : id, type === void 1 ? this.y2b_1 : type);
|
|
509
|
+
};
|
|
510
|
+
VoiceInviteFromInfoJS.prototype.a2c = function (id, type) {
|
|
511
|
+
return new VoiceInviteFromInfoJS(id, type);
|
|
512
|
+
};
|
|
513
|
+
VoiceInviteFromInfoJS.prototype.b2c = function (id, type, $mask0, $handler) {
|
|
514
|
+
if (!(($mask0 & 1) === 0))
|
|
515
|
+
id = this.x2b_1;
|
|
516
|
+
if (!(($mask0 & 2) === 0))
|
|
517
|
+
type = this.y2b_1;
|
|
518
|
+
return this.a2c(id, type);
|
|
519
|
+
};
|
|
520
|
+
VoiceInviteFromInfoJS.prototype.toString = function () {
|
|
521
|
+
return 'VoiceInviteFromInfoJS(id=' + this.x2b_1 + ', type=' + this.y2b_1 + ')';
|
|
522
|
+
};
|
|
523
|
+
VoiceInviteFromInfoJS.prototype.hashCode = function () {
|
|
524
|
+
var result = this.x2b_1 == null ? 0 : getStringHashCode(this.x2b_1);
|
|
525
|
+
result = imul(result, 31) + getStringHashCode(this.y2b_1) | 0;
|
|
526
|
+
return result;
|
|
527
|
+
};
|
|
528
|
+
VoiceInviteFromInfoJS.prototype.equals = function (other) {
|
|
529
|
+
if (this === other)
|
|
530
|
+
return true;
|
|
531
|
+
if (!(other instanceof VoiceInviteFromInfoJS))
|
|
532
|
+
return false;
|
|
533
|
+
var tmp0_other_with_cast = other instanceof VoiceInviteFromInfoJS ? other : THROW_CCE();
|
|
534
|
+
if (!(this.x2b_1 == tmp0_other_with_cast.x2b_1))
|
|
535
|
+
return false;
|
|
536
|
+
if (!(this.y2b_1 === tmp0_other_with_cast.y2b_1))
|
|
537
|
+
return false;
|
|
538
|
+
return true;
|
|
539
|
+
};
|
|
540
|
+
VoiceInviteFromInfoJS.$metadata$ = classMeta('VoiceInviteFromInfoJS');
|
|
541
|
+
Object.defineProperty(VoiceInviteFromInfoJS.prototype, 'id', {
|
|
542
|
+
configurable: true,
|
|
543
|
+
get: VoiceInviteFromInfoJS.prototype.h1k
|
|
544
|
+
});
|
|
545
|
+
Object.defineProperty(VoiceInviteFromInfoJS.prototype, 'type', {
|
|
546
|
+
configurable: true,
|
|
547
|
+
get: VoiceInviteFromInfoJS.prototype.z2b
|
|
548
|
+
});
|
|
549
|
+
function VoiceInviteJS_init_$Init$(invite, from, $mask0, $marker, $this) {
|
|
550
|
+
if (!(($mask0 & 2) === 0))
|
|
551
|
+
from = new VoiceInviteFromInfoJS(invite.a21_1.f21_1, invite.a21_1.g21_1);
|
|
552
|
+
VoiceInviteJS.call($this, invite, from);
|
|
553
|
+
return $this;
|
|
554
|
+
}
|
|
555
|
+
function VoiceInviteJS_init_$Create$(invite, from, $mask0, $marker) {
|
|
556
|
+
return VoiceInviteJS_init_$Init$(invite, from, $mask0, $marker, Object.create(VoiceInviteJS.prototype));
|
|
557
|
+
}
|
|
365
558
|
function VoiceInviteJS$answerCall$lambda$lambda($reject, $resolve) {
|
|
366
559
|
return function (err, call) {
|
|
367
560
|
var tmp;
|
|
@@ -377,7 +570,7 @@
|
|
|
377
570
|
}
|
|
378
571
|
function VoiceInviteJS$answerCall$lambda(this$0) {
|
|
379
572
|
return function (resolve, reject) {
|
|
380
|
-
this$0.
|
|
573
|
+
this$0.c2c_1.b21(VoiceInviteJS$answerCall$lambda$lambda(reject, resolve));
|
|
381
574
|
return Unit_getInstance();
|
|
382
575
|
};
|
|
383
576
|
}
|
|
@@ -394,13 +587,17 @@
|
|
|
394
587
|
}
|
|
395
588
|
function VoiceInviteJS$rejectCall$lambda(this$0) {
|
|
396
589
|
return function (resolve, reject) {
|
|
397
|
-
this$0.
|
|
590
|
+
this$0.c2c_1.e21(VoiceInviteJS$rejectCall$lambda$lambda(reject, resolve));
|
|
398
591
|
return Unit_getInstance();
|
|
399
592
|
};
|
|
400
593
|
}
|
|
401
|
-
function VoiceInviteJS(invite) {
|
|
402
|
-
this.
|
|
594
|
+
function VoiceInviteJS(invite, from) {
|
|
595
|
+
this.c2c_1 = invite;
|
|
596
|
+
this.d2c_1 = from;
|
|
403
597
|
}
|
|
598
|
+
VoiceInviteJS.prototype.o1j = function () {
|
|
599
|
+
return this.d2c_1;
|
|
600
|
+
};
|
|
404
601
|
VoiceInviteJS.prototype.answerCall = function () {
|
|
405
602
|
return new Promise(VoiceInviteJS$answerCall$lambda(this));
|
|
406
603
|
};
|
|
@@ -408,32 +605,36 @@
|
|
|
408
605
|
return new Promise(VoiceInviteJS$rejectCall$lambda(this));
|
|
409
606
|
};
|
|
410
607
|
VoiceInviteJS.$metadata$ = classMeta('VoiceInviteJS');
|
|
608
|
+
Object.defineProperty(VoiceInviteJS.prototype, 'from', {
|
|
609
|
+
configurable: true,
|
|
610
|
+
get: VoiceInviteJS.prototype.o1j
|
|
611
|
+
});
|
|
411
612
|
function ConversationJS(conversation) {
|
|
412
|
-
this.
|
|
413
|
-
this.
|
|
613
|
+
this.e2c_1 = conversation;
|
|
614
|
+
this.f2c_1 = this.e2c_1.d1y_1;
|
|
414
615
|
}
|
|
415
|
-
ConversationJS.prototype.
|
|
416
|
-
this.
|
|
616
|
+
ConversationJS.prototype.g2c = function (_set____db54di) {
|
|
617
|
+
this.f2c_1 = _set____db54di;
|
|
417
618
|
};
|
|
418
|
-
ConversationJS.prototype.
|
|
419
|
-
return this.
|
|
619
|
+
ConversationJS.prototype.h1k = function () {
|
|
620
|
+
return this.f2c_1;
|
|
420
621
|
};
|
|
421
622
|
ConversationJS.prototype.copy = function (conversation) {
|
|
422
|
-
return this.
|
|
623
|
+
return this.h2c(conversation === void 1 ? this.e2c_1 : conversation);
|
|
423
624
|
};
|
|
424
|
-
ConversationJS.prototype.
|
|
625
|
+
ConversationJS.prototype.h2c = function (conversation) {
|
|
425
626
|
return new ConversationJS(conversation);
|
|
426
627
|
};
|
|
427
|
-
ConversationJS.prototype.
|
|
628
|
+
ConversationJS.prototype.i2c = function (conversation, $mask0, $handler) {
|
|
428
629
|
if (!(($mask0 & 1) === 0))
|
|
429
|
-
conversation = this.
|
|
430
|
-
return this.
|
|
630
|
+
conversation = this.e2c_1;
|
|
631
|
+
return this.h2c(conversation);
|
|
431
632
|
};
|
|
432
633
|
ConversationJS.prototype.toString = function () {
|
|
433
|
-
return 'ConversationJS(conversation=' + this.
|
|
634
|
+
return 'ConversationJS(conversation=' + this.e2c_1 + ')';
|
|
434
635
|
};
|
|
435
636
|
ConversationJS.prototype.hashCode = function () {
|
|
436
|
-
return this.
|
|
637
|
+
return this.e2c_1.hashCode();
|
|
437
638
|
};
|
|
438
639
|
ConversationJS.prototype.equals = function (other) {
|
|
439
640
|
if (this === other)
|
|
@@ -441,15 +642,15 @@
|
|
|
441
642
|
if (!(other instanceof ConversationJS))
|
|
442
643
|
return false;
|
|
443
644
|
var tmp0_other_with_cast = other instanceof ConversationJS ? other : THROW_CCE();
|
|
444
|
-
if (!this.
|
|
645
|
+
if (!this.e2c_1.equals(tmp0_other_with_cast.e2c_1))
|
|
445
646
|
return false;
|
|
446
647
|
return true;
|
|
447
648
|
};
|
|
448
649
|
ConversationJS.$metadata$ = classMeta('ConversationJS');
|
|
449
650
|
Object.defineProperty(ConversationJS.prototype, 'id', {
|
|
450
651
|
configurable: true,
|
|
451
|
-
get: ConversationJS.prototype.
|
|
452
|
-
set: ConversationJS.prototype.
|
|
652
|
+
get: ConversationJS.prototype.h1k,
|
|
653
|
+
set: ConversationJS.prototype.g2c
|
|
453
654
|
});
|
|
454
655
|
function get_jsonNullable(_this__u8e3s4) {
|
|
455
656
|
var tmp0_subject = _this__u8e3s4;
|
|
@@ -506,22 +707,19 @@
|
|
|
506
707
|
};
|
|
507
708
|
}
|
|
508
709
|
function HttpClientJSAdapter$1($js) {
|
|
509
|
-
this.
|
|
710
|
+
this.j2c_1 = $js;
|
|
510
711
|
}
|
|
511
|
-
HttpClientJSAdapter$1.prototype.
|
|
712
|
+
HttpClientJSAdapter$1.prototype.c1b = function (verb, url, headers, body, callback) {
|
|
512
713
|
var tmp = verb.toString();
|
|
513
714
|
var tmp$ret$1;
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
}
|
|
521
|
-
tmp$ret$1 = tmp$ret$0;
|
|
522
|
-
}
|
|
715
|
+
// Inline function 'kotlin.let' call
|
|
716
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
717
|
+
var tmp$ret$0;
|
|
718
|
+
// Inline function 'vonage.<no name provided>.request.<anonymous>' call
|
|
719
|
+
tmp$ret$0 = fromMap(JSON, headers);
|
|
720
|
+
tmp$ret$1 = tmp$ret$0;
|
|
523
721
|
var tmp_0 = tmp$ret$1;
|
|
524
|
-
this.
|
|
722
|
+
this.j2c_1.request(tmp, url, tmp_0, body, HttpClientJSAdapter$o$request$lambda(callback));
|
|
525
723
|
};
|
|
526
724
|
HttpClientJSAdapter$1.$metadata$ = classMeta(undefined, [HTTPClient]);
|
|
527
725
|
function SocketClientJSAdapter$o$emit$lambda($callback) {
|
|
@@ -532,15 +730,12 @@
|
|
|
532
730
|
tmp = null;
|
|
533
731
|
} else {
|
|
534
732
|
var tmp$ret$1;
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
}
|
|
542
|
-
tmp$ret$1 = tmp$ret$0;
|
|
543
|
-
}
|
|
733
|
+
// Inline function 'kotlin.let' call
|
|
734
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
735
|
+
var tmp$ret$0;
|
|
736
|
+
// Inline function 'vonage.<no name provided>.emit.<anonymous>.<anonymous>' call
|
|
737
|
+
tmp$ret$0 = Exception_init_$Create$(err);
|
|
738
|
+
tmp$ret$1 = tmp$ret$0;
|
|
544
739
|
tmp = tmp$ret$1;
|
|
545
740
|
}
|
|
546
741
|
$callback(tmp, response);
|
|
@@ -548,58 +743,55 @@
|
|
|
548
743
|
};
|
|
549
744
|
}
|
|
550
745
|
function SocketClientJSAdapter$adapter$1($js) {
|
|
551
|
-
this.
|
|
552
|
-
this.
|
|
746
|
+
this.l2c_1 = $js;
|
|
747
|
+
this.k2c_1 = null;
|
|
553
748
|
}
|
|
554
|
-
SocketClientJSAdapter$adapter$1.prototype.
|
|
555
|
-
this.
|
|
749
|
+
SocketClientJSAdapter$adapter$1.prototype.f1b = function (_set____db54di) {
|
|
750
|
+
this.k2c_1 = _set____db54di;
|
|
556
751
|
};
|
|
557
|
-
SocketClientJSAdapter$adapter$1.prototype.
|
|
558
|
-
return this.
|
|
752
|
+
SocketClientJSAdapter$adapter$1.prototype.r21 = function () {
|
|
753
|
+
return this.k2c_1;
|
|
559
754
|
};
|
|
560
|
-
SocketClientJSAdapter$adapter$1.prototype.
|
|
755
|
+
SocketClientJSAdapter$adapter$1.prototype.g1b = function (type, msg, callback) {
|
|
561
756
|
var tmp0_safe_receiver = msg;
|
|
562
757
|
var tmp;
|
|
563
758
|
if (tmp0_safe_receiver == null) {
|
|
564
759
|
tmp = null;
|
|
565
760
|
} else {
|
|
566
761
|
var tmp$ret$1;
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
}
|
|
574
|
-
tmp$ret$1 = tmp$ret$0;
|
|
575
|
-
}
|
|
762
|
+
// Inline function 'kotlin.let' call
|
|
763
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
764
|
+
var tmp$ret$0;
|
|
765
|
+
// Inline function 'vonage.<no name provided>.emit.<anonymous>' call
|
|
766
|
+
tmp$ret$0 = fromMap(JSON, tmp0_safe_receiver);
|
|
767
|
+
tmp$ret$1 = tmp$ret$0;
|
|
576
768
|
tmp = tmp$ret$1;
|
|
577
769
|
}
|
|
578
770
|
var tmp_0 = tmp;
|
|
579
|
-
this.
|
|
771
|
+
this.l2c_1.emit(type, tmp_0, SocketClientJSAdapter$o$emit$lambda(callback));
|
|
580
772
|
};
|
|
581
|
-
SocketClientJSAdapter$adapter$1.prototype.
|
|
582
|
-
this.
|
|
773
|
+
SocketClientJSAdapter$adapter$1.prototype.h1b = function (host, path, reconnectionAttempts, reconnectionDelay, randomizationFactor, token, session_id, query) {
|
|
774
|
+
this.l2c_1.connect(host, path, reconnectionAttempts, reconnectionDelay, randomizationFactor, query);
|
|
583
775
|
};
|
|
584
|
-
SocketClientJSAdapter$adapter$1.prototype.
|
|
585
|
-
this.
|
|
776
|
+
SocketClientJSAdapter$adapter$1.prototype.i1b = function () {
|
|
777
|
+
this.l2c_1.disconnect();
|
|
586
778
|
};
|
|
587
|
-
SocketClientJSAdapter$adapter$1.prototype.
|
|
588
|
-
this.
|
|
779
|
+
SocketClientJSAdapter$adapter$1.prototype.j1b = function (token) {
|
|
780
|
+
this.l2c_1.setConnectParamsSocketConfig(token);
|
|
589
781
|
};
|
|
590
|
-
SocketClientJSAdapter$adapter$1.prototype.
|
|
591
|
-
this.
|
|
782
|
+
SocketClientJSAdapter$adapter$1.prototype.k1b = function (milliseconds, callback) {
|
|
783
|
+
this.l2c_1.startVerifyResponseTimer(milliseconds, callback);
|
|
592
784
|
};
|
|
593
785
|
SocketClientJSAdapter$adapter$1.$metadata$ = classMeta(undefined, [SocketClient]);
|
|
594
786
|
function SocketClientJSAdapter$1($adapter) {
|
|
595
|
-
this.
|
|
787
|
+
this.m2c_1 = $adapter;
|
|
596
788
|
}
|
|
597
789
|
SocketClientJSAdapter$1.prototype.didReceiveNewSocketEvent = function (type, body) {
|
|
598
|
-
var tmp0_safe_receiver = this.
|
|
790
|
+
var tmp0_safe_receiver = this.m2c_1.k2c_1;
|
|
599
791
|
if (tmp0_safe_receiver == null)
|
|
600
792
|
null;
|
|
601
793
|
else {
|
|
602
|
-
tmp0_safe_receiver.
|
|
794
|
+
tmp0_safe_receiver.f26(new UnknownSocketEvent(body, type));
|
|
603
795
|
}
|
|
604
796
|
};
|
|
605
797
|
SocketClientJSAdapter$1.prototype.didReceiveNewSocketConnectionStatusEvent = function (type, reason) {
|
|
@@ -625,161 +817,155 @@
|
|
|
625
817
|
null;
|
|
626
818
|
else {
|
|
627
819
|
var tmp$ret$1;
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
}
|
|
645
|
-
|
|
646
|
-
tmp = tmp_0;
|
|
647
|
-
break;
|
|
648
|
-
case 'NXMCORE_REASON_CLIENT_DISCONNECTED':
|
|
649
|
-
var tmp2_safe_receiver = this.f2a_1.d2a_1;
|
|
650
|
-
var tmp_1;
|
|
651
|
-
if (tmp2_safe_receiver == null) {
|
|
652
|
-
tmp_1 = null;
|
|
653
|
-
} else {
|
|
654
|
-
tmp2_safe_receiver.t24(tmp1_safe_receiver, SocketConnectionFailedReason_ClientDisconnected_getInstance());
|
|
655
|
-
tmp_1 = Unit_getInstance();
|
|
656
|
-
}
|
|
820
|
+
// Inline function 'kotlin.let' call
|
|
821
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
822
|
+
var tmp$ret$0;
|
|
823
|
+
// Inline function 'vonage.<no name provided>.didReceiveNewSocketConnectionStatusEvent.<anonymous>' call
|
|
824
|
+
var tmp0_subject_0 = reason;
|
|
825
|
+
var tmp;
|
|
826
|
+
switch (tmp0_subject_0) {
|
|
827
|
+
case 'NXMCORE_REASON_SERVER_DISCONNECTED':
|
|
828
|
+
var tmp1_safe_receiver_0 = this.m2c_1.k2c_1;
|
|
829
|
+
var tmp_0;
|
|
830
|
+
if (tmp1_safe_receiver_0 == null) {
|
|
831
|
+
tmp_0 = null;
|
|
832
|
+
} else {
|
|
833
|
+
tmp1_safe_receiver_0.g26(tmp1_safe_receiver, SocketConnectionFailedReason_ServerDisconnected_getInstance());
|
|
834
|
+
tmp_0 = Unit_getInstance();
|
|
835
|
+
}
|
|
657
836
|
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
837
|
+
tmp = tmp_0;
|
|
838
|
+
break;
|
|
839
|
+
case 'NXMCORE_REASON_CLIENT_DISCONNECTED':
|
|
840
|
+
var tmp2_safe_receiver = this.m2c_1.k2c_1;
|
|
841
|
+
var tmp_1;
|
|
842
|
+
if (tmp2_safe_receiver == null) {
|
|
843
|
+
tmp_1 = null;
|
|
844
|
+
} else {
|
|
845
|
+
tmp2_safe_receiver.g26(tmp1_safe_receiver, SocketConnectionFailedReason_ClientDisconnected_getInstance());
|
|
846
|
+
tmp_1 = Unit_getInstance();
|
|
847
|
+
}
|
|
669
848
|
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
849
|
+
tmp = tmp_1;
|
|
850
|
+
break;
|
|
851
|
+
case 'NXMCORE_CLIENT_NETWORK_ERROR':
|
|
852
|
+
var tmp3_safe_receiver = this.m2c_1.k2c_1;
|
|
853
|
+
var tmp_2;
|
|
854
|
+
if (tmp3_safe_receiver == null) {
|
|
855
|
+
tmp_2 = null;
|
|
856
|
+
} else {
|
|
857
|
+
tmp3_safe_receiver.g26(tmp1_safe_receiver, SocketConnectionFailedReason_ClientNetworkError_getInstance());
|
|
858
|
+
tmp_2 = Unit_getInstance();
|
|
859
|
+
}
|
|
681
860
|
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
861
|
+
tmp = tmp_2;
|
|
862
|
+
break;
|
|
863
|
+
case 'NXMCORE_REASON_PING_TIMEOUT':
|
|
864
|
+
var tmp4_safe_receiver = this.m2c_1.k2c_1;
|
|
865
|
+
var tmp_3;
|
|
866
|
+
if (tmp4_safe_receiver == null) {
|
|
867
|
+
tmp_3 = null;
|
|
868
|
+
} else {
|
|
869
|
+
tmp4_safe_receiver.g26(tmp1_safe_receiver, SocketConnectionFailedReason_PingTimeout_getInstance());
|
|
870
|
+
tmp_3 = Unit_getInstance();
|
|
871
|
+
}
|
|
693
872
|
|
|
694
|
-
|
|
695
|
-
|
|
873
|
+
tmp = tmp_3;
|
|
874
|
+
break;
|
|
875
|
+
default:
|
|
876
|
+
var tmp5_safe_receiver = this.m2c_1.k2c_1;
|
|
877
|
+
var tmp_4;
|
|
878
|
+
if (tmp5_safe_receiver == null) {
|
|
879
|
+
tmp_4 = null;
|
|
880
|
+
} else {
|
|
881
|
+
tmp5_safe_receiver.g26(tmp1_safe_receiver, null);
|
|
882
|
+
tmp_4 = Unit_getInstance();
|
|
696
883
|
}
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
884
|
+
|
|
885
|
+
tmp = tmp_4;
|
|
886
|
+
break;
|
|
700
887
|
}
|
|
888
|
+
tmp$ret$0 = tmp;
|
|
889
|
+
tmp$ret$1 = tmp$ret$0;
|
|
701
890
|
}
|
|
702
891
|
};
|
|
703
892
|
SocketClientJSAdapter$1.$metadata$ = classMeta();
|
|
704
893
|
function MediaClientJSAdapter$adapter$1($js) {
|
|
705
|
-
this.
|
|
706
|
-
this.
|
|
894
|
+
this.o2c_1 = $js;
|
|
895
|
+
this.n2c_1 = null;
|
|
707
896
|
}
|
|
708
|
-
MediaClientJSAdapter$adapter$1.prototype.
|
|
709
|
-
this.
|
|
897
|
+
MediaClientJSAdapter$adapter$1.prototype.n1b = function (_set____db54di) {
|
|
898
|
+
this.n2c_1 = _set____db54di;
|
|
710
899
|
};
|
|
711
|
-
MediaClientJSAdapter$adapter$1.prototype.
|
|
712
|
-
this.
|
|
900
|
+
MediaClientJSAdapter$adapter$1.prototype.o1b = function (id) {
|
|
901
|
+
this.o2c_1.enableMedia(id, null);
|
|
713
902
|
};
|
|
714
|
-
MediaClientJSAdapter$adapter$1.prototype.
|
|
715
|
-
this.
|
|
903
|
+
MediaClientJSAdapter$adapter$1.prototype.p1b = function (id, remoteDescription) {
|
|
904
|
+
this.o2c_1.enableMedia(id, remoteDescription);
|
|
716
905
|
};
|
|
717
|
-
MediaClientJSAdapter$adapter$1.prototype.
|
|
718
|
-
this.
|
|
906
|
+
MediaClientJSAdapter$adapter$1.prototype.q1b = function (id, sdp, streamId, legId) {
|
|
907
|
+
this.o2c_1.processAnswer(id, sdp, streamId, legId);
|
|
719
908
|
};
|
|
720
|
-
MediaClientJSAdapter$adapter$1.prototype.
|
|
721
|
-
this.
|
|
909
|
+
MediaClientJSAdapter$adapter$1.prototype.r1b = function (id) {
|
|
910
|
+
this.o2c_1.disableMedia(id);
|
|
722
911
|
};
|
|
723
|
-
MediaClientJSAdapter$adapter$1.prototype.
|
|
724
|
-
this.
|
|
912
|
+
MediaClientJSAdapter$adapter$1.prototype.s1b = function (id) {
|
|
913
|
+
this.o2c_1.mute(id);
|
|
725
914
|
};
|
|
726
|
-
MediaClientJSAdapter$adapter$1.prototype.
|
|
727
|
-
this.
|
|
915
|
+
MediaClientJSAdapter$adapter$1.prototype.t1b = function (id) {
|
|
916
|
+
this.o2c_1.unmute(id);
|
|
728
917
|
};
|
|
729
918
|
MediaClientJSAdapter$adapter$1.$metadata$ = classMeta(undefined, [MediaClient]);
|
|
730
919
|
function MediaClientJSAdapter$1($adapter) {
|
|
731
|
-
this.
|
|
920
|
+
this.p2c_1 = $adapter;
|
|
732
921
|
}
|
|
733
922
|
MediaClientJSAdapter$1.prototype.onOffer = function (mediaId, streamId, sdp, callback) {
|
|
734
|
-
var tmp0_safe_receiver = this.
|
|
923
|
+
var tmp0_safe_receiver = this.p2c_1.n2c_1;
|
|
735
924
|
if (tmp0_safe_receiver == null)
|
|
736
925
|
null;
|
|
737
926
|
else {
|
|
738
|
-
tmp0_safe_receiver.
|
|
927
|
+
tmp0_safe_receiver.c26(mediaId, streamId, sdp, callback);
|
|
739
928
|
}
|
|
740
929
|
};
|
|
741
930
|
MediaClientJSAdapter$1.prototype.onAnswer = function (mediaId, streamId, sdp, callback) {
|
|
742
|
-
var tmp0_safe_receiver = this.
|
|
931
|
+
var tmp0_safe_receiver = this.p2c_1.n2c_1;
|
|
743
932
|
if (tmp0_safe_receiver == null)
|
|
744
933
|
null;
|
|
745
934
|
else {
|
|
746
|
-
tmp0_safe_receiver.
|
|
935
|
+
tmp0_safe_receiver.d26(mediaId, streamId, sdp, callback);
|
|
747
936
|
}
|
|
748
937
|
};
|
|
749
938
|
MediaClientJSAdapter$1.prototype.onError = function (mediaId, error) {
|
|
750
|
-
var tmp0_safe_receiver = this.
|
|
939
|
+
var tmp0_safe_receiver = this.p2c_1.n2c_1;
|
|
751
940
|
if (tmp0_safe_receiver == null)
|
|
752
941
|
null;
|
|
753
942
|
else {
|
|
754
|
-
tmp0_safe_receiver.
|
|
943
|
+
tmp0_safe_receiver.e26(mediaId, Exception_init_$Create$(error));
|
|
755
944
|
}
|
|
756
945
|
};
|
|
757
946
|
MediaClientJSAdapter$1.$metadata$ = classMeta();
|
|
758
947
|
function entriesOf(jsObject) {
|
|
759
948
|
var tmp$ret$2;
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
tmp0_mapTo.a(tmp$ret$0);
|
|
778
|
-
}
|
|
779
|
-
tmp$ret$1 = tmp0_mapTo;
|
|
780
|
-
}
|
|
781
|
-
tmp$ret$2 = tmp$ret$1;
|
|
949
|
+
// Inline function 'kotlin.collections.map' call
|
|
950
|
+
var tmp = Object.entries;
|
|
951
|
+
var tmp0_map = ((!(tmp == null) ? typeof tmp === 'function' : false) ? tmp : THROW_CCE())(jsObject);
|
|
952
|
+
var tmp$ret$1;
|
|
953
|
+
// Inline function 'kotlin.collections.mapTo' call
|
|
954
|
+
var tmp0_mapTo = ArrayList_init_$Create$(tmp0_map.length);
|
|
955
|
+
var indexedObject = tmp0_map;
|
|
956
|
+
var inductionVariable = 0;
|
|
957
|
+
var last = indexedObject.length;
|
|
958
|
+
while (inductionVariable < last) {
|
|
959
|
+
var item = indexedObject[inductionVariable];
|
|
960
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
961
|
+
var tmp$ret$0;
|
|
962
|
+
// Inline function 'vonage.utils.entriesOf.<anonymous>' call
|
|
963
|
+
var tmp_0 = item[0];
|
|
964
|
+
tmp$ret$0 = to((!(tmp_0 == null) ? typeof tmp_0 === 'string' : false) ? tmp_0 : THROW_CCE(), item[1]);
|
|
965
|
+
tmp0_mapTo.a(tmp$ret$0);
|
|
782
966
|
}
|
|
967
|
+
tmp$ret$1 = tmp0_mapTo;
|
|
968
|
+
tmp$ret$2 = tmp$ret$1;
|
|
783
969
|
return tmp$ret$2;
|
|
784
970
|
}
|
|
785
971
|
function toMap_0(_this__u8e3s4) {
|
|
@@ -787,112 +973,99 @@
|
|
|
787
973
|
}
|
|
788
974
|
function fromMap(_this__u8e3s4, m) {
|
|
789
975
|
var tmp$ret$9;
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
var tmp_4 = JSON;
|
|
869
|
-
var tmp_5 = item.o1();
|
|
870
|
-
tmp_3 = fromMap(tmp_4, (!(tmp_5 == null) ? isInterface(tmp_5, Map) : false) ? tmp_5 : THROW_CCE());
|
|
871
|
-
} catch ($p) {
|
|
872
|
-
var tmp_6;
|
|
873
|
-
if ($p instanceof Exception) {
|
|
874
|
-
tmp_6 = null;
|
|
875
|
-
} else {
|
|
876
|
-
throw $p;
|
|
877
|
-
}
|
|
878
|
-
tmp_3 = tmp_6;
|
|
879
|
-
}
|
|
880
|
-
tmp_0 = tmp_3;
|
|
881
|
-
} else {
|
|
882
|
-
tmp_0 = null;
|
|
883
|
-
}
|
|
884
|
-
}
|
|
885
|
-
tmp$ret$6 = new Pair(tmp, tmp_0);
|
|
976
|
+
// Inline function 'kotlin.collections.toTypedArray' call
|
|
977
|
+
var tmp$ret$8;
|
|
978
|
+
// Inline function 'kotlin.collections.map' call
|
|
979
|
+
var tmp$ret$4;
|
|
980
|
+
// Inline function 'kotlin.apply' call
|
|
981
|
+
var tmp$ret$0;
|
|
982
|
+
// Inline function 'kotlin.collections.mutableMapOf' call
|
|
983
|
+
tmp$ret$0 = LinkedHashMap_init_$Create$();
|
|
984
|
+
var tmp0_apply = tmp$ret$0;
|
|
985
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
986
|
+
// Inline function 'vonage.utils.fromMap.<anonymous>' call
|
|
987
|
+
// Inline function 'kotlin.collections.forEach' call
|
|
988
|
+
var tmp$ret$1;
|
|
989
|
+
// Inline function 'kotlin.collections.iterator' call
|
|
990
|
+
tmp$ret$1 = m.q().g();
|
|
991
|
+
var tmp0_iterator = tmp$ret$1;
|
|
992
|
+
while (tmp0_iterator.h()) {
|
|
993
|
+
var element = tmp0_iterator.i();
|
|
994
|
+
// Inline function 'vonage.utils.fromMap.<anonymous>.<anonymous>' call
|
|
995
|
+
var tmp$ret$2;
|
|
996
|
+
// Inline function 'kotlin.collections.component1' call
|
|
997
|
+
tmp$ret$2 = element.m1();
|
|
998
|
+
var k = tmp$ret$2;
|
|
999
|
+
var tmp$ret$3;
|
|
1000
|
+
// Inline function 'kotlin.collections.component2' call
|
|
1001
|
+
tmp$ret$3 = element.o1();
|
|
1002
|
+
var v = tmp$ret$3;
|
|
1003
|
+
var tmp0_subject = k;
|
|
1004
|
+
if (!(tmp0_subject == null) ? typeof tmp0_subject === 'string' : false) {
|
|
1005
|
+
// Inline function 'kotlin.collections.set' call
|
|
1006
|
+
var tmp0_set = k;
|
|
1007
|
+
tmp0_apply.l(tmp0_set, v);
|
|
1008
|
+
} else {
|
|
1009
|
+
}
|
|
1010
|
+
}
|
|
1011
|
+
tmp$ret$4 = tmp0_apply;
|
|
1012
|
+
var tmp1_map = tmp$ret$4;
|
|
1013
|
+
var tmp$ret$7;
|
|
1014
|
+
// Inline function 'kotlin.collections.mapTo' call
|
|
1015
|
+
var tmp0_mapTo = ArrayList_init_$Create$(tmp1_map.f());
|
|
1016
|
+
var tmp$ret$5;
|
|
1017
|
+
// Inline function 'kotlin.collections.iterator' call
|
|
1018
|
+
tmp$ret$5 = tmp1_map.q().g();
|
|
1019
|
+
var tmp0_iterator_0 = tmp$ret$5;
|
|
1020
|
+
while (tmp0_iterator_0.h()) {
|
|
1021
|
+
var item = tmp0_iterator_0.i();
|
|
1022
|
+
var tmp$ret$6;
|
|
1023
|
+
// Inline function 'vonage.utils.fromMap.<anonymous>' call
|
|
1024
|
+
var tmp = item.m1();
|
|
1025
|
+
var tmp0_subject_0 = item.o1();
|
|
1026
|
+
var tmp_0;
|
|
1027
|
+
var tmp_1;
|
|
1028
|
+
var tmp_2;
|
|
1029
|
+
if (!(tmp0_subject_0 == null) ? typeof tmp0_subject_0 === 'string' : false) {
|
|
1030
|
+
tmp_2 = true;
|
|
1031
|
+
} else {
|
|
1032
|
+
tmp_2 = !(tmp0_subject_0 == null) ? typeof tmp0_subject_0 === 'boolean' : false;
|
|
1033
|
+
}
|
|
1034
|
+
if (tmp_2) {
|
|
1035
|
+
tmp_1 = true;
|
|
1036
|
+
} else {
|
|
1037
|
+
tmp_1 = !(tmp0_subject_0 == null) ? typeof tmp0_subject_0 === 'number' : false;
|
|
1038
|
+
}
|
|
1039
|
+
if (tmp_1) {
|
|
1040
|
+
tmp_0 = item.o1();
|
|
1041
|
+
} else {
|
|
1042
|
+
if (!(tmp0_subject_0 == null) ? isInterface(tmp0_subject_0, Map) : false) {
|
|
1043
|
+
var tmp_3;
|
|
1044
|
+
try {
|
|
1045
|
+
var tmp_4 = JSON;
|
|
1046
|
+
var tmp_5 = item.o1();
|
|
1047
|
+
tmp_3 = fromMap(tmp_4, (!(tmp_5 == null) ? isInterface(tmp_5, Map) : false) ? tmp_5 : THROW_CCE());
|
|
1048
|
+
} catch ($p) {
|
|
1049
|
+
var tmp_6;
|
|
1050
|
+
if ($p instanceof Exception) {
|
|
1051
|
+
tmp_6 = null;
|
|
1052
|
+
} else {
|
|
1053
|
+
throw $p;
|
|
886
1054
|
}
|
|
887
|
-
|
|
1055
|
+
tmp_3 = tmp_6;
|
|
888
1056
|
}
|
|
889
|
-
|
|
1057
|
+
tmp_0 = tmp_3;
|
|
1058
|
+
} else {
|
|
1059
|
+
tmp_0 = null;
|
|
890
1060
|
}
|
|
891
|
-
tmp$ret$8 = tmp$ret$7;
|
|
892
1061
|
}
|
|
893
|
-
|
|
894
|
-
tmp$ret$
|
|
1062
|
+
tmp$ret$6 = new Pair(tmp, tmp_0);
|
|
1063
|
+
tmp0_mapTo.a(tmp$ret$6);
|
|
895
1064
|
}
|
|
1065
|
+
tmp$ret$7 = tmp0_mapTo;
|
|
1066
|
+
tmp$ret$8 = tmp$ret$7;
|
|
1067
|
+
var tmp2_toTypedArray = tmp$ret$8;
|
|
1068
|
+
tmp$ret$9 = copyToArray(tmp2_toTypedArray);
|
|
896
1069
|
return json(tmp$ret$9.slice());
|
|
897
1070
|
}
|
|
898
1071
|
//region block: init
|
|
@@ -907,8 +1080,10 @@
|
|
|
907
1080
|
//region block: exports
|
|
908
1081
|
function $jsExportAll$(_) {
|
|
909
1082
|
var $vonage = _.vonage || (_.vonage = {});
|
|
1083
|
+
$vonage.CoreClientConfigJS = CoreClientConfigJS;
|
|
910
1084
|
$vonage.CoreClientJS = CoreClientJS;
|
|
911
1085
|
$vonage.VoiceCallJS = VoiceCallJS;
|
|
1086
|
+
$vonage.VoiceInviteFromInfoJS = VoiceInviteFromInfoJS;
|
|
912
1087
|
$vonage.VoiceInviteJS = VoiceInviteJS;
|
|
913
1088
|
$vonage.ConversationJS = ConversationJS;
|
|
914
1089
|
var $vonage = _.vonage || (_.vonage = {});
|
|
@@ -946,4 +1121,4 @@
|
|
|
946
1121
|
return _;
|
|
947
1122
|
}));
|
|
948
1123
|
|
|
949
|
-
//# sourceMappingURL=clientsdk-clientcore_js.js.map
|
|
1124
|
+
//# sourceMappingURL=clientsdk-clientcore_js.js.map
|