@doordeck/doordeck-headless-sdk 0.56.0 → 0.57.0
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/kotlin/Kotlin-DateTime-library-kotlinx-datetime.js +1258 -1258
- package/kotlin/KotlinMultiplatformLibsodium-multiplatform-crypto-libsodium-bindings.js +21 -21
- package/kotlin/MultiplatformSettings-multiplatform-settings.js +7 -7
- package/kotlin/doordeck-sdk.js +9034 -9034
- package/kotlin/kotlin-kotlin-stdlib.js +1117 -904
- package/kotlin/kotlinx-atomicfu.js +15 -15
- package/kotlin/kotlinx-coroutines-core.js +1672 -1642
- package/kotlin/kotlinx-io-kotlinx-io-core.js +431 -431
- package/kotlin/kotlinx-serialization-kotlinx-serialization-core.js +1781 -1781
- package/kotlin/kotlinx-serialization-kotlinx-serialization-json.js +1387 -1387
- package/kotlin/ktor-ktor-client-ktor-client-core.js +2012 -1885
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-auth.js +241 -241
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-content-negotiation.js +130 -130
- package/kotlin/ktor-ktor-http.js +699 -698
- package/kotlin/ktor-ktor-io.js +483 -458
- package/kotlin/ktor-ktor-shared-ktor-events.js +10 -10
- package/kotlin/ktor-ktor-shared-ktor-serialization-ktor-serialization-kotlinx-ktor-serialization-kotlinx-json.js +7 -7
- package/kotlin/ktor-ktor-shared-ktor-serialization-ktor-serialization-kotlinx.js +145 -145
- package/kotlin/ktor-ktor-shared-ktor-serialization.js +68 -68
- package/kotlin/ktor-ktor-shared-ktor-websockets.js +45 -45
- package/kotlin/ktor-ktor-utils.js +564 -543
- package/package.json +1 -1
- package/kotlin/ktor-ktor-client-ktor-client-js.js +0 -6
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
(function (_, kotlin_kotlin, kotlin_io_ktor_ktor_http, kotlin_io_ktor_ktor_serialization, kotlin_io_ktor_ktor_io, kotlin_io_ktor_ktor_client_core, kotlin_io_ktor_ktor_utils) {
|
|
2
2
|
'use strict';
|
|
3
3
|
//region block: imports
|
|
4
|
-
var protoOf = kotlin_kotlin.$_$.
|
|
4
|
+
var protoOf = kotlin_kotlin.$_$.jb;
|
|
5
5
|
var initMetadataForClass = kotlin_kotlin.$_$.ia;
|
|
6
6
|
var plus = kotlin_kotlin.$_$.s7;
|
|
7
7
|
var toMutableSet = kotlin_kotlin.$_$.o8;
|
|
@@ -11,12 +11,12 @@
|
|
|
11
11
|
var Unit_instance = kotlin_kotlin.$_$.g5;
|
|
12
12
|
var Configuration = kotlin_io_ktor_ktor_serialization.$_$.c;
|
|
13
13
|
var VOID = kotlin_kotlin.$_$.h;
|
|
14
|
-
var Exception = kotlin_kotlin.$_$.
|
|
14
|
+
var Exception = kotlin_kotlin.$_$.ne;
|
|
15
15
|
var Exception_init_$Init$ = kotlin_kotlin.$_$.n1;
|
|
16
16
|
var captureStack = kotlin_kotlin.$_$.t9;
|
|
17
17
|
var Charsets_getInstance = kotlin_io_ktor_ktor_io.$_$.h;
|
|
18
18
|
var CoroutineImpl = kotlin_kotlin.$_$.l9;
|
|
19
|
-
var THROW_CCE = kotlin_kotlin.$_$.
|
|
19
|
+
var THROW_CCE = kotlin_kotlin.$_$.we;
|
|
20
20
|
var TransformRequestBodyContext = kotlin_io_ktor_ktor_client_core.$_$.g;
|
|
21
21
|
var HttpRequestBuilder = kotlin_io_ktor_ktor_client_core.$_$.o;
|
|
22
22
|
var TypeInfo = kotlin_io_ktor_ktor_utils.$_$.k;
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
var contentType = kotlin_io_ktor_ktor_http.$_$.i1;
|
|
30
30
|
var get_request = kotlin_io_ktor_ktor_client_core.$_$.v;
|
|
31
31
|
var suitableCharset = kotlin_io_ktor_ktor_serialization.$_$.f;
|
|
32
|
-
var toString = kotlin_kotlin.$_$.
|
|
32
|
+
var toString = kotlin_kotlin.$_$.nb;
|
|
33
33
|
var HttpHeaders_getInstance = kotlin_io_ktor_ktor_http.$_$.e;
|
|
34
34
|
var accept = kotlin_io_ktor_ktor_client_core.$_$.p;
|
|
35
35
|
var Collection = kotlin_kotlin.$_$.i5;
|
|
@@ -37,9 +37,9 @@
|
|
|
37
37
|
var getKClassFromExpression = kotlin_kotlin.$_$.e;
|
|
38
38
|
var contentType_0 = kotlin_io_ktor_ktor_http.$_$.h1;
|
|
39
39
|
var EmptyContent_getInstance = kotlin_io_ktor_ktor_client_core.$_$.d;
|
|
40
|
-
var Unit = kotlin_kotlin.$_$.
|
|
40
|
+
var Unit = kotlin_kotlin.$_$.hf;
|
|
41
41
|
var charset = kotlin_io_ktor_ktor_http.$_$.f1;
|
|
42
|
-
var ensureNotNull = kotlin_kotlin.$_$.
|
|
42
|
+
var ensureNotNull = kotlin_kotlin.$_$.nf;
|
|
43
43
|
var NullBody_instance = kotlin_io_ktor_ktor_http.$_$.a;
|
|
44
44
|
var equals = kotlin_kotlin.$_$.ba;
|
|
45
45
|
var joinToString = kotlin_kotlin.$_$.h7;
|
|
@@ -53,8 +53,8 @@
|
|
|
53
53
|
var getKClass = kotlin_kotlin.$_$.f;
|
|
54
54
|
var setOf = kotlin_kotlin.$_$.b8;
|
|
55
55
|
var createClientPlugin = kotlin_io_ktor_ktor_client_core.$_$.i;
|
|
56
|
-
var startsWith = kotlin_kotlin.$_$.
|
|
57
|
-
var endsWith = kotlin_kotlin.$_$.
|
|
56
|
+
var startsWith = kotlin_kotlin.$_$.ed;
|
|
57
|
+
var endsWith = kotlin_kotlin.$_$.kc;
|
|
58
58
|
var initMetadataForObject = kotlin_kotlin.$_$.oa;
|
|
59
59
|
var LinkedHashSet_init_$Create$ = kotlin_kotlin.$_$.a1;
|
|
60
60
|
//endregion
|
|
@@ -85,34 +85,34 @@
|
|
|
85
85
|
}
|
|
86
86
|
var ContentNegotiation;
|
|
87
87
|
function ConverterRegistration(converter, contentTypeToSend, contentTypeMatcher) {
|
|
88
|
-
this.
|
|
89
|
-
this.
|
|
90
|
-
this.
|
|
88
|
+
this.r48_1 = converter;
|
|
89
|
+
this.s48_1 = contentTypeToSend;
|
|
90
|
+
this.t48_1 = contentTypeMatcher;
|
|
91
91
|
}
|
|
92
92
|
function defaultMatcher($this, pattern) {
|
|
93
93
|
return new ContentNegotiationConfig$defaultMatcher$1(pattern);
|
|
94
94
|
}
|
|
95
95
|
function ContentNegotiationConfig$defaultMatcher$1($pattern) {
|
|
96
|
-
this.
|
|
96
|
+
this.u48_1 = $pattern;
|
|
97
97
|
}
|
|
98
|
-
protoOf(ContentNegotiationConfig$defaultMatcher$1).
|
|
99
|
-
return contentType.
|
|
98
|
+
protoOf(ContentNegotiationConfig$defaultMatcher$1).v48 = function (contentType) {
|
|
99
|
+
return contentType.f2f(this.u48_1);
|
|
100
100
|
};
|
|
101
101
|
function ContentNegotiationConfig() {
|
|
102
|
-
this.
|
|
102
|
+
this.w48_1 = toMutableSet(plus(get_DefaultIgnoredTypes(), get_DefaultCommonIgnoredTypes()));
|
|
103
103
|
var tmp = this;
|
|
104
104
|
// Inline function 'kotlin.collections.mutableListOf' call
|
|
105
|
-
tmp.
|
|
105
|
+
tmp.x48_1 = ArrayList_init_$Create$();
|
|
106
106
|
}
|
|
107
|
-
protoOf(ContentNegotiationConfig).
|
|
108
|
-
var matcher = contentType.equals(Application_getInstance().
|
|
109
|
-
this.
|
|
107
|
+
protoOf(ContentNegotiationConfig).n2r = function (contentType, converter, configuration) {
|
|
108
|
+
var matcher = contentType.equals(Application_getInstance().x2d_1) ? JsonContentTypeMatcher_instance : defaultMatcher(this, contentType);
|
|
109
|
+
this.y48(contentType, converter, matcher, configuration);
|
|
110
110
|
};
|
|
111
|
-
protoOf(ContentNegotiationConfig).
|
|
111
|
+
protoOf(ContentNegotiationConfig).y48 = function (contentTypeToSend, converter, contentTypeMatcher, configuration) {
|
|
112
112
|
// Inline function 'kotlin.apply' call
|
|
113
113
|
configuration(converter);
|
|
114
114
|
var registration = new ConverterRegistration(converter, contentTypeToSend, contentTypeMatcher);
|
|
115
|
-
this.
|
|
115
|
+
this.x48_1.k(registration);
|
|
116
116
|
};
|
|
117
117
|
function ContentConverterException(message) {
|
|
118
118
|
Exception_init_$Init$(message, this);
|
|
@@ -127,10 +127,10 @@
|
|
|
127
127
|
}
|
|
128
128
|
function ContentNegotiation$lambda($this$createClientPlugin) {
|
|
129
129
|
_init_properties_ContentNegotiation_kt__o183go();
|
|
130
|
-
var registrations = $this$createClientPlugin.
|
|
131
|
-
var ignoredTypes = $this$createClientPlugin.
|
|
132
|
-
$this$createClientPlugin.
|
|
133
|
-
$this$createClientPlugin.
|
|
130
|
+
var registrations = $this$createClientPlugin.h34_1.x48_1;
|
|
131
|
+
var ignoredTypes = $this$createClientPlugin.h34_1.w48_1;
|
|
132
|
+
$this$createClientPlugin.g3n(ContentNegotiation$lambda$slambda_0(registrations, ignoredTypes, $this$createClientPlugin, null));
|
|
133
|
+
$this$createClientPlugin.l3f(ContentNegotiation$lambda$slambda_2(ignoredTypes, registrations, $this$createClientPlugin, null));
|
|
134
134
|
return Unit_instance;
|
|
135
135
|
}
|
|
136
136
|
function invoke$convertRequest(registrations, ignoredTypes, $this_createClientPlugin, request, body, $completion) {
|
|
@@ -140,29 +140,29 @@
|
|
|
140
140
|
return tmp.l9();
|
|
141
141
|
}
|
|
142
142
|
function invoke$convertResponse(ignoredTypes, registrations, $this_createClientPlugin, requestUrl, info, body, responseContentType, charset, $completion) {
|
|
143
|
-
charset = charset === VOID ? Charsets_getInstance().
|
|
143
|
+
charset = charset === VOID ? Charsets_getInstance().o1l_1 : charset;
|
|
144
144
|
var tmp = new $invoke$convertResponseCOROUTINE$1(ignoredTypes, registrations, $this_createClientPlugin, requestUrl, info, body, responseContentType, charset, $completion);
|
|
145
145
|
tmp.f9_1 = Unit_instance;
|
|
146
146
|
tmp.g9_1 = null;
|
|
147
147
|
return tmp.l9();
|
|
148
148
|
}
|
|
149
149
|
function ContentNegotiation$lambda$slambda($registrations, $ignoredTypes, $this_createClientPlugin, resultContinuation) {
|
|
150
|
-
this.
|
|
151
|
-
this.
|
|
152
|
-
this.
|
|
150
|
+
this.u4a_1 = $registrations;
|
|
151
|
+
this.v4a_1 = $ignoredTypes;
|
|
152
|
+
this.w4a_1 = $this_createClientPlugin;
|
|
153
153
|
CoroutineImpl.call(this, resultContinuation);
|
|
154
154
|
}
|
|
155
|
-
protoOf(ContentNegotiation$lambda$slambda).
|
|
156
|
-
var tmp = this.
|
|
155
|
+
protoOf(ContentNegotiation$lambda$slambda).b4b = function ($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion) {
|
|
156
|
+
var tmp = this.c4b($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion);
|
|
157
157
|
tmp.f9_1 = Unit_instance;
|
|
158
158
|
tmp.g9_1 = null;
|
|
159
159
|
return tmp.l9();
|
|
160
160
|
};
|
|
161
|
-
protoOf(ContentNegotiation$lambda$slambda).
|
|
161
|
+
protoOf(ContentNegotiation$lambda$slambda).q3g = function (p1, p2, p3, p4, $completion) {
|
|
162
162
|
var tmp = p1 instanceof TransformRequestBodyContext ? p1 : THROW_CCE();
|
|
163
163
|
var tmp_0 = p2 instanceof HttpRequestBuilder ? p2 : THROW_CCE();
|
|
164
164
|
var tmp_1 = !(p3 == null) ? p3 : THROW_CCE();
|
|
165
|
-
return this.
|
|
165
|
+
return this.b4b(tmp, tmp_0, tmp_1, (p4 == null ? true : p4 instanceof TypeInfo) ? p4 : THROW_CCE(), $completion);
|
|
166
166
|
};
|
|
167
167
|
protoOf(ContentNegotiation$lambda$slambda).l9 = function () {
|
|
168
168
|
var suspendResult = this.f9_1;
|
|
@@ -173,7 +173,7 @@
|
|
|
173
173
|
case 0:
|
|
174
174
|
this.e9_1 = 2;
|
|
175
175
|
this.d9_1 = 1;
|
|
176
|
-
suspendResult = invoke$convertRequest(this.
|
|
176
|
+
suspendResult = invoke$convertRequest(this.u4a_1, this.v4a_1, this.w4a_1, this.y4a_1, this.z4a_1, this);
|
|
177
177
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
178
178
|
return suspendResult;
|
|
179
179
|
}
|
|
@@ -195,39 +195,39 @@
|
|
|
195
195
|
}
|
|
196
196
|
while (true);
|
|
197
197
|
};
|
|
198
|
-
protoOf(ContentNegotiation$lambda$slambda).
|
|
199
|
-
var i = new ContentNegotiation$lambda$slambda(this.
|
|
200
|
-
i.
|
|
201
|
-
i.
|
|
202
|
-
i.
|
|
203
|
-
i.
|
|
198
|
+
protoOf(ContentNegotiation$lambda$slambda).c4b = function ($this$transformRequestBody, request, body, _unused_var__etf5q3, completion) {
|
|
199
|
+
var i = new ContentNegotiation$lambda$slambda(this.u4a_1, this.v4a_1, this.w4a_1, completion);
|
|
200
|
+
i.x4a_1 = $this$transformRequestBody;
|
|
201
|
+
i.y4a_1 = request;
|
|
202
|
+
i.z4a_1 = body;
|
|
203
|
+
i.a4b_1 = _unused_var__etf5q3;
|
|
204
204
|
return i;
|
|
205
205
|
};
|
|
206
206
|
function ContentNegotiation$lambda$slambda_0($registrations, $ignoredTypes, $this_createClientPlugin, resultContinuation) {
|
|
207
207
|
var i = new ContentNegotiation$lambda$slambda($registrations, $ignoredTypes, $this_createClientPlugin, resultContinuation);
|
|
208
208
|
var l = function ($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion) {
|
|
209
|
-
return i.
|
|
209
|
+
return i.b4b($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion);
|
|
210
210
|
};
|
|
211
211
|
l.$arity = 4;
|
|
212
212
|
return l;
|
|
213
213
|
}
|
|
214
214
|
function ContentNegotiation$lambda$slambda_1($ignoredTypes, $registrations, $this_createClientPlugin, resultContinuation) {
|
|
215
|
-
this.
|
|
216
|
-
this.
|
|
217
|
-
this.
|
|
215
|
+
this.l4b_1 = $ignoredTypes;
|
|
216
|
+
this.m4b_1 = $registrations;
|
|
217
|
+
this.n4b_1 = $this_createClientPlugin;
|
|
218
218
|
CoroutineImpl.call(this, resultContinuation);
|
|
219
219
|
}
|
|
220
|
-
protoOf(ContentNegotiation$lambda$slambda_1).
|
|
221
|
-
var tmp = this.
|
|
220
|
+
protoOf(ContentNegotiation$lambda$slambda_1).o3g = function ($this$transformResponseBody, response, body, info, $completion) {
|
|
221
|
+
var tmp = this.p3g($this$transformResponseBody, response, body, info, $completion);
|
|
222
222
|
tmp.f9_1 = Unit_instance;
|
|
223
223
|
tmp.g9_1 = null;
|
|
224
224
|
return tmp.l9();
|
|
225
225
|
};
|
|
226
|
-
protoOf(ContentNegotiation$lambda$slambda_1).
|
|
226
|
+
protoOf(ContentNegotiation$lambda$slambda_1).q3g = function (p1, p2, p3, p4, $completion) {
|
|
227
227
|
var tmp = p1 instanceof TransformResponseBodyContext ? p1 : THROW_CCE();
|
|
228
228
|
var tmp_0 = p2 instanceof HttpResponse ? p2 : THROW_CCE();
|
|
229
229
|
var tmp_1 = (!(p3 == null) ? isInterface(p3, ByteReadChannel) : false) ? p3 : THROW_CCE();
|
|
230
|
-
return this.
|
|
230
|
+
return this.o3g(tmp, tmp_0, tmp_1, p4 instanceof TypeInfo ? p4 : THROW_CCE(), $completion);
|
|
231
231
|
};
|
|
232
232
|
protoOf(ContentNegotiation$lambda$slambda_1).l9 = function () {
|
|
233
233
|
var suspendResult = this.f9_1;
|
|
@@ -238,7 +238,7 @@
|
|
|
238
238
|
case 0:
|
|
239
239
|
this.e9_1 = 2;
|
|
240
240
|
var tmp_0 = this;
|
|
241
|
-
var tmp0_elvis_lhs = contentType(this.
|
|
241
|
+
var tmp0_elvis_lhs = contentType(this.p4b_1);
|
|
242
242
|
var tmp_1;
|
|
243
243
|
if (tmp0_elvis_lhs == null) {
|
|
244
244
|
return null;
|
|
@@ -246,10 +246,10 @@
|
|
|
246
246
|
tmp_1 = tmp0_elvis_lhs;
|
|
247
247
|
}
|
|
248
248
|
|
|
249
|
-
tmp_0.
|
|
250
|
-
this.
|
|
249
|
+
tmp_0.s4b_1 = tmp_1;
|
|
250
|
+
this.t4b_1 = suitableCharset(get_request(this.p4b_1).o2j());
|
|
251
251
|
this.d9_1 = 1;
|
|
252
|
-
suspendResult = invoke$convertResponse(this.
|
|
252
|
+
suspendResult = invoke$convertResponse(this.l4b_1, this.m4b_1, this.n4b_1, get_request(this.p4b_1).h2y(), this.r4b_1, this.q4b_1, this.s4b_1, this.t4b_1, this);
|
|
253
253
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
254
254
|
return suspendResult;
|
|
255
255
|
}
|
|
@@ -271,33 +271,33 @@
|
|
|
271
271
|
}
|
|
272
272
|
while (true);
|
|
273
273
|
};
|
|
274
|
-
protoOf(ContentNegotiation$lambda$slambda_1).
|
|
275
|
-
var i = new ContentNegotiation$lambda$slambda_1(this.
|
|
276
|
-
i.
|
|
277
|
-
i.
|
|
278
|
-
i.
|
|
279
|
-
i.
|
|
274
|
+
protoOf(ContentNegotiation$lambda$slambda_1).p3g = function ($this$transformResponseBody, response, body, info, completion) {
|
|
275
|
+
var i = new ContentNegotiation$lambda$slambda_1(this.l4b_1, this.m4b_1, this.n4b_1, completion);
|
|
276
|
+
i.o4b_1 = $this$transformResponseBody;
|
|
277
|
+
i.p4b_1 = response;
|
|
278
|
+
i.q4b_1 = body;
|
|
279
|
+
i.r4b_1 = info;
|
|
280
280
|
return i;
|
|
281
281
|
};
|
|
282
282
|
function ContentNegotiation$lambda$slambda_2($ignoredTypes, $registrations, $this_createClientPlugin, resultContinuation) {
|
|
283
283
|
var i = new ContentNegotiation$lambda$slambda_1($ignoredTypes, $registrations, $this_createClientPlugin, resultContinuation);
|
|
284
284
|
var l = function ($this$transformResponseBody, response, body, info, $completion) {
|
|
285
|
-
return i.
|
|
285
|
+
return i.o3g($this$transformResponseBody, response, body, info, $completion);
|
|
286
286
|
};
|
|
287
287
|
l.$arity = 4;
|
|
288
288
|
return l;
|
|
289
289
|
}
|
|
290
290
|
function ContentNegotiation$lambda$convertRequest$lambda(it) {
|
|
291
291
|
_init_properties_ContentNegotiation_kt__o183go();
|
|
292
|
-
return toString(it.
|
|
292
|
+
return toString(it.r48_1);
|
|
293
293
|
}
|
|
294
294
|
function $invoke$convertRequestCOROUTINE$0(registrations, ignoredTypes, $this_createClientPlugin, request, body, resultContinuation) {
|
|
295
295
|
CoroutineImpl.call(this, resultContinuation);
|
|
296
|
-
this.
|
|
297
|
-
this.
|
|
298
|
-
this.
|
|
299
|
-
this.
|
|
300
|
-
this.
|
|
296
|
+
this.h49_1 = registrations;
|
|
297
|
+
this.i49_1 = ignoredTypes;
|
|
298
|
+
this.j49_1 = $this_createClientPlugin;
|
|
299
|
+
this.k49_1 = request;
|
|
300
|
+
this.l49_1 = body;
|
|
301
301
|
}
|
|
302
302
|
protoOf($invoke$convertRequestCOROUTINE$0).l9 = function () {
|
|
303
303
|
var suspendResult = this.f9_1;
|
|
@@ -307,25 +307,25 @@
|
|
|
307
307
|
switch (tmp) {
|
|
308
308
|
case 0:
|
|
309
309
|
this.e9_1 = 7;
|
|
310
|
-
var _iterator__ex2g4s = this.
|
|
310
|
+
var _iterator__ex2g4s = this.h49_1.p();
|
|
311
311
|
while (_iterator__ex2g4s.q()) {
|
|
312
312
|
var element = _iterator__ex2g4s.r();
|
|
313
313
|
l$ret$1: do {
|
|
314
|
-
get_LOGGER().
|
|
315
|
-
if (this.
|
|
314
|
+
get_LOGGER().k2d('Adding Accept=' + element.s48_1.b2f_1 + ' header for ' + this.k49_1.v2v_1.toString());
|
|
315
|
+
if (this.k49_1.x2v_1.g29(HttpHeaders_getInstance().l2f_1, element.s48_1.toString())) {
|
|
316
316
|
break l$ret$1;
|
|
317
317
|
}
|
|
318
|
-
accept(this.
|
|
318
|
+
accept(this.k49_1, element.s48_1);
|
|
319
319
|
}
|
|
320
320
|
while (false);
|
|
321
321
|
}
|
|
322
322
|
|
|
323
323
|
var tmp_0;
|
|
324
|
-
var tmp_1 = this.
|
|
324
|
+
var tmp_1 = this.l49_1;
|
|
325
325
|
if (tmp_1 instanceof OutgoingContent) {
|
|
326
326
|
tmp_0 = true;
|
|
327
327
|
} else {
|
|
328
|
-
var tmp2 = this.
|
|
328
|
+
var tmp2 = this.i49_1;
|
|
329
329
|
var tmp$ret$2;
|
|
330
330
|
l$ret$3: do {
|
|
331
331
|
var tmp_2;
|
|
@@ -341,7 +341,7 @@
|
|
|
341
341
|
var _iterator__ex2g4s_0 = tmp2.p();
|
|
342
342
|
while (_iterator__ex2g4s_0.q()) {
|
|
343
343
|
var element_0 = _iterator__ex2g4s_0.r();
|
|
344
|
-
if (element_0.eb(this.
|
|
344
|
+
if (element_0.eb(this.l49_1)) {
|
|
345
345
|
tmp$ret$2 = true;
|
|
346
346
|
break l$ret$3;
|
|
347
347
|
}
|
|
@@ -353,36 +353,36 @@
|
|
|
353
353
|
}
|
|
354
354
|
|
|
355
355
|
if (tmp_0) {
|
|
356
|
-
get_LOGGER().
|
|
356
|
+
get_LOGGER().k2d('Body type ' + toString(getKClassFromExpression(this.l49_1)) + ' is in ignored types. ' + ('Skipping ContentNegotiation for ' + this.k49_1.v2v_1.toString() + '.'));
|
|
357
357
|
return null;
|
|
358
358
|
}
|
|
359
359
|
|
|
360
360
|
var tmp_3 = this;
|
|
361
|
-
var tmp0_elvis_lhs = contentType_0(this.
|
|
361
|
+
var tmp0_elvis_lhs = contentType_0(this.k49_1);
|
|
362
362
|
var tmp_4;
|
|
363
363
|
if (tmp0_elvis_lhs == null) {
|
|
364
|
-
this.
|
|
365
|
-
get_LOGGER().
|
|
364
|
+
this.j49_1;
|
|
365
|
+
get_LOGGER().k2d("Request doesn't have Content-Type header. Skipping ContentNegotiation for " + this.k49_1.v2v_1.toString() + '.');
|
|
366
366
|
return null;
|
|
367
367
|
} else {
|
|
368
368
|
tmp_4 = tmp0_elvis_lhs;
|
|
369
369
|
}
|
|
370
370
|
|
|
371
|
-
tmp_3.
|
|
372
|
-
var tmp_5 = this.
|
|
371
|
+
tmp_3.m49_1 = tmp_4;
|
|
372
|
+
var tmp_5 = this.l49_1;
|
|
373
373
|
if (tmp_5 instanceof Unit) {
|
|
374
|
-
get_LOGGER().
|
|
375
|
-
this.
|
|
374
|
+
get_LOGGER().k2d('Sending empty body for ' + this.k49_1.v2v_1.toString());
|
|
375
|
+
this.k49_1.x2v_1.m29(HttpHeaders_getInstance().d2g_1);
|
|
376
376
|
return EmptyContent_getInstance();
|
|
377
377
|
}
|
|
378
378
|
|
|
379
379
|
var tmp_6 = this;
|
|
380
|
-
var tmp0 = this.
|
|
380
|
+
var tmp0 = this.h49_1;
|
|
381
381
|
var destination = ArrayList_init_$Create$();
|
|
382
382
|
var _iterator__ex2g4s_1 = tmp0.p();
|
|
383
383
|
while (_iterator__ex2g4s_1.q()) {
|
|
384
384
|
var element_1 = _iterator__ex2g4s_1.r();
|
|
385
|
-
if (element_1.
|
|
385
|
+
if (element_1.t48_1.v48(this.m49_1)) {
|
|
386
386
|
destination.k(element_1);
|
|
387
387
|
}
|
|
388
388
|
}
|
|
@@ -397,44 +397,44 @@
|
|
|
397
397
|
var tmp1_elvis_lhs = tmp_7;
|
|
398
398
|
var tmp_8;
|
|
399
399
|
if (tmp1_elvis_lhs == null) {
|
|
400
|
-
this.
|
|
401
|
-
get_LOGGER().
|
|
400
|
+
this.j49_1;
|
|
401
|
+
get_LOGGER().k2d('None of the registered converters match request Content-Type=' + this.m49_1.toString() + '. ' + ('Skipping ContentNegotiation for ' + this.k49_1.v2v_1.toString() + '.'));
|
|
402
402
|
return null;
|
|
403
403
|
} else {
|
|
404
404
|
tmp_8 = tmp1_elvis_lhs;
|
|
405
405
|
}
|
|
406
406
|
|
|
407
|
-
tmp_6.
|
|
408
|
-
if (this.
|
|
409
|
-
get_LOGGER().
|
|
407
|
+
tmp_6.n49_1 = tmp_8;
|
|
408
|
+
if (this.k49_1.p3p() == null) {
|
|
409
|
+
get_LOGGER().k2d('Request has unknown body type. Skipping ContentNegotiation for ' + this.k49_1.v2v_1.toString() + '.');
|
|
410
410
|
return null;
|
|
411
411
|
}
|
|
412
412
|
|
|
413
|
-
this.
|
|
413
|
+
this.k49_1.x2v_1.m29(HttpHeaders_getInstance().d2g_1);
|
|
414
414
|
var tmp_9 = this;
|
|
415
|
-
tmp_9.
|
|
415
|
+
tmp_9.o49_1 = this.n49_1;
|
|
416
416
|
this.d9_1 = 1;
|
|
417
417
|
continue $sm;
|
|
418
418
|
case 1:
|
|
419
|
-
this.
|
|
420
|
-
this.
|
|
419
|
+
this.q49_1 = this.o49_1;
|
|
420
|
+
this.r49_1 = this.q49_1.p();
|
|
421
421
|
this.d9_1 = 2;
|
|
422
422
|
continue $sm;
|
|
423
423
|
case 2:
|
|
424
|
-
if (!this.
|
|
424
|
+
if (!this.r49_1.q()) {
|
|
425
425
|
this.d9_1 = 5;
|
|
426
426
|
continue $sm;
|
|
427
427
|
}
|
|
428
428
|
|
|
429
|
-
this.
|
|
429
|
+
this.s49_1 = this.r49_1.r();
|
|
430
430
|
var tmp_10 = this;
|
|
431
|
-
tmp_10.
|
|
432
|
-
this.
|
|
431
|
+
tmp_10.t49_1 = this.s49_1;
|
|
432
|
+
this.u49_1 = this.t49_1;
|
|
433
433
|
this.d9_1 = 3;
|
|
434
|
-
var tmp0_elvis_lhs_0 = charset(this.
|
|
435
|
-
var tmp_11 = tmp0_elvis_lhs_0 == null ? Charsets_getInstance().
|
|
436
|
-
var tmp_12 = ensureNotNull(this.
|
|
437
|
-
var this_0 = this.
|
|
434
|
+
var tmp0_elvis_lhs_0 = charset(this.m49_1);
|
|
435
|
+
var tmp_11 = tmp0_elvis_lhs_0 == null ? Charsets_getInstance().o1l_1 : tmp0_elvis_lhs_0;
|
|
436
|
+
var tmp_12 = ensureNotNull(this.k49_1.p3p());
|
|
437
|
+
var this_0 = this.l49_1;
|
|
438
438
|
var tmp_13;
|
|
439
439
|
if (!equals(this_0, NullBody_instance)) {
|
|
440
440
|
tmp_13 = this_0;
|
|
@@ -442,7 +442,7 @@
|
|
|
442
442
|
tmp_13 = null;
|
|
443
443
|
}
|
|
444
444
|
|
|
445
|
-
suspendResult = this.
|
|
445
|
+
suspendResult = this.u49_1.r48_1.u4b(this.m49_1, tmp_11, tmp_12, tmp_13, this);
|
|
446
446
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
447
447
|
return suspendResult;
|
|
448
448
|
}
|
|
@@ -451,12 +451,12 @@
|
|
|
451
451
|
case 3:
|
|
452
452
|
var result = suspendResult;
|
|
453
453
|
if (!(result == null)) {
|
|
454
|
-
get_LOGGER().
|
|
454
|
+
get_LOGGER().k2d('Converted request body using ' + toString(this.u49_1.r48_1) + ' for ' + this.k49_1.v2v_1.toString());
|
|
455
455
|
}
|
|
456
456
|
|
|
457
457
|
var result_0 = result;
|
|
458
458
|
if (!(result_0 == null)) {
|
|
459
|
-
this.
|
|
459
|
+
this.p49_1 = result_0;
|
|
460
460
|
this.d9_1 = 6;
|
|
461
461
|
continue $sm;
|
|
462
462
|
} else {
|
|
@@ -468,7 +468,7 @@
|
|
|
468
468
|
this.d9_1 = 2;
|
|
469
469
|
continue $sm;
|
|
470
470
|
case 5:
|
|
471
|
-
this.
|
|
471
|
+
this.p49_1 = null;
|
|
472
472
|
if (false) {
|
|
473
473
|
this.d9_1 = 1;
|
|
474
474
|
continue $sm;
|
|
@@ -477,11 +477,11 @@
|
|
|
477
477
|
this.d9_1 = 6;
|
|
478
478
|
continue $sm;
|
|
479
479
|
case 6:
|
|
480
|
-
var tmp2_elvis_lhs = this.
|
|
480
|
+
var tmp2_elvis_lhs = this.p49_1;
|
|
481
481
|
var tmp_14;
|
|
482
482
|
if (tmp2_elvis_lhs == null) {
|
|
483
|
-
var tmp_15 = "Can't convert " + toString(this.
|
|
484
|
-
throw new ContentConverterException(tmp_15 + joinToString(this.
|
|
483
|
+
var tmp_15 = "Can't convert " + toString(this.l49_1) + ' with contentType ' + this.m49_1.toString() + ' using converters ';
|
|
484
|
+
throw new ContentConverterException(tmp_15 + joinToString(this.n49_1, VOID, VOID, VOID, VOID, VOID, ContentNegotiation$lambda$convertRequest$lambda));
|
|
485
485
|
} else {
|
|
486
486
|
tmp_14 = tmp2_elvis_lhs;
|
|
487
487
|
}
|
|
@@ -504,14 +504,14 @@
|
|
|
504
504
|
};
|
|
505
505
|
function $invoke$convertResponseCOROUTINE$1(ignoredTypes, registrations, $this_createClientPlugin, requestUrl, info, body, responseContentType, charset, resultContinuation) {
|
|
506
506
|
CoroutineImpl.call(this, resultContinuation);
|
|
507
|
-
this.
|
|
508
|
-
this.
|
|
509
|
-
this.
|
|
510
|
-
this.
|
|
511
|
-
this.
|
|
512
|
-
this.
|
|
513
|
-
this.
|
|
514
|
-
this.
|
|
507
|
+
this.d4a_1 = ignoredTypes;
|
|
508
|
+
this.e4a_1 = registrations;
|
|
509
|
+
this.f4a_1 = $this_createClientPlugin;
|
|
510
|
+
this.g4a_1 = requestUrl;
|
|
511
|
+
this.h4a_1 = info;
|
|
512
|
+
this.i4a_1 = body;
|
|
513
|
+
this.j4a_1 = responseContentType;
|
|
514
|
+
this.k4a_1 = charset;
|
|
515
515
|
}
|
|
516
516
|
protoOf($invoke$convertResponseCOROUTINE$1).l9 = function () {
|
|
517
517
|
var suspendResult = this.f9_1;
|
|
@@ -521,24 +521,24 @@
|
|
|
521
521
|
switch (tmp) {
|
|
522
522
|
case 0:
|
|
523
523
|
this.e9_1 = 2;
|
|
524
|
-
var tmp_0 = this.
|
|
524
|
+
var tmp_0 = this.i4a_1;
|
|
525
525
|
if (!isInterface(tmp_0, ByteReadChannel)) {
|
|
526
|
-
get_LOGGER().
|
|
526
|
+
get_LOGGER().k2d('Response body is already transformed. Skipping ContentNegotiation for ' + this.g4a_1.toString() + '.');
|
|
527
527
|
return null;
|
|
528
528
|
}
|
|
529
529
|
|
|
530
|
-
if (this.
|
|
531
|
-
get_LOGGER().
|
|
530
|
+
if (this.d4a_1.x1(this.h4a_1.y2c_1)) {
|
|
531
|
+
get_LOGGER().k2d('Response body type ' + toString(this.h4a_1.y2c_1) + ' is in ignored types. ' + ('Skipping ContentNegotiation for ' + this.g4a_1.toString() + '.'));
|
|
532
532
|
return null;
|
|
533
533
|
}
|
|
534
534
|
|
|
535
535
|
var tmp_1 = this;
|
|
536
|
-
var tmp0 = this.
|
|
536
|
+
var tmp0 = this.e4a_1;
|
|
537
537
|
var destination = ArrayList_init_$Create$();
|
|
538
538
|
var _iterator__ex2g4s = tmp0.p();
|
|
539
539
|
while (_iterator__ex2g4s.q()) {
|
|
540
540
|
var element = _iterator__ex2g4s.r();
|
|
541
|
-
if (element.
|
|
541
|
+
if (element.t48_1.v48(this.j4a_1)) {
|
|
542
542
|
destination.k(element);
|
|
543
543
|
}
|
|
544
544
|
}
|
|
@@ -547,7 +547,7 @@
|
|
|
547
547
|
var _iterator__ex2g4s_0 = destination.p();
|
|
548
548
|
while (_iterator__ex2g4s_0.q()) {
|
|
549
549
|
var item = _iterator__ex2g4s_0.r();
|
|
550
|
-
destination_0.k(item.
|
|
550
|
+
destination_0.k(item.r48_1);
|
|
551
551
|
}
|
|
552
552
|
|
|
553
553
|
var tmp_2;
|
|
@@ -560,16 +560,16 @@
|
|
|
560
560
|
var tmp0_elvis_lhs = tmp_2;
|
|
561
561
|
var tmp_3;
|
|
562
562
|
if (tmp0_elvis_lhs == null) {
|
|
563
|
-
this.
|
|
564
|
-
get_LOGGER().
|
|
563
|
+
this.f4a_1;
|
|
564
|
+
get_LOGGER().k2d('None of the registered converters match response with Content-Type=' + this.j4a_1.toString() + '. ' + ('Skipping ContentNegotiation for ' + this.g4a_1.toString() + '.'));
|
|
565
565
|
return null;
|
|
566
566
|
} else {
|
|
567
567
|
tmp_3 = tmp0_elvis_lhs;
|
|
568
568
|
}
|
|
569
569
|
|
|
570
|
-
tmp_1.
|
|
570
|
+
tmp_1.l4a_1 = tmp_3;
|
|
571
571
|
this.d9_1 = 1;
|
|
572
|
-
suspendResult = deserialize(this.
|
|
572
|
+
suspendResult = deserialize(this.l4a_1, this.i4a_1, this.h4a_1, this.k4a_1, this);
|
|
573
573
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
574
574
|
return suspendResult;
|
|
575
575
|
}
|
|
@@ -578,7 +578,7 @@
|
|
|
578
578
|
case 1:
|
|
579
579
|
var result = suspendResult;
|
|
580
580
|
if (!isInterface(result, ByteReadChannel)) {
|
|
581
|
-
get_LOGGER().
|
|
581
|
+
get_LOGGER().k2d('Response body was converted to ' + toString(getKClassFromExpression(result)) + ' for ' + this.g4a_1.toString() + '.');
|
|
582
582
|
}
|
|
583
583
|
|
|
584
584
|
return result;
|
|
@@ -608,11 +608,11 @@
|
|
|
608
608
|
}
|
|
609
609
|
function JsonContentTypeMatcher() {
|
|
610
610
|
}
|
|
611
|
-
protoOf(JsonContentTypeMatcher).
|
|
612
|
-
if (contentType.
|
|
611
|
+
protoOf(JsonContentTypeMatcher).v48 = function (contentType) {
|
|
612
|
+
if (contentType.f2f(Application_getInstance().x2d_1)) {
|
|
613
613
|
return true;
|
|
614
614
|
}
|
|
615
|
-
var value = contentType.
|
|
615
|
+
var value = contentType.e2f().toString();
|
|
616
616
|
return startsWith(value, 'application/', true) && endsWith(value, '+json', true);
|
|
617
617
|
};
|
|
618
618
|
var JsonContentTypeMatcher_instance;
|
|
@@ -633,7 +633,7 @@
|
|
|
633
633
|
}
|
|
634
634
|
}
|
|
635
635
|
//region block: post-declaration
|
|
636
|
-
protoOf(ContentNegotiationConfig).
|
|
636
|
+
protoOf(ContentNegotiationConfig).o2r = register$default;
|
|
637
637
|
//endregion
|
|
638
638
|
//region block: init
|
|
639
639
|
JsonContentTypeMatcher_instance = new JsonContentTypeMatcher();
|