@doordeck/doordeck-headless-sdk 0.209.0 → 0.211.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/Kermit-kermit-core.js +60 -60
- package/kotlin/Kermit-kermit.js +8 -8
- package/kotlin/MultiplatformSettings-multiplatform-settings.js +23 -23
- package/kotlin/Signum-indispensable-asn1.js +4 -0
- package/kotlin/doordeck-sdk.d.ts +36 -1
- package/kotlin/doordeck-sdk.js +12262 -11907
- package/kotlin/kotlin-kotlin-stdlib.js +483 -465
- package/kotlin/kotlinx-atomicfu.js +8 -8
- package/kotlin/kotlinx-coroutines-core.js +182 -155
- package/kotlin/kotlinx-io-kotlinx-io-bytestring.js +20 -20
- package/kotlin/kotlinx-io-kotlinx-io-core.js +35 -35
- package/kotlin/kotlinx-serialization-kotlinx-serialization-core.js +2084 -1887
- package/kotlin/kotlinx-serialization-kotlinx-serialization-json.js +1514 -1514
- package/kotlin/kotlinx-serialization-kotlinx-serialization-properties.js +100 -0
- package/kotlin/ktor-ktor-client-auth.js +273 -273
- package/kotlin/ktor-ktor-client-content-negotiation.js +163 -163
- package/kotlin/ktor-ktor-client-core.js +2156 -2134
- package/kotlin/ktor-ktor-client-logging.js +654 -654
- package/kotlin/ktor-ktor-events.js +12 -12
- package/kotlin/ktor-ktor-http-cio.js +379 -379
- package/kotlin/ktor-ktor-http.js +847 -900
- package/kotlin/ktor-ktor-io.js +109 -162
- package/kotlin/ktor-ktor-serialization-kotlinx-json.js +8 -8
- package/kotlin/ktor-ktor-serialization-kotlinx.js +165 -348
- package/kotlin/ktor-ktor-serialization.js +70 -92
- package/kotlin/ktor-ktor-utils.js +920 -919
- package/kotlin/ktor-ktor-websockets.js +397 -397
- package/package.json +1 -1
|
@@ -1,71 +1,70 @@
|
|
|
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.$_$.
|
|
5
|
-
var initMetadataForClass = kotlin_kotlin.$_$.
|
|
6
|
-
var plus = kotlin_kotlin.$_$.
|
|
7
|
-
var toMutableSet = kotlin_kotlin.$_$.
|
|
8
|
-
var ArrayList_init_$Create$ = kotlin_kotlin.$_$.
|
|
4
|
+
var protoOf = kotlin_kotlin.$_$.nc;
|
|
5
|
+
var initMetadataForClass = kotlin_kotlin.$_$.qb;
|
|
6
|
+
var plus = kotlin_kotlin.$_$.d8;
|
|
7
|
+
var toMutableSet = kotlin_kotlin.$_$.z8;
|
|
8
|
+
var ArrayList_init_$Create$ = kotlin_kotlin.$_$.n3;
|
|
9
9
|
var Application_getInstance = kotlin_io_ktor_ktor_http.$_$.b;
|
|
10
10
|
var register$default = kotlin_io_ktor_ktor_serialization.$_$.b;
|
|
11
|
-
var Unit_instance = kotlin_kotlin.$_$.
|
|
11
|
+
var Unit_instance = kotlin_kotlin.$_$.c3;
|
|
12
12
|
var Configuration = kotlin_io_ktor_ktor_serialization.$_$.c;
|
|
13
13
|
var VOID = kotlin_kotlin.$_$.c;
|
|
14
|
-
var Exception = kotlin_kotlin.$_$.
|
|
15
|
-
var Exception_init_$Init$ = kotlin_kotlin.$_$.
|
|
16
|
-
var captureStack = kotlin_kotlin.$_$.
|
|
17
|
-
var constructCallableReference = kotlin_kotlin.$_$.
|
|
18
|
-
var toString = kotlin_kotlin.$_$.
|
|
14
|
+
var Exception = kotlin_kotlin.$_$.ig;
|
|
15
|
+
var Exception_init_$Init$ = kotlin_kotlin.$_$.m4;
|
|
16
|
+
var captureStack = kotlin_kotlin.$_$.ya;
|
|
17
|
+
var constructCallableReference = kotlin_kotlin.$_$.gb;
|
|
18
|
+
var toString = kotlin_kotlin.$_$.qc;
|
|
19
19
|
var Charsets_getInstance = kotlin_io_ktor_ktor_io.$_$.b;
|
|
20
|
-
var CoroutineImpl = kotlin_kotlin.$_$.
|
|
21
|
-
var THROW_CCE = kotlin_kotlin.$_$.
|
|
20
|
+
var CoroutineImpl = kotlin_kotlin.$_$.y9;
|
|
21
|
+
var THROW_CCE = kotlin_kotlin.$_$.pg;
|
|
22
22
|
var TransformRequestBodyContext = kotlin_io_ktor_ktor_client_core.$_$.m;
|
|
23
23
|
var HttpRequestBuilder = kotlin_io_ktor_ktor_client_core.$_$.d1;
|
|
24
24
|
var TypeInfo = kotlin_io_ktor_ktor_utils.$_$.o;
|
|
25
|
-
var get_COROUTINE_SUSPENDED = kotlin_kotlin.$_$.
|
|
26
|
-
var initMetadataForLambda = kotlin_kotlin.$_$.
|
|
25
|
+
var get_COROUTINE_SUSPENDED = kotlin_kotlin.$_$.h9;
|
|
26
|
+
var initMetadataForLambda = kotlin_kotlin.$_$.vb;
|
|
27
27
|
var TransformResponseBodyContext = kotlin_io_ktor_ktor_client_core.$_$.n;
|
|
28
28
|
var HttpResponse = kotlin_io_ktor_ktor_client_core.$_$.k1;
|
|
29
29
|
var ByteReadChannel = kotlin_io_ktor_ktor_io.$_$.n1;
|
|
30
|
-
var isInterface = kotlin_kotlin.$_$.
|
|
30
|
+
var isInterface = kotlin_kotlin.$_$.fc;
|
|
31
31
|
var contentType = kotlin_io_ktor_ktor_http.$_$.o1;
|
|
32
|
+
var charset = kotlin_io_ktor_ktor_http.$_$.l1;
|
|
32
33
|
var get_request = kotlin_io_ktor_ktor_client_core.$_$.m1;
|
|
33
|
-
var
|
|
34
|
-
var
|
|
35
|
-
var emptyList = kotlin_kotlin.$_$.w6;
|
|
34
|
+
var Collection = kotlin_kotlin.$_$.m5;
|
|
35
|
+
var emptyList = kotlin_kotlin.$_$.a7;
|
|
36
36
|
var Companion_getInstance = kotlin_io_ktor_ktor_http.$_$.c;
|
|
37
37
|
var accept = kotlin_io_ktor_ktor_client_core.$_$.f1;
|
|
38
38
|
var OutgoingContent = kotlin_io_ktor_ktor_http.$_$.v;
|
|
39
|
-
var getKClassFromExpression = kotlin_kotlin.$_$.
|
|
39
|
+
var getKClassFromExpression = kotlin_kotlin.$_$.fd;
|
|
40
40
|
var contentType_0 = kotlin_io_ktor_ktor_http.$_$.n1;
|
|
41
41
|
var EmptyContent_getInstance = kotlin_io_ktor_ktor_client_core.$_$.f;
|
|
42
|
-
var Unit = kotlin_kotlin.$_$.
|
|
43
|
-
var
|
|
44
|
-
var ensureNotNull = kotlin_kotlin.$_$.bh;
|
|
42
|
+
var Unit = kotlin_kotlin.$_$.ah;
|
|
43
|
+
var ensureNotNull = kotlin_kotlin.$_$.hh;
|
|
45
44
|
var NullBody_instance = kotlin_io_ktor_ktor_http.$_$.a;
|
|
46
|
-
var equals = kotlin_kotlin.$_$.
|
|
47
|
-
var joinToString = kotlin_kotlin.$_$.
|
|
48
|
-
var initMetadataForCoroutine = kotlin_kotlin.$_$.
|
|
49
|
-
var collectionSizeOrDefault = kotlin_kotlin.$_$.
|
|
50
|
-
var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.
|
|
45
|
+
var equals = kotlin_kotlin.$_$.ib;
|
|
46
|
+
var joinToString = kotlin_kotlin.$_$.q7;
|
|
47
|
+
var initMetadataForCoroutine = kotlin_kotlin.$_$.sb;
|
|
48
|
+
var collectionSizeOrDefault = kotlin_kotlin.$_$.f6;
|
|
49
|
+
var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.m3;
|
|
51
50
|
var deserialize = kotlin_io_ktor_ktor_serialization.$_$.a;
|
|
52
51
|
var KtorSimpleLogger = kotlin_io_ktor_ktor_utils.$_$.j;
|
|
53
|
-
var PrimitiveClasses_getInstance = kotlin_kotlin.$_$.
|
|
52
|
+
var PrimitiveClasses_getInstance = kotlin_kotlin.$_$.q2;
|
|
54
53
|
var HttpStatusCode = kotlin_io_ktor_ktor_http.$_$.b1;
|
|
55
|
-
var getKClass = kotlin_kotlin.$_$.
|
|
54
|
+
var getKClass = kotlin_kotlin.$_$.gd;
|
|
56
55
|
var ClientSSESession = kotlin_io_ktor_ktor_client_core.$_$.r;
|
|
57
56
|
var ClientSSESessionWithDeserialization = kotlin_io_ktor_ktor_client_core.$_$.q;
|
|
58
|
-
var setOf = kotlin_kotlin.$_$.
|
|
59
|
-
var KtList = kotlin_kotlin.$_$.
|
|
57
|
+
var setOf = kotlin_kotlin.$_$.l8;
|
|
58
|
+
var KtList = kotlin_kotlin.$_$.r5;
|
|
60
59
|
var ContentType = kotlin_io_ktor_ktor_http.$_$.z;
|
|
61
|
-
var arrayOf = kotlin_kotlin.$_$.
|
|
62
|
-
var createKType = kotlin_kotlin.$_$.
|
|
63
|
-
var createInvariantKTypeProjection = kotlin_kotlin.$_$.
|
|
60
|
+
var arrayOf = kotlin_kotlin.$_$.dh;
|
|
61
|
+
var createKType = kotlin_kotlin.$_$.ed;
|
|
62
|
+
var createInvariantKTypeProjection = kotlin_kotlin.$_$.cd;
|
|
64
63
|
var AttributeKey = kotlin_io_ktor_ktor_utils.$_$.q;
|
|
65
64
|
var createClientPlugin = kotlin_io_ktor_ktor_client_core.$_$.o;
|
|
66
|
-
var endsWith = kotlin_kotlin.$_$.
|
|
67
|
-
var initMetadataForObject = kotlin_kotlin.$_$.
|
|
68
|
-
var LinkedHashSet_init_$Create$ = kotlin_kotlin.$_$.
|
|
65
|
+
var endsWith = kotlin_kotlin.$_$.yd;
|
|
66
|
+
var initMetadataForObject = kotlin_kotlin.$_$.wb;
|
|
67
|
+
var LinkedHashSet_init_$Create$ = kotlin_kotlin.$_$.y3;
|
|
69
68
|
//endregion
|
|
70
69
|
//region block: pre-declaration
|
|
71
70
|
initMetadataForClass(ConverterRegistration, 'ConverterRegistration');
|
|
@@ -99,35 +98,35 @@
|
|
|
99
98
|
}
|
|
100
99
|
var ContentNegotiation;
|
|
101
100
|
function ConverterRegistration(converter, contentTypeToSend, contentTypeMatcher) {
|
|
102
|
-
this.
|
|
103
|
-
this.
|
|
104
|
-
this.
|
|
101
|
+
this.d5p_1 = converter;
|
|
102
|
+
this.e5p_1 = contentTypeToSend;
|
|
103
|
+
this.f5p_1 = contentTypeMatcher;
|
|
105
104
|
}
|
|
106
105
|
function defaultMatcher($this, pattern) {
|
|
107
106
|
return new ContentNegotiationConfig$defaultMatcher$1(pattern);
|
|
108
107
|
}
|
|
109
108
|
function ContentNegotiationConfig$defaultMatcher$1($pattern) {
|
|
110
|
-
this.
|
|
109
|
+
this.g5p_1 = $pattern;
|
|
111
110
|
}
|
|
112
|
-
protoOf(ContentNegotiationConfig$defaultMatcher$1).
|
|
113
|
-
return contentType.
|
|
111
|
+
protoOf(ContentNegotiationConfig$defaultMatcher$1).h5p = function (contentType) {
|
|
112
|
+
return contentType.b2y(this.g5p_1);
|
|
114
113
|
};
|
|
115
114
|
function ContentNegotiationConfig() {
|
|
116
|
-
this.
|
|
115
|
+
this.i5p_1 = toMutableSet(plus(get_DefaultIgnoredTypes(), get_DefaultCommonIgnoredTypes()));
|
|
117
116
|
var tmp = this;
|
|
118
117
|
// Inline function 'kotlin.collections.mutableListOf' call
|
|
119
|
-
tmp.
|
|
120
|
-
this.
|
|
118
|
+
tmp.j5p_1 = ArrayList_init_$Create$();
|
|
119
|
+
this.k5p_1 = null;
|
|
121
120
|
}
|
|
122
|
-
protoOf(ContentNegotiationConfig).
|
|
123
|
-
var matcher = contentType.
|
|
124
|
-
this.
|
|
121
|
+
protoOf(ContentNegotiationConfig).g3o = function (contentType, converter, configuration) {
|
|
122
|
+
var matcher = contentType.b2y(Application_getInstance().h2w_1) ? JsonContentTypeMatcher_instance : defaultMatcher(this, contentType);
|
|
123
|
+
this.l5p(contentType, converter, matcher, configuration);
|
|
125
124
|
};
|
|
126
|
-
protoOf(ContentNegotiationConfig).
|
|
125
|
+
protoOf(ContentNegotiationConfig).l5p = function (contentTypeToSend, converter, contentTypeMatcher, configuration) {
|
|
127
126
|
// Inline function 'kotlin.apply' call
|
|
128
127
|
configuration(converter);
|
|
129
128
|
var registration = new ConverterRegistration(converter, contentTypeToSend, contentTypeMatcher);
|
|
130
|
-
this.
|
|
129
|
+
this.j5p_1.j1(registration);
|
|
131
130
|
};
|
|
132
131
|
function ContentConverterException(message) {
|
|
133
132
|
Exception_init_$Init$(message, this);
|
|
@@ -140,15 +139,15 @@
|
|
|
140
139
|
}
|
|
141
140
|
function ContentNegotiation$lambda($this$createClientPlugin) {
|
|
142
141
|
_init_properties_ContentNegotiation_kt__o183go();
|
|
143
|
-
var registrations = $this$createClientPlugin.
|
|
144
|
-
var ignoredTypes = $this$createClientPlugin.
|
|
145
|
-
$this$createClientPlugin.
|
|
146
|
-
$this$createClientPlugin.
|
|
142
|
+
var registrations = $this$createClientPlugin.k40_1.j5p_1;
|
|
143
|
+
var ignoredTypes = $this$createClientPlugin.k40_1.i5p_1;
|
|
144
|
+
$this$createClientPlugin.g4l(ContentNegotiation$lambda$slambda_0(registrations, $this$createClientPlugin, ignoredTypes, null));
|
|
145
|
+
$this$createClientPlugin.p49(ContentNegotiation$lambda$slambda_2(ignoredTypes, registrations, $this$createClientPlugin, null));
|
|
147
146
|
return Unit_instance;
|
|
148
147
|
}
|
|
149
148
|
function ContentNegotiation$lambda$convertRequest$lambda(it) {
|
|
150
149
|
_init_properties_ContentNegotiation_kt__o183go();
|
|
151
|
-
return toString(it.
|
|
150
|
+
return toString(it.d5p_1);
|
|
152
151
|
}
|
|
153
152
|
function invoke$convertRequest(registrations, $this_createClientPlugin, ignoredTypes, request, body, $completion) {
|
|
154
153
|
var tmp = new $invoke$convertRequestCOROUTINE$(registrations, $this_createClientPlugin, ignoredTypes, request, body, $completion);
|
|
@@ -164,22 +163,22 @@
|
|
|
164
163
|
return tmp.l9();
|
|
165
164
|
}
|
|
166
165
|
function ContentNegotiation$lambda$slambda($registrations, $this_createClientPlugin, $ignoredTypes, resultContinuation) {
|
|
167
|
-
this.
|
|
168
|
-
this.
|
|
169
|
-
this.
|
|
166
|
+
this.d5r_1 = $registrations;
|
|
167
|
+
this.e5r_1 = $this_createClientPlugin;
|
|
168
|
+
this.f5r_1 = $ignoredTypes;
|
|
170
169
|
CoroutineImpl.call(this, resultContinuation);
|
|
171
170
|
}
|
|
172
|
-
protoOf(ContentNegotiation$lambda$slambda).
|
|
173
|
-
var tmp = this.
|
|
171
|
+
protoOf(ContentNegotiation$lambda$slambda).k5r = function ($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion) {
|
|
172
|
+
var tmp = this.l5r($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion);
|
|
174
173
|
tmp.f9_1 = Unit_instance;
|
|
175
174
|
tmp.g9_1 = null;
|
|
176
175
|
return tmp.l9();
|
|
177
176
|
};
|
|
178
|
-
protoOf(ContentNegotiation$lambda$slambda).
|
|
177
|
+
protoOf(ContentNegotiation$lambda$slambda).u4a = function (p1, p2, p3, p4, $completion) {
|
|
179
178
|
var tmp = p1 instanceof TransformRequestBodyContext ? p1 : THROW_CCE();
|
|
180
179
|
var tmp_0 = p2 instanceof HttpRequestBuilder ? p2 : THROW_CCE();
|
|
181
180
|
var tmp_1 = !(p3 == null) ? p3 : THROW_CCE();
|
|
182
|
-
return this.
|
|
181
|
+
return this.k5r(tmp, tmp_0, tmp_1, (p4 == null ? true : p4 instanceof TypeInfo) ? p4 : THROW_CCE(), $completion);
|
|
183
182
|
};
|
|
184
183
|
protoOf(ContentNegotiation$lambda$slambda).l9 = function () {
|
|
185
184
|
var suspendResult = this.f9_1;
|
|
@@ -190,7 +189,7 @@
|
|
|
190
189
|
case 0:
|
|
191
190
|
this.e9_1 = 2;
|
|
192
191
|
this.d9_1 = 1;
|
|
193
|
-
suspendResult = invoke$convertRequest(this.
|
|
192
|
+
suspendResult = invoke$convertRequest(this.d5r_1, this.e5r_1, this.f5r_1, this.h5r_1, this.i5r_1, this);
|
|
194
193
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
195
194
|
return suspendResult;
|
|
196
195
|
}
|
|
@@ -212,37 +211,37 @@
|
|
|
212
211
|
}
|
|
213
212
|
while (true);
|
|
214
213
|
};
|
|
215
|
-
protoOf(ContentNegotiation$lambda$slambda).
|
|
216
|
-
var i = new ContentNegotiation$lambda$slambda(this.
|
|
217
|
-
i.
|
|
218
|
-
i.
|
|
219
|
-
i.
|
|
220
|
-
i.
|
|
214
|
+
protoOf(ContentNegotiation$lambda$slambda).l5r = function ($this$transformRequestBody, request, body, _unused_var__etf5q3, completion) {
|
|
215
|
+
var i = new ContentNegotiation$lambda$slambda(this.d5r_1, this.e5r_1, this.f5r_1, completion);
|
|
216
|
+
i.g5r_1 = $this$transformRequestBody;
|
|
217
|
+
i.h5r_1 = request;
|
|
218
|
+
i.i5r_1 = body;
|
|
219
|
+
i.j5r_1 = _unused_var__etf5q3;
|
|
221
220
|
return i;
|
|
222
221
|
};
|
|
223
222
|
function ContentNegotiation$lambda$slambda_0($registrations, $this_createClientPlugin, $ignoredTypes, resultContinuation) {
|
|
224
223
|
var i = new ContentNegotiation$lambda$slambda($registrations, $this_createClientPlugin, $ignoredTypes, resultContinuation);
|
|
225
224
|
return constructCallableReference(function ($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion) {
|
|
226
|
-
return i.
|
|
225
|
+
return i.k5r($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion);
|
|
227
226
|
}, 4);
|
|
228
227
|
}
|
|
229
228
|
function ContentNegotiation$lambda$slambda_1($ignoredTypes, $registrations, $this_createClientPlugin, resultContinuation) {
|
|
230
|
-
this.
|
|
231
|
-
this.
|
|
232
|
-
this.
|
|
229
|
+
this.u5r_1 = $ignoredTypes;
|
|
230
|
+
this.v5r_1 = $registrations;
|
|
231
|
+
this.w5r_1 = $this_createClientPlugin;
|
|
233
232
|
CoroutineImpl.call(this, resultContinuation);
|
|
234
233
|
}
|
|
235
|
-
protoOf(ContentNegotiation$lambda$slambda_1).
|
|
236
|
-
var tmp = this.
|
|
234
|
+
protoOf(ContentNegotiation$lambda$slambda_1).s4a = function ($this$transformResponseBody, response, body, info, $completion) {
|
|
235
|
+
var tmp = this.t4a($this$transformResponseBody, response, body, info, $completion);
|
|
237
236
|
tmp.f9_1 = Unit_instance;
|
|
238
237
|
tmp.g9_1 = null;
|
|
239
238
|
return tmp.l9();
|
|
240
239
|
};
|
|
241
|
-
protoOf(ContentNegotiation$lambda$slambda_1).
|
|
240
|
+
protoOf(ContentNegotiation$lambda$slambda_1).u4a = function (p1, p2, p3, p4, $completion) {
|
|
242
241
|
var tmp = p1 instanceof TransformResponseBodyContext ? p1 : THROW_CCE();
|
|
243
242
|
var tmp_0 = p2 instanceof HttpResponse ? p2 : THROW_CCE();
|
|
244
243
|
var tmp_1 = (!(p3 == null) ? isInterface(p3, ByteReadChannel) : false) ? p3 : THROW_CCE();
|
|
245
|
-
return this.
|
|
244
|
+
return this.s4a(tmp, tmp_0, tmp_1, p4 instanceof TypeInfo ? p4 : THROW_CCE(), $completion);
|
|
246
245
|
};
|
|
247
246
|
protoOf(ContentNegotiation$lambda$slambda_1).l9 = function () {
|
|
248
247
|
var suspendResult = this.f9_1;
|
|
@@ -252,7 +251,7 @@
|
|
|
252
251
|
switch (tmp) {
|
|
253
252
|
case 0:
|
|
254
253
|
this.e9_1 = 2;
|
|
255
|
-
var tmp0_elvis_lhs = contentType(this.
|
|
254
|
+
var tmp0_elvis_lhs = contentType(this.y5r_1);
|
|
256
255
|
var tmp_0;
|
|
257
256
|
if (tmp0_elvis_lhs == null) {
|
|
258
257
|
return null;
|
|
@@ -261,9 +260,10 @@
|
|
|
261
260
|
}
|
|
262
261
|
|
|
263
262
|
var contentType_0 = tmp_0;
|
|
264
|
-
var
|
|
263
|
+
var tmp1_elvis_lhs = charset(contentType_0);
|
|
264
|
+
var charset_0 = tmp1_elvis_lhs == null ? Charsets_getInstance().c1z_1 : tmp1_elvis_lhs;
|
|
265
265
|
this.d9_1 = 1;
|
|
266
|
-
suspendResult = invoke$convertResponse(this.
|
|
266
|
+
suspendResult = invoke$convertResponse(this.u5r_1, this.v5r_1, this.w5r_1, get_request(this.y5r_1).b3u(), this.a5s_1, this.z5r_1, contentType_0, charset_0, this);
|
|
267
267
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
268
268
|
return suspendResult;
|
|
269
269
|
}
|
|
@@ -285,27 +285,27 @@
|
|
|
285
285
|
}
|
|
286
286
|
while (true);
|
|
287
287
|
};
|
|
288
|
-
protoOf(ContentNegotiation$lambda$slambda_1).
|
|
289
|
-
var i = new ContentNegotiation$lambda$slambda_1(this.
|
|
290
|
-
i.
|
|
291
|
-
i.
|
|
292
|
-
i.
|
|
293
|
-
i.
|
|
288
|
+
protoOf(ContentNegotiation$lambda$slambda_1).t4a = function ($this$transformResponseBody, response, body, info, completion) {
|
|
289
|
+
var i = new ContentNegotiation$lambda$slambda_1(this.u5r_1, this.v5r_1, this.w5r_1, completion);
|
|
290
|
+
i.x5r_1 = $this$transformResponseBody;
|
|
291
|
+
i.y5r_1 = response;
|
|
292
|
+
i.z5r_1 = body;
|
|
293
|
+
i.a5s_1 = info;
|
|
294
294
|
return i;
|
|
295
295
|
};
|
|
296
296
|
function ContentNegotiation$lambda$slambda_2($ignoredTypes, $registrations, $this_createClientPlugin, resultContinuation) {
|
|
297
297
|
var i = new ContentNegotiation$lambda$slambda_1($ignoredTypes, $registrations, $this_createClientPlugin, resultContinuation);
|
|
298
298
|
return constructCallableReference(function ($this$transformResponseBody, response, body, info, $completion) {
|
|
299
|
-
return i.
|
|
299
|
+
return i.s4a($this$transformResponseBody, response, body, info, $completion);
|
|
300
300
|
}, 4);
|
|
301
301
|
}
|
|
302
302
|
function $invoke$convertRequestCOROUTINE$(registrations, $this_createClientPlugin, ignoredTypes, request, body, resultContinuation) {
|
|
303
303
|
CoroutineImpl.call(this, resultContinuation);
|
|
304
|
-
this.
|
|
305
|
-
this.
|
|
306
|
-
this.
|
|
307
|
-
this.
|
|
308
|
-
this.
|
|
304
|
+
this.u5p_1 = registrations;
|
|
305
|
+
this.v5p_1 = $this_createClientPlugin;
|
|
306
|
+
this.w5p_1 = ignoredTypes;
|
|
307
|
+
this.x5p_1 = request;
|
|
308
|
+
this.y5p_1 = body;
|
|
309
309
|
}
|
|
310
310
|
protoOf($invoke$convertRequestCOROUTINE$).l9 = function () {
|
|
311
311
|
var suspendResult = this.f9_1;
|
|
@@ -316,9 +316,9 @@
|
|
|
316
316
|
case 0:
|
|
317
317
|
this.e9_1 = 7;
|
|
318
318
|
var tmp_0;
|
|
319
|
-
if (this.
|
|
320
|
-
var excluded = this.
|
|
321
|
-
var tmp0 = this.
|
|
319
|
+
if (this.x5p_1.p3s_1.s2l(get_ExcludedContentTypes())) {
|
|
320
|
+
var excluded = this.x5p_1.p3s_1.q2l(get_ExcludedContentTypes());
|
|
321
|
+
var tmp0 = this.u5p_1;
|
|
322
322
|
var destination = ArrayList_init_$Create$();
|
|
323
323
|
var _iterator__ex2g4s = tmp0.t();
|
|
324
324
|
while (_iterator__ex2g4s.u()) {
|
|
@@ -338,7 +338,7 @@
|
|
|
338
338
|
var _iterator__ex2g4s_0 = excluded.t();
|
|
339
339
|
while (_iterator__ex2g4s_0.u()) {
|
|
340
340
|
var element_0 = _iterator__ex2g4s_0.v();
|
|
341
|
-
if (element.
|
|
341
|
+
if (element.e5p_1.b2y(element_0)) {
|
|
342
342
|
tmp$ret$0 = false;
|
|
343
343
|
break l$ret$1;
|
|
344
344
|
}
|
|
@@ -352,11 +352,11 @@
|
|
|
352
352
|
}
|
|
353
353
|
tmp_0 = destination;
|
|
354
354
|
} else {
|
|
355
|
-
tmp_0 = this.
|
|
355
|
+
tmp_0 = this.u5p_1;
|
|
356
356
|
}
|
|
357
357
|
|
|
358
358
|
var requestRegistrations = tmp_0;
|
|
359
|
-
var tmp0_elvis_lhs = this.
|
|
359
|
+
var tmp0_elvis_lhs = this.x5p_1.m3s_1.h2q('Accept');
|
|
360
360
|
var acceptHeaders = tmp0_elvis_lhs == null ? emptyList() : tmp0_elvis_lhs;
|
|
361
361
|
var _iterator__ex2g4s_1 = requestRegistrations.t();
|
|
362
362
|
while (_iterator__ex2g4s_1.u()) {
|
|
@@ -376,7 +376,7 @@
|
|
|
376
376
|
var _iterator__ex2g4s_2 = acceptHeaders.t();
|
|
377
377
|
while (_iterator__ex2g4s_2.u()) {
|
|
378
378
|
var element_2 = _iterator__ex2g4s_2.v();
|
|
379
|
-
if (Companion_getInstance().ao(element_2).
|
|
379
|
+
if (Companion_getInstance().ao(element_2).b2y(element_1.e5p_1)) {
|
|
380
380
|
tmp$ret$2 = false;
|
|
381
381
|
break l$ret$3;
|
|
382
382
|
}
|
|
@@ -385,19 +385,19 @@
|
|
|
385
385
|
}
|
|
386
386
|
while (false);
|
|
387
387
|
if (tmp$ret$2) {
|
|
388
|
-
var qValue = this.
|
|
389
|
-
var contentTypeToSend = qValue == null ? element_1.
|
|
390
|
-
get_LOGGER().
|
|
391
|
-
accept(this.
|
|
388
|
+
var qValue = this.v5p_1.k40_1.k5p_1;
|
|
389
|
+
var contentTypeToSend = qValue == null ? element_1.e5p_1 : element_1.e5p_1.z2x('q', qValue.toString());
|
|
390
|
+
get_LOGGER().d2v('Adding Accept=' + contentTypeToSend.toString() + ' header for ' + this.x5p_1.k3s_1.toString());
|
|
391
|
+
accept(this.x5p_1, contentTypeToSend);
|
|
392
392
|
}
|
|
393
393
|
}
|
|
394
394
|
|
|
395
395
|
var tmp_3;
|
|
396
|
-
var tmp_4 = this.
|
|
396
|
+
var tmp_4 = this.y5p_1;
|
|
397
397
|
if (tmp_4 instanceof OutgoingContent) {
|
|
398
398
|
tmp_3 = true;
|
|
399
399
|
} else {
|
|
400
|
-
var tmp0_0 = this.
|
|
400
|
+
var tmp0_0 = this.w5p_1;
|
|
401
401
|
var tmp$ret$4;
|
|
402
402
|
l$ret$5: do {
|
|
403
403
|
var tmp_5;
|
|
@@ -413,7 +413,7 @@
|
|
|
413
413
|
var _iterator__ex2g4s_3 = tmp0_0.t();
|
|
414
414
|
while (_iterator__ex2g4s_3.u()) {
|
|
415
415
|
var element_3 = _iterator__ex2g4s_3.v();
|
|
416
|
-
if (element_3.eb(this.
|
|
416
|
+
if (element_3.eb(this.y5p_1)) {
|
|
417
417
|
tmp$ret$4 = true;
|
|
418
418
|
break l$ret$5;
|
|
419
419
|
}
|
|
@@ -425,36 +425,36 @@
|
|
|
425
425
|
}
|
|
426
426
|
|
|
427
427
|
if (tmp_3) {
|
|
428
|
-
get_LOGGER().
|
|
428
|
+
get_LOGGER().d2v('Body type ' + toString(getKClassFromExpression(this.y5p_1)) + ' is in ignored types. ' + ('Skipping ContentNegotiation for ' + this.x5p_1.k3s_1.toString() + '.'));
|
|
429
429
|
return null;
|
|
430
430
|
}
|
|
431
431
|
|
|
432
432
|
var tmp_6 = this;
|
|
433
|
-
var tmp0_elvis_lhs_0 = contentType_0(this.
|
|
433
|
+
var tmp0_elvis_lhs_0 = contentType_0(this.x5p_1);
|
|
434
434
|
var tmp_7;
|
|
435
435
|
if (tmp0_elvis_lhs_0 == null) {
|
|
436
|
-
this.
|
|
437
|
-
get_LOGGER().
|
|
436
|
+
this.v5p_1;
|
|
437
|
+
get_LOGGER().d2v("Request doesn't have Content-Type header. Skipping ContentNegotiation for " + this.x5p_1.k3s_1.toString() + '.');
|
|
438
438
|
return null;
|
|
439
439
|
} else {
|
|
440
440
|
tmp_7 = tmp0_elvis_lhs_0;
|
|
441
441
|
}
|
|
442
442
|
|
|
443
|
-
tmp_6.
|
|
444
|
-
var tmp_8 = this.
|
|
443
|
+
tmp_6.a5q_1 = tmp_7;
|
|
444
|
+
var tmp_8 = this.y5p_1;
|
|
445
445
|
if (tmp_8 instanceof Unit) {
|
|
446
|
-
get_LOGGER().
|
|
447
|
-
this.
|
|
446
|
+
get_LOGGER().d2v('Sending empty body for ' + this.x5p_1.k3s_1.toString());
|
|
447
|
+
this.x5p_1.m3s_1.r2q('Content-Type');
|
|
448
448
|
return EmptyContent_getInstance();
|
|
449
449
|
}
|
|
450
450
|
|
|
451
451
|
var tmp_9 = this;
|
|
452
|
-
var tmp0_1 = this.
|
|
452
|
+
var tmp0_1 = this.u5p_1;
|
|
453
453
|
var destination_0 = ArrayList_init_$Create$();
|
|
454
454
|
var _iterator__ex2g4s_4 = tmp0_1.t();
|
|
455
455
|
while (_iterator__ex2g4s_4.u()) {
|
|
456
456
|
var element_4 = _iterator__ex2g4s_4.v();
|
|
457
|
-
if (element_4.
|
|
457
|
+
if (element_4.f5p_1.h5p(this.a5q_1)) {
|
|
458
458
|
destination_0.j1(element_4);
|
|
459
459
|
}
|
|
460
460
|
}
|
|
@@ -469,40 +469,40 @@
|
|
|
469
469
|
var tmp1_elvis_lhs = tmp_10;
|
|
470
470
|
var tmp_11;
|
|
471
471
|
if (tmp1_elvis_lhs == null) {
|
|
472
|
-
this.
|
|
473
|
-
get_LOGGER().
|
|
472
|
+
this.v5p_1;
|
|
473
|
+
get_LOGGER().d2v('None of the registered converters match request Content-Type=' + this.a5q_1.toString() + '. ' + ('Skipping ContentNegotiation for ' + this.x5p_1.k3s_1.toString() + '.'));
|
|
474
474
|
return null;
|
|
475
475
|
} else {
|
|
476
476
|
tmp_11 = tmp1_elvis_lhs;
|
|
477
477
|
}
|
|
478
478
|
|
|
479
|
-
tmp_9.
|
|
480
|
-
if (this.
|
|
481
|
-
get_LOGGER().
|
|
479
|
+
tmp_9.z5p_1 = tmp_11;
|
|
480
|
+
if (this.x5p_1.o4n() == null) {
|
|
481
|
+
get_LOGGER().d2v('Request has unknown body type. Skipping ContentNegotiation for ' + this.x5p_1.k3s_1.toString() + '.');
|
|
482
482
|
return null;
|
|
483
483
|
}
|
|
484
484
|
|
|
485
|
-
this.
|
|
486
|
-
this.
|
|
485
|
+
this.x5p_1.m3s_1.r2q('Content-Type');
|
|
486
|
+
this.e5q_1 = this.z5p_1;
|
|
487
487
|
this.d9_1 = 1;
|
|
488
488
|
continue $sm;
|
|
489
489
|
case 1:
|
|
490
|
-
this.
|
|
490
|
+
this.d5q_1 = this.e5q_1.t();
|
|
491
491
|
this.d9_1 = 2;
|
|
492
492
|
continue $sm;
|
|
493
493
|
case 2:
|
|
494
|
-
if (!this.
|
|
494
|
+
if (!this.d5q_1.u()) {
|
|
495
495
|
this.d9_1 = 5;
|
|
496
496
|
continue $sm;
|
|
497
497
|
}
|
|
498
498
|
|
|
499
|
-
var element_5 = this.
|
|
500
|
-
this.
|
|
499
|
+
var element_5 = this.d5q_1.v();
|
|
500
|
+
this.c5q_1 = element_5;
|
|
501
501
|
this.d9_1 = 3;
|
|
502
|
-
var tmp0_elvis_lhs_1 = charset(this.
|
|
502
|
+
var tmp0_elvis_lhs_1 = charset(this.a5q_1);
|
|
503
503
|
var tmp_12 = tmp0_elvis_lhs_1 == null ? Charsets_getInstance().c1z_1 : tmp0_elvis_lhs_1;
|
|
504
|
-
var tmp_13 = ensureNotNull(this.
|
|
505
|
-
var this_0 = this.
|
|
504
|
+
var tmp_13 = ensureNotNull(this.x5p_1.o4n());
|
|
505
|
+
var this_0 = this.y5p_1;
|
|
506
506
|
var tmp_14;
|
|
507
507
|
if (!equals(this_0, NullBody_instance)) {
|
|
508
508
|
tmp_14 = this_0;
|
|
@@ -510,7 +510,7 @@
|
|
|
510
510
|
tmp_14 = null;
|
|
511
511
|
}
|
|
512
512
|
|
|
513
|
-
suspendResult = this.
|
|
513
|
+
suspendResult = this.c5q_1.d5p_1.b5s(this.a5q_1, tmp_12, tmp_13, tmp_14, this);
|
|
514
514
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
515
515
|
return suspendResult;
|
|
516
516
|
}
|
|
@@ -519,12 +519,12 @@
|
|
|
519
519
|
case 3:
|
|
520
520
|
var result = suspendResult;
|
|
521
521
|
if (!(result == null)) {
|
|
522
|
-
get_LOGGER().
|
|
522
|
+
get_LOGGER().d2v('Converted request body using ' + toString(this.c5q_1.d5p_1) + ' for ' + this.x5p_1.k3s_1.toString());
|
|
523
523
|
}
|
|
524
524
|
|
|
525
525
|
var result_0 = result;
|
|
526
526
|
if (!(result_0 == null)) {
|
|
527
|
-
this.
|
|
527
|
+
this.b5q_1 = result_0;
|
|
528
528
|
this.d9_1 = 6;
|
|
529
529
|
continue $sm;
|
|
530
530
|
} else {
|
|
@@ -536,7 +536,7 @@
|
|
|
536
536
|
this.d9_1 = 2;
|
|
537
537
|
continue $sm;
|
|
538
538
|
case 5:
|
|
539
|
-
this.
|
|
539
|
+
this.b5q_1 = null;
|
|
540
540
|
if (false) {
|
|
541
541
|
this.d9_1 = 1;
|
|
542
542
|
continue $sm;
|
|
@@ -545,11 +545,11 @@
|
|
|
545
545
|
this.d9_1 = 6;
|
|
546
546
|
continue $sm;
|
|
547
547
|
case 6:
|
|
548
|
-
var tmp2_elvis_lhs = this.
|
|
548
|
+
var tmp2_elvis_lhs = this.b5q_1;
|
|
549
549
|
var tmp_15;
|
|
550
550
|
if (tmp2_elvis_lhs == null) {
|
|
551
|
-
var tmp_16 = "Can't convert " + toString(this.
|
|
552
|
-
throw new ContentConverterException(tmp_16 + joinToString(this.
|
|
551
|
+
var tmp_16 = "Can't convert " + toString(this.y5p_1) + ' with contentType ' + this.a5q_1.toString() + ' using converters ';
|
|
552
|
+
throw new ContentConverterException(tmp_16 + joinToString(this.z5p_1, VOID, VOID, VOID, VOID, VOID, ContentNegotiation$lambda$convertRequest$lambda));
|
|
553
553
|
} else {
|
|
554
554
|
tmp_15 = tmp2_elvis_lhs;
|
|
555
555
|
}
|
|
@@ -572,14 +572,14 @@
|
|
|
572
572
|
};
|
|
573
573
|
function $invoke$convertResponseCOROUTINE$(ignoredTypes, registrations, $this_createClientPlugin, requestUrl, info, body, responseContentType, charset, resultContinuation) {
|
|
574
574
|
CoroutineImpl.call(this, resultContinuation);
|
|
575
|
-
this.
|
|
576
|
-
this.
|
|
577
|
-
this.
|
|
578
|
-
this.
|
|
579
|
-
this.
|
|
580
|
-
this.
|
|
581
|
-
this.
|
|
582
|
-
this.
|
|
575
|
+
this.n5q_1 = ignoredTypes;
|
|
576
|
+
this.o5q_1 = registrations;
|
|
577
|
+
this.p5q_1 = $this_createClientPlugin;
|
|
578
|
+
this.q5q_1 = requestUrl;
|
|
579
|
+
this.r5q_1 = info;
|
|
580
|
+
this.s5q_1 = body;
|
|
581
|
+
this.t5q_1 = responseContentType;
|
|
582
|
+
this.u5q_1 = charset;
|
|
583
583
|
}
|
|
584
584
|
protoOf($invoke$convertResponseCOROUTINE$).l9 = function () {
|
|
585
585
|
var suspendResult = this.f9_1;
|
|
@@ -589,23 +589,23 @@
|
|
|
589
589
|
switch (tmp) {
|
|
590
590
|
case 0:
|
|
591
591
|
this.e9_1 = 2;
|
|
592
|
-
var tmp_0 = this.
|
|
592
|
+
var tmp_0 = this.s5q_1;
|
|
593
593
|
if (!isInterface(tmp_0, ByteReadChannel)) {
|
|
594
|
-
get_LOGGER().
|
|
594
|
+
get_LOGGER().d2v('Response body is already transformed. Skipping ContentNegotiation for ' + this.q5q_1.toString() + '.');
|
|
595
595
|
return null;
|
|
596
596
|
}
|
|
597
597
|
|
|
598
|
-
if (this.
|
|
599
|
-
get_LOGGER().
|
|
598
|
+
if (this.n5q_1.n2(this.r5q_1.m2u_1)) {
|
|
599
|
+
get_LOGGER().d2v('Response body type ' + toString(this.r5q_1.m2u_1) + ' is in ignored types. ' + ('Skipping ContentNegotiation for ' + this.q5q_1.toString() + '.'));
|
|
600
600
|
return null;
|
|
601
601
|
}
|
|
602
602
|
|
|
603
|
-
var tmp0 = this.
|
|
603
|
+
var tmp0 = this.o5q_1;
|
|
604
604
|
var destination = ArrayList_init_$Create$();
|
|
605
605
|
var _iterator__ex2g4s = tmp0.t();
|
|
606
606
|
while (_iterator__ex2g4s.u()) {
|
|
607
607
|
var element = _iterator__ex2g4s.v();
|
|
608
|
-
if (element.
|
|
608
|
+
if (element.f5p_1.h5p(this.t5q_1)) {
|
|
609
609
|
destination.j1(element);
|
|
610
610
|
}
|
|
611
611
|
}
|
|
@@ -614,7 +614,7 @@
|
|
|
614
614
|
var _iterator__ex2g4s_0 = destination.t();
|
|
615
615
|
while (_iterator__ex2g4s_0.u()) {
|
|
616
616
|
var item = _iterator__ex2g4s_0.v();
|
|
617
|
-
destination_0.j1(item.
|
|
617
|
+
destination_0.j1(item.d5p_1);
|
|
618
618
|
}
|
|
619
619
|
|
|
620
620
|
var tmp_1;
|
|
@@ -627,8 +627,8 @@
|
|
|
627
627
|
var tmp0_elvis_lhs = tmp_1;
|
|
628
628
|
var tmp_2;
|
|
629
629
|
if (tmp0_elvis_lhs == null) {
|
|
630
|
-
this.
|
|
631
|
-
get_LOGGER().
|
|
630
|
+
this.p5q_1;
|
|
631
|
+
get_LOGGER().d2v('None of the registered converters match response with Content-Type=' + this.t5q_1.toString() + '. ' + ('Skipping ContentNegotiation for ' + this.q5q_1.toString() + '.'));
|
|
632
632
|
return null;
|
|
633
633
|
} else {
|
|
634
634
|
tmp_2 = tmp0_elvis_lhs;
|
|
@@ -636,7 +636,7 @@
|
|
|
636
636
|
|
|
637
637
|
var suitableConverters = tmp_2;
|
|
638
638
|
this.d9_1 = 1;
|
|
639
|
-
suspendResult = deserialize(suitableConverters, this.
|
|
639
|
+
suspendResult = deserialize(suitableConverters, this.s5q_1, this.r5q_1, this.u5q_1, this);
|
|
640
640
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
641
641
|
return suspendResult;
|
|
642
642
|
}
|
|
@@ -645,7 +645,7 @@
|
|
|
645
645
|
case 1:
|
|
646
646
|
var result = suspendResult;
|
|
647
647
|
if (!isInterface(result, ByteReadChannel)) {
|
|
648
|
-
get_LOGGER().
|
|
648
|
+
get_LOGGER().d2v('Response body was converted to ' + toString(getKClassFromExpression(result)) + ' for ' + this.q5q_1.toString() + '.');
|
|
649
649
|
}
|
|
650
650
|
|
|
651
651
|
return result;
|
|
@@ -696,12 +696,12 @@
|
|
|
696
696
|
}
|
|
697
697
|
function JsonContentTypeMatcher() {
|
|
698
698
|
}
|
|
699
|
-
protoOf(JsonContentTypeMatcher).
|
|
700
|
-
if (contentType.
|
|
699
|
+
protoOf(JsonContentTypeMatcher).h5p = function (contentType) {
|
|
700
|
+
if (contentType.b2y(Application_getInstance().h2w_1)) {
|
|
701
701
|
return true;
|
|
702
702
|
}
|
|
703
|
-
var value = contentType.
|
|
704
|
-
return Application_getInstance().
|
|
703
|
+
var value = contentType.a2y().toString();
|
|
704
|
+
return Application_getInstance().b2x(value) && endsWith(value, '+json', true);
|
|
705
705
|
};
|
|
706
706
|
var JsonContentTypeMatcher_instance;
|
|
707
707
|
function JsonContentTypeMatcher_getInstance() {
|
|
@@ -721,7 +721,7 @@
|
|
|
721
721
|
}
|
|
722
722
|
}
|
|
723
723
|
//region block: post-declaration
|
|
724
|
-
protoOf(ContentNegotiationConfig).
|
|
724
|
+
protoOf(ContentNegotiationConfig).h3o = register$default;
|
|
725
725
|
//endregion
|
|
726
726
|
//region block: init
|
|
727
727
|
JsonContentTypeMatcher_instance = new JsonContentTypeMatcher();
|