@doordeck/doordeck-headless-sdk 0.204.0 → 0.205.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 +58 -58
- package/kotlin/Kermit-kermit.js +7 -7
- package/kotlin/MultiplatformSettings-multiplatform-settings.js +23 -23
- package/kotlin/doordeck-sdk.d.ts +21 -2
- package/kotlin/doordeck-sdk.js +12895 -12809
- package/kotlin/kotlin-kotlin-stdlib.js +1727 -1595
- package/kotlin/kotlinx-atomicfu.js +18 -18
- package/kotlin/kotlinx-coroutines-core.js +2087 -2109
- package/kotlin/kotlinx-io-kotlinx-io-bytestring.js +48 -48
- package/kotlin/kotlinx-io-kotlinx-io-core.js +476 -476
- package/kotlin/kotlinx-serialization-kotlinx-serialization-core.js +1917 -1916
- package/kotlin/kotlinx-serialization-kotlinx-serialization-json.js +1498 -1501
- package/kotlin/ktor-ktor-client-auth.js +284 -299
- package/kotlin/ktor-ktor-client-content-negotiation.js +160 -165
- package/kotlin/ktor-ktor-client-core.js +2380 -2491
- package/kotlin/ktor-ktor-client-logging.js +694 -719
- package/kotlin/ktor-ktor-events.js +12 -12
- package/kotlin/ktor-ktor-http-cio.js +381 -386
- package/kotlin/ktor-ktor-http.js +809 -808
- package/kotlin/ktor-ktor-io.js +702 -704
- package/kotlin/ktor-ktor-serialization-kotlinx-json.js +8 -8
- package/kotlin/ktor-ktor-serialization-kotlinx.js +166 -173
- package/kotlin/ktor-ktor-serialization.js +76 -79
- package/kotlin/ktor-ktor-utils.js +927 -947
- package/kotlin/ktor-ktor-websockets.js +447 -462
- package/package.json +1 -1
|
@@ -1,32 +1,33 @@
|
|
|
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.$_$.
|
|
4
|
+
var protoOf = kotlin_kotlin.$_$.hc;
|
|
5
|
+
var initMetadataForClass = kotlin_kotlin.$_$.kb;
|
|
6
6
|
var plus = kotlin_kotlin.$_$.x7;
|
|
7
7
|
var toMutableSet = kotlin_kotlin.$_$.t8;
|
|
8
|
-
var ArrayList_init_$Create$ = kotlin_kotlin.$_$.
|
|
8
|
+
var ArrayList_init_$Create$ = kotlin_kotlin.$_$.j3;
|
|
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.$_$.z2;
|
|
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.$_$.
|
|
14
|
+
var Exception = kotlin_kotlin.$_$.cg;
|
|
15
|
+
var Exception_init_$Init$ = kotlin_kotlin.$_$.i4;
|
|
16
16
|
var captureStack = kotlin_kotlin.$_$.sa;
|
|
17
|
-
var
|
|
18
|
-
var
|
|
17
|
+
var constructCallableReference = kotlin_kotlin.$_$.ab;
|
|
18
|
+
var toString = kotlin_kotlin.$_$.kc;
|
|
19
|
+
var Charsets_getInstance = kotlin_io_ktor_ktor_io.$_$.b;
|
|
19
20
|
var CoroutineImpl = kotlin_kotlin.$_$.s9;
|
|
20
|
-
var THROW_CCE = kotlin_kotlin.$_$.
|
|
21
|
+
var THROW_CCE = kotlin_kotlin.$_$.jg;
|
|
21
22
|
var TransformRequestBodyContext = kotlin_io_ktor_ktor_client_core.$_$.m;
|
|
22
23
|
var HttpRequestBuilder = kotlin_io_ktor_ktor_client_core.$_$.d1;
|
|
23
24
|
var TypeInfo = kotlin_io_ktor_ktor_utils.$_$.o;
|
|
24
25
|
var get_COROUTINE_SUSPENDED = kotlin_kotlin.$_$.b9;
|
|
25
|
-
var initMetadataForLambda = kotlin_kotlin.$_$.
|
|
26
|
+
var initMetadataForLambda = kotlin_kotlin.$_$.pb;
|
|
26
27
|
var TransformResponseBodyContext = kotlin_io_ktor_ktor_client_core.$_$.n;
|
|
27
28
|
var HttpResponse = kotlin_io_ktor_ktor_client_core.$_$.k1;
|
|
28
29
|
var ByteReadChannel = kotlin_io_ktor_ktor_io.$_$.n1;
|
|
29
|
-
var isInterface = kotlin_kotlin.$_$.
|
|
30
|
+
var isInterface = kotlin_kotlin.$_$.zb;
|
|
30
31
|
var contentType = kotlin_io_ktor_ktor_http.$_$.o1;
|
|
31
32
|
var get_request = kotlin_io_ktor_ktor_client_core.$_$.m1;
|
|
32
33
|
var suitableCharset = kotlin_io_ktor_ktor_serialization.$_$.f;
|
|
@@ -35,36 +36,36 @@
|
|
|
35
36
|
var Companion_getInstance = kotlin_io_ktor_ktor_http.$_$.c;
|
|
36
37
|
var accept = kotlin_io_ktor_ktor_client_core.$_$.f1;
|
|
37
38
|
var OutgoingContent = kotlin_io_ktor_ktor_http.$_$.v;
|
|
38
|
-
var getKClassFromExpression = kotlin_kotlin.$_$.
|
|
39
|
+
var getKClassFromExpression = kotlin_kotlin.$_$.zc;
|
|
39
40
|
var contentType_0 = kotlin_io_ktor_ktor_http.$_$.n1;
|
|
40
41
|
var EmptyContent_getInstance = kotlin_io_ktor_ktor_client_core.$_$.f;
|
|
41
|
-
var Unit = kotlin_kotlin.$_$.
|
|
42
|
+
var Unit = kotlin_kotlin.$_$.ug;
|
|
42
43
|
var charset = kotlin_io_ktor_ktor_http.$_$.l1;
|
|
43
|
-
var ensureNotNull = kotlin_kotlin.$_$.
|
|
44
|
+
var ensureNotNull = kotlin_kotlin.$_$.bh;
|
|
44
45
|
var NullBody_instance = kotlin_io_ktor_ktor_http.$_$.a;
|
|
45
|
-
var equals = kotlin_kotlin.$_$.
|
|
46
|
+
var equals = kotlin_kotlin.$_$.cb;
|
|
46
47
|
var joinToString = kotlin_kotlin.$_$.m7;
|
|
47
|
-
var initMetadataForCoroutine = kotlin_kotlin.$_$.
|
|
48
|
+
var initMetadataForCoroutine = kotlin_kotlin.$_$.mb;
|
|
48
49
|
var collectionSizeOrDefault = kotlin_kotlin.$_$.b6;
|
|
49
|
-
var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.
|
|
50
|
+
var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.i3;
|
|
50
51
|
var deserialize = kotlin_io_ktor_ktor_serialization.$_$.a;
|
|
51
52
|
var KtorSimpleLogger = kotlin_io_ktor_ktor_utils.$_$.j;
|
|
52
|
-
var PrimitiveClasses_getInstance = kotlin_kotlin.$_$.
|
|
53
|
+
var PrimitiveClasses_getInstance = kotlin_kotlin.$_$.n2;
|
|
53
54
|
var HttpStatusCode = kotlin_io_ktor_ktor_http.$_$.b1;
|
|
54
|
-
var getKClass = kotlin_kotlin.$_$.
|
|
55
|
+
var getKClass = kotlin_kotlin.$_$.ad;
|
|
55
56
|
var ClientSSESession = kotlin_io_ktor_ktor_client_core.$_$.r;
|
|
56
57
|
var ClientSSESessionWithDeserialization = kotlin_io_ktor_ktor_client_core.$_$.q;
|
|
57
58
|
var setOf = kotlin_kotlin.$_$.f8;
|
|
58
59
|
var KtList = kotlin_kotlin.$_$.n5;
|
|
59
60
|
var ContentType = kotlin_io_ktor_ktor_http.$_$.z;
|
|
60
|
-
var arrayOf = kotlin_kotlin.$_$.
|
|
61
|
-
var createKType = kotlin_kotlin.$_$.
|
|
62
|
-
var createInvariantKTypeProjection = kotlin_kotlin.$_$.
|
|
61
|
+
var arrayOf = kotlin_kotlin.$_$.xg;
|
|
62
|
+
var createKType = kotlin_kotlin.$_$.yc;
|
|
63
|
+
var createInvariantKTypeProjection = kotlin_kotlin.$_$.wc;
|
|
63
64
|
var AttributeKey = kotlin_io_ktor_ktor_utils.$_$.q;
|
|
64
65
|
var createClientPlugin = kotlin_io_ktor_ktor_client_core.$_$.o;
|
|
65
|
-
var endsWith = kotlin_kotlin.$_$.
|
|
66
|
-
var initMetadataForObject = kotlin_kotlin.$_$.
|
|
67
|
-
var LinkedHashSet_init_$Create$ = kotlin_kotlin.$_$.
|
|
66
|
+
var endsWith = kotlin_kotlin.$_$.sd;
|
|
67
|
+
var initMetadataForObject = kotlin_kotlin.$_$.qb;
|
|
68
|
+
var LinkedHashSet_init_$Create$ = kotlin_kotlin.$_$.u3;
|
|
68
69
|
//endregion
|
|
69
70
|
//region block: pre-declaration
|
|
70
71
|
initMetadataForClass(ConverterRegistration, 'ConverterRegistration');
|
|
@@ -98,58 +99,56 @@
|
|
|
98
99
|
}
|
|
99
100
|
var ContentNegotiation;
|
|
100
101
|
function ConverterRegistration(converter, contentTypeToSend, contentTypeMatcher) {
|
|
101
|
-
this.
|
|
102
|
-
this.
|
|
103
|
-
this.
|
|
102
|
+
this.n5o_1 = converter;
|
|
103
|
+
this.o5o_1 = contentTypeToSend;
|
|
104
|
+
this.p5o_1 = contentTypeMatcher;
|
|
104
105
|
}
|
|
105
106
|
function defaultMatcher($this, pattern) {
|
|
106
107
|
return new ContentNegotiationConfig$defaultMatcher$1(pattern);
|
|
107
108
|
}
|
|
108
109
|
function ContentNegotiationConfig$defaultMatcher$1($pattern) {
|
|
109
|
-
this.
|
|
110
|
+
this.q5o_1 = $pattern;
|
|
110
111
|
}
|
|
111
|
-
protoOf(ContentNegotiationConfig$defaultMatcher$1).
|
|
112
|
-
return contentType.
|
|
112
|
+
protoOf(ContentNegotiationConfig$defaultMatcher$1).r5o = function (contentType) {
|
|
113
|
+
return contentType.k2x(this.q5o_1);
|
|
113
114
|
};
|
|
114
115
|
function ContentNegotiationConfig() {
|
|
115
|
-
this.
|
|
116
|
+
this.s5o_1 = toMutableSet(plus(get_DefaultIgnoredTypes(), get_DefaultCommonIgnoredTypes()));
|
|
116
117
|
var tmp = this;
|
|
117
118
|
// Inline function 'kotlin.collections.mutableListOf' call
|
|
118
|
-
tmp.
|
|
119
|
-
this.
|
|
119
|
+
tmp.t5o_1 = ArrayList_init_$Create$();
|
|
120
|
+
this.u5o_1 = null;
|
|
120
121
|
}
|
|
121
|
-
protoOf(ContentNegotiationConfig).
|
|
122
|
-
var matcher = contentType.
|
|
123
|
-
this.
|
|
122
|
+
protoOf(ContentNegotiationConfig).q3n = function (contentType, converter, configuration) {
|
|
123
|
+
var matcher = contentType.k2x(Application_getInstance().q2v_1) ? JsonContentTypeMatcher_instance : defaultMatcher(this, contentType);
|
|
124
|
+
this.v5o(contentType, converter, matcher, configuration);
|
|
124
125
|
};
|
|
125
|
-
protoOf(ContentNegotiationConfig).
|
|
126
|
+
protoOf(ContentNegotiationConfig).v5o = function (contentTypeToSend, converter, contentTypeMatcher, configuration) {
|
|
126
127
|
// Inline function 'kotlin.apply' call
|
|
127
128
|
configuration(converter);
|
|
128
129
|
var registration = new ConverterRegistration(converter, contentTypeToSend, contentTypeMatcher);
|
|
129
|
-
this.
|
|
130
|
+
this.t5o_1.j1(registration);
|
|
130
131
|
};
|
|
131
132
|
function ContentConverterException(message) {
|
|
132
133
|
Exception_init_$Init$(message, this);
|
|
133
134
|
captureStack(this, ContentConverterException);
|
|
134
135
|
}
|
|
135
136
|
function ContentNegotiationConfig$_init_$ref_1ne3ob() {
|
|
136
|
-
|
|
137
|
+
return constructCallableReference(function () {
|
|
137
138
|
return new ContentNegotiationConfig();
|
|
138
|
-
};
|
|
139
|
-
l.callableName = '<init>';
|
|
140
|
-
return l;
|
|
139
|
+
}, 0, 0, 41, '<init>');
|
|
141
140
|
}
|
|
142
141
|
function ContentNegotiation$lambda($this$createClientPlugin) {
|
|
143
142
|
_init_properties_ContentNegotiation_kt__o183go();
|
|
144
|
-
var registrations = $this$createClientPlugin.
|
|
145
|
-
var ignoredTypes = $this$createClientPlugin.
|
|
146
|
-
$this$createClientPlugin.
|
|
147
|
-
$this$createClientPlugin.
|
|
143
|
+
var registrations = $this$createClientPlugin.u3z_1.t5o_1;
|
|
144
|
+
var ignoredTypes = $this$createClientPlugin.u3z_1.s5o_1;
|
|
145
|
+
$this$createClientPlugin.q4k(ContentNegotiation$lambda$slambda_0(registrations, $this$createClientPlugin, ignoredTypes, null));
|
|
146
|
+
$this$createClientPlugin.z48(ContentNegotiation$lambda$slambda_2(ignoredTypes, registrations, $this$createClientPlugin, null));
|
|
148
147
|
return Unit_instance;
|
|
149
148
|
}
|
|
150
149
|
function ContentNegotiation$lambda$convertRequest$lambda(it) {
|
|
151
150
|
_init_properties_ContentNegotiation_kt__o183go();
|
|
152
|
-
return toString(it.
|
|
151
|
+
return toString(it.n5o_1);
|
|
153
152
|
}
|
|
154
153
|
function invoke$convertRequest(registrations, $this_createClientPlugin, ignoredTypes, request, body, $completion) {
|
|
155
154
|
var tmp = new $invoke$convertRequestCOROUTINE$(registrations, $this_createClientPlugin, ignoredTypes, request, body, $completion);
|
|
@@ -158,29 +157,29 @@
|
|
|
158
157
|
return tmp.l9();
|
|
159
158
|
}
|
|
160
159
|
function invoke$convertResponse(ignoredTypes, registrations, $this_createClientPlugin, requestUrl, info, body, responseContentType, charset, $completion) {
|
|
161
|
-
charset = charset === VOID ? Charsets_getInstance().
|
|
160
|
+
charset = charset === VOID ? Charsets_getInstance().c1z_1 : charset;
|
|
162
161
|
var tmp = new $invoke$convertResponseCOROUTINE$(ignoredTypes, registrations, $this_createClientPlugin, requestUrl, info, body, responseContentType, charset, $completion);
|
|
163
162
|
tmp.f9_1 = Unit_instance;
|
|
164
163
|
tmp.g9_1 = null;
|
|
165
164
|
return tmp.l9();
|
|
166
165
|
}
|
|
167
166
|
function ContentNegotiation$lambda$slambda($registrations, $this_createClientPlugin, $ignoredTypes, resultContinuation) {
|
|
168
|
-
this.
|
|
169
|
-
this.
|
|
170
|
-
this.
|
|
167
|
+
this.n5q_1 = $registrations;
|
|
168
|
+
this.o5q_1 = $this_createClientPlugin;
|
|
169
|
+
this.p5q_1 = $ignoredTypes;
|
|
171
170
|
CoroutineImpl.call(this, resultContinuation);
|
|
172
171
|
}
|
|
173
|
-
protoOf(ContentNegotiation$lambda$slambda).
|
|
174
|
-
var tmp = this.
|
|
172
|
+
protoOf(ContentNegotiation$lambda$slambda).u5q = function ($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion) {
|
|
173
|
+
var tmp = this.v5q($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion);
|
|
175
174
|
tmp.f9_1 = Unit_instance;
|
|
176
175
|
tmp.g9_1 = null;
|
|
177
176
|
return tmp.l9();
|
|
178
177
|
};
|
|
179
|
-
protoOf(ContentNegotiation$lambda$slambda).
|
|
178
|
+
protoOf(ContentNegotiation$lambda$slambda).e4a = function (p1, p2, p3, p4, $completion) {
|
|
180
179
|
var tmp = p1 instanceof TransformRequestBodyContext ? p1 : THROW_CCE();
|
|
181
180
|
var tmp_0 = p2 instanceof HttpRequestBuilder ? p2 : THROW_CCE();
|
|
182
181
|
var tmp_1 = !(p3 == null) ? p3 : THROW_CCE();
|
|
183
|
-
return this.
|
|
182
|
+
return this.u5q(tmp, tmp_0, tmp_1, (p4 == null ? true : p4 instanceof TypeInfo) ? p4 : THROW_CCE(), $completion);
|
|
184
183
|
};
|
|
185
184
|
protoOf(ContentNegotiation$lambda$slambda).l9 = function () {
|
|
186
185
|
var suspendResult = this.f9_1;
|
|
@@ -191,7 +190,7 @@
|
|
|
191
190
|
case 0:
|
|
192
191
|
this.e9_1 = 2;
|
|
193
192
|
this.d9_1 = 1;
|
|
194
|
-
suspendResult = invoke$convertRequest(this.
|
|
193
|
+
suspendResult = invoke$convertRequest(this.n5q_1, this.o5q_1, this.p5q_1, this.r5q_1, this.s5q_1, this);
|
|
195
194
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
196
195
|
return suspendResult;
|
|
197
196
|
}
|
|
@@ -213,39 +212,37 @@
|
|
|
213
212
|
}
|
|
214
213
|
while (true);
|
|
215
214
|
};
|
|
216
|
-
protoOf(ContentNegotiation$lambda$slambda).
|
|
217
|
-
var i = new ContentNegotiation$lambda$slambda(this.
|
|
218
|
-
i.
|
|
219
|
-
i.
|
|
220
|
-
i.
|
|
221
|
-
i.
|
|
215
|
+
protoOf(ContentNegotiation$lambda$slambda).v5q = function ($this$transformRequestBody, request, body, _unused_var__etf5q3, completion) {
|
|
216
|
+
var i = new ContentNegotiation$lambda$slambda(this.n5q_1, this.o5q_1, this.p5q_1, completion);
|
|
217
|
+
i.q5q_1 = $this$transformRequestBody;
|
|
218
|
+
i.r5q_1 = request;
|
|
219
|
+
i.s5q_1 = body;
|
|
220
|
+
i.t5q_1 = _unused_var__etf5q3;
|
|
222
221
|
return i;
|
|
223
222
|
};
|
|
224
223
|
function ContentNegotiation$lambda$slambda_0($registrations, $this_createClientPlugin, $ignoredTypes, resultContinuation) {
|
|
225
224
|
var i = new ContentNegotiation$lambda$slambda($registrations, $this_createClientPlugin, $ignoredTypes, resultContinuation);
|
|
226
|
-
|
|
227
|
-
return i.
|
|
228
|
-
};
|
|
229
|
-
l.$arity = 4;
|
|
230
|
-
return l;
|
|
225
|
+
return constructCallableReference(function ($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion) {
|
|
226
|
+
return i.u5q($this$transformRequestBody, request, body, _unused_var__etf5q3, $completion);
|
|
227
|
+
}, 4);
|
|
231
228
|
}
|
|
232
229
|
function ContentNegotiation$lambda$slambda_1($ignoredTypes, $registrations, $this_createClientPlugin, resultContinuation) {
|
|
233
|
-
this.
|
|
234
|
-
this.
|
|
235
|
-
this.
|
|
230
|
+
this.e5r_1 = $ignoredTypes;
|
|
231
|
+
this.f5r_1 = $registrations;
|
|
232
|
+
this.g5r_1 = $this_createClientPlugin;
|
|
236
233
|
CoroutineImpl.call(this, resultContinuation);
|
|
237
234
|
}
|
|
238
|
-
protoOf(ContentNegotiation$lambda$slambda_1).
|
|
239
|
-
var tmp = this.
|
|
235
|
+
protoOf(ContentNegotiation$lambda$slambda_1).c4a = function ($this$transformResponseBody, response, body, info, $completion) {
|
|
236
|
+
var tmp = this.d4a($this$transformResponseBody, response, body, info, $completion);
|
|
240
237
|
tmp.f9_1 = Unit_instance;
|
|
241
238
|
tmp.g9_1 = null;
|
|
242
239
|
return tmp.l9();
|
|
243
240
|
};
|
|
244
|
-
protoOf(ContentNegotiation$lambda$slambda_1).
|
|
241
|
+
protoOf(ContentNegotiation$lambda$slambda_1).e4a = function (p1, p2, p3, p4, $completion) {
|
|
245
242
|
var tmp = p1 instanceof TransformResponseBodyContext ? p1 : THROW_CCE();
|
|
246
243
|
var tmp_0 = p2 instanceof HttpResponse ? p2 : THROW_CCE();
|
|
247
244
|
var tmp_1 = (!(p3 == null) ? isInterface(p3, ByteReadChannel) : false) ? p3 : THROW_CCE();
|
|
248
|
-
return this.
|
|
245
|
+
return this.c4a(tmp, tmp_0, tmp_1, p4 instanceof TypeInfo ? p4 : THROW_CCE(), $completion);
|
|
249
246
|
};
|
|
250
247
|
protoOf(ContentNegotiation$lambda$slambda_1).l9 = function () {
|
|
251
248
|
var suspendResult = this.f9_1;
|
|
@@ -255,7 +252,7 @@
|
|
|
255
252
|
switch (tmp) {
|
|
256
253
|
case 0:
|
|
257
254
|
this.e9_1 = 2;
|
|
258
|
-
var tmp0_elvis_lhs = contentType(this.
|
|
255
|
+
var tmp0_elvis_lhs = contentType(this.i5r_1);
|
|
259
256
|
var tmp_0;
|
|
260
257
|
if (tmp0_elvis_lhs == null) {
|
|
261
258
|
return null;
|
|
@@ -264,9 +261,9 @@
|
|
|
264
261
|
}
|
|
265
262
|
|
|
266
263
|
var contentType_0 = tmp_0;
|
|
267
|
-
var charset = suitableCharset(get_request(this.
|
|
264
|
+
var charset = suitableCharset(get_request(this.i5r_1).w31());
|
|
268
265
|
this.d9_1 = 1;
|
|
269
|
-
suspendResult = invoke$convertResponse(this.
|
|
266
|
+
suspendResult = invoke$convertResponse(this.e5r_1, this.f5r_1, this.g5r_1, get_request(this.i5r_1).l3t(), this.k5r_1, this.j5r_1, contentType_0, charset, this);
|
|
270
267
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
271
268
|
return suspendResult;
|
|
272
269
|
}
|
|
@@ -288,29 +285,27 @@
|
|
|
288
285
|
}
|
|
289
286
|
while (true);
|
|
290
287
|
};
|
|
291
|
-
protoOf(ContentNegotiation$lambda$slambda_1).
|
|
292
|
-
var i = new ContentNegotiation$lambda$slambda_1(this.
|
|
293
|
-
i.
|
|
294
|
-
i.
|
|
295
|
-
i.
|
|
296
|
-
i.
|
|
288
|
+
protoOf(ContentNegotiation$lambda$slambda_1).d4a = function ($this$transformResponseBody, response, body, info, completion) {
|
|
289
|
+
var i = new ContentNegotiation$lambda$slambda_1(this.e5r_1, this.f5r_1, this.g5r_1, completion);
|
|
290
|
+
i.h5r_1 = $this$transformResponseBody;
|
|
291
|
+
i.i5r_1 = response;
|
|
292
|
+
i.j5r_1 = body;
|
|
293
|
+
i.k5r_1 = info;
|
|
297
294
|
return i;
|
|
298
295
|
};
|
|
299
296
|
function ContentNegotiation$lambda$slambda_2($ignoredTypes, $registrations, $this_createClientPlugin, resultContinuation) {
|
|
300
297
|
var i = new ContentNegotiation$lambda$slambda_1($ignoredTypes, $registrations, $this_createClientPlugin, resultContinuation);
|
|
301
|
-
|
|
302
|
-
return i.
|
|
303
|
-
};
|
|
304
|
-
l.$arity = 4;
|
|
305
|
-
return l;
|
|
298
|
+
return constructCallableReference(function ($this$transformResponseBody, response, body, info, $completion) {
|
|
299
|
+
return i.c4a($this$transformResponseBody, response, body, info, $completion);
|
|
300
|
+
}, 4);
|
|
306
301
|
}
|
|
307
302
|
function $invoke$convertRequestCOROUTINE$(registrations, $this_createClientPlugin, ignoredTypes, request, body, resultContinuation) {
|
|
308
303
|
CoroutineImpl.call(this, resultContinuation);
|
|
309
|
-
this.
|
|
310
|
-
this.
|
|
311
|
-
this.
|
|
312
|
-
this.
|
|
313
|
-
this.
|
|
304
|
+
this.e5p_1 = registrations;
|
|
305
|
+
this.f5p_1 = $this_createClientPlugin;
|
|
306
|
+
this.g5p_1 = ignoredTypes;
|
|
307
|
+
this.h5p_1 = request;
|
|
308
|
+
this.i5p_1 = body;
|
|
314
309
|
}
|
|
315
310
|
protoOf($invoke$convertRequestCOROUTINE$).l9 = function () {
|
|
316
311
|
var suspendResult = this.f9_1;
|
|
@@ -321,9 +316,9 @@
|
|
|
321
316
|
case 0:
|
|
322
317
|
this.e9_1 = 7;
|
|
323
318
|
var tmp_0;
|
|
324
|
-
if (this.
|
|
325
|
-
var excluded = this.
|
|
326
|
-
var tmp0 = this.
|
|
319
|
+
if (this.h5p_1.z3r_1.b2l(get_ExcludedContentTypes())) {
|
|
320
|
+
var excluded = this.h5p_1.z3r_1.z2k(get_ExcludedContentTypes());
|
|
321
|
+
var tmp0 = this.e5p_1;
|
|
327
322
|
var destination = ArrayList_init_$Create$();
|
|
328
323
|
var _iterator__ex2g4s = tmp0.t();
|
|
329
324
|
while (_iterator__ex2g4s.u()) {
|
|
@@ -343,7 +338,7 @@
|
|
|
343
338
|
var _iterator__ex2g4s_0 = excluded.t();
|
|
344
339
|
while (_iterator__ex2g4s_0.u()) {
|
|
345
340
|
var element_0 = _iterator__ex2g4s_0.v();
|
|
346
|
-
if (element.
|
|
341
|
+
if (element.o5o_1.k2x(element_0)) {
|
|
347
342
|
tmp$ret$0 = false;
|
|
348
343
|
break l$ret$1;
|
|
349
344
|
}
|
|
@@ -357,11 +352,11 @@
|
|
|
357
352
|
}
|
|
358
353
|
tmp_0 = destination;
|
|
359
354
|
} else {
|
|
360
|
-
tmp_0 = this.
|
|
355
|
+
tmp_0 = this.e5p_1;
|
|
361
356
|
}
|
|
362
357
|
|
|
363
358
|
var requestRegistrations = tmp_0;
|
|
364
|
-
var tmp0_elvis_lhs = this.
|
|
359
|
+
var tmp0_elvis_lhs = this.h5p_1.w3r_1.q2p('Accept');
|
|
365
360
|
var acceptHeaders = tmp0_elvis_lhs == null ? emptyList() : tmp0_elvis_lhs;
|
|
366
361
|
var _iterator__ex2g4s_1 = requestRegistrations.t();
|
|
367
362
|
while (_iterator__ex2g4s_1.u()) {
|
|
@@ -381,7 +376,7 @@
|
|
|
381
376
|
var _iterator__ex2g4s_2 = acceptHeaders.t();
|
|
382
377
|
while (_iterator__ex2g4s_2.u()) {
|
|
383
378
|
var element_2 = _iterator__ex2g4s_2.v();
|
|
384
|
-
if (Companion_getInstance().
|
|
379
|
+
if (Companion_getInstance().ao(element_2).k2x(element_1.o5o_1)) {
|
|
385
380
|
tmp$ret$2 = false;
|
|
386
381
|
break l$ret$3;
|
|
387
382
|
}
|
|
@@ -390,19 +385,19 @@
|
|
|
390
385
|
}
|
|
391
386
|
while (false);
|
|
392
387
|
if (tmp$ret$2) {
|
|
393
|
-
var qValue = this.
|
|
394
|
-
var contentTypeToSend = qValue == null ? element_1.
|
|
395
|
-
get_LOGGER().
|
|
396
|
-
accept(this.
|
|
388
|
+
var qValue = this.f5p_1.u3z_1.u5o_1;
|
|
389
|
+
var contentTypeToSend = qValue == null ? element_1.o5o_1 : element_1.o5o_1.i2x('q', qValue.toString());
|
|
390
|
+
get_LOGGER().m2u('Adding Accept=' + contentTypeToSend.toString() + ' header for ' + this.h5p_1.u3r_1.toString());
|
|
391
|
+
accept(this.h5p_1, contentTypeToSend);
|
|
397
392
|
}
|
|
398
393
|
}
|
|
399
394
|
|
|
400
395
|
var tmp_3;
|
|
401
|
-
var tmp_4 = this.
|
|
396
|
+
var tmp_4 = this.i5p_1;
|
|
402
397
|
if (tmp_4 instanceof OutgoingContent) {
|
|
403
398
|
tmp_3 = true;
|
|
404
399
|
} else {
|
|
405
|
-
var tmp0_0 = this.
|
|
400
|
+
var tmp0_0 = this.g5p_1;
|
|
406
401
|
var tmp$ret$4;
|
|
407
402
|
l$ret$5: do {
|
|
408
403
|
var tmp_5;
|
|
@@ -418,7 +413,7 @@
|
|
|
418
413
|
var _iterator__ex2g4s_3 = tmp0_0.t();
|
|
419
414
|
while (_iterator__ex2g4s_3.u()) {
|
|
420
415
|
var element_3 = _iterator__ex2g4s_3.v();
|
|
421
|
-
if (element_3.eb(this.
|
|
416
|
+
if (element_3.eb(this.i5p_1)) {
|
|
422
417
|
tmp$ret$4 = true;
|
|
423
418
|
break l$ret$5;
|
|
424
419
|
}
|
|
@@ -430,36 +425,36 @@
|
|
|
430
425
|
}
|
|
431
426
|
|
|
432
427
|
if (tmp_3) {
|
|
433
|
-
get_LOGGER().
|
|
428
|
+
get_LOGGER().m2u('Body type ' + toString(getKClassFromExpression(this.i5p_1)) + ' is in ignored types. ' + ('Skipping ContentNegotiation for ' + this.h5p_1.u3r_1.toString() + '.'));
|
|
434
429
|
return null;
|
|
435
430
|
}
|
|
436
431
|
|
|
437
432
|
var tmp_6 = this;
|
|
438
|
-
var tmp0_elvis_lhs_0 = contentType_0(this.
|
|
433
|
+
var tmp0_elvis_lhs_0 = contentType_0(this.h5p_1);
|
|
439
434
|
var tmp_7;
|
|
440
435
|
if (tmp0_elvis_lhs_0 == null) {
|
|
441
|
-
this.
|
|
442
|
-
get_LOGGER().
|
|
436
|
+
this.f5p_1;
|
|
437
|
+
get_LOGGER().m2u("Request doesn't have Content-Type header. Skipping ContentNegotiation for " + this.h5p_1.u3r_1.toString() + '.');
|
|
443
438
|
return null;
|
|
444
439
|
} else {
|
|
445
440
|
tmp_7 = tmp0_elvis_lhs_0;
|
|
446
441
|
}
|
|
447
442
|
|
|
448
|
-
tmp_6.
|
|
449
|
-
var tmp_8 = this.
|
|
443
|
+
tmp_6.k5p_1 = tmp_7;
|
|
444
|
+
var tmp_8 = this.i5p_1;
|
|
450
445
|
if (tmp_8 instanceof Unit) {
|
|
451
|
-
get_LOGGER().
|
|
452
|
-
this.
|
|
446
|
+
get_LOGGER().m2u('Sending empty body for ' + this.h5p_1.u3r_1.toString());
|
|
447
|
+
this.h5p_1.w3r_1.a2q('Content-Type');
|
|
453
448
|
return EmptyContent_getInstance();
|
|
454
449
|
}
|
|
455
450
|
|
|
456
451
|
var tmp_9 = this;
|
|
457
|
-
var tmp0_1 = this.
|
|
452
|
+
var tmp0_1 = this.e5p_1;
|
|
458
453
|
var destination_0 = ArrayList_init_$Create$();
|
|
459
454
|
var _iterator__ex2g4s_4 = tmp0_1.t();
|
|
460
455
|
while (_iterator__ex2g4s_4.u()) {
|
|
461
456
|
var element_4 = _iterator__ex2g4s_4.v();
|
|
462
|
-
if (element_4.
|
|
457
|
+
if (element_4.p5o_1.r5o(this.k5p_1)) {
|
|
463
458
|
destination_0.j1(element_4);
|
|
464
459
|
}
|
|
465
460
|
}
|
|
@@ -474,40 +469,40 @@
|
|
|
474
469
|
var tmp1_elvis_lhs = tmp_10;
|
|
475
470
|
var tmp_11;
|
|
476
471
|
if (tmp1_elvis_lhs == null) {
|
|
477
|
-
this.
|
|
478
|
-
get_LOGGER().
|
|
472
|
+
this.f5p_1;
|
|
473
|
+
get_LOGGER().m2u('None of the registered converters match request Content-Type=' + this.k5p_1.toString() + '. ' + ('Skipping ContentNegotiation for ' + this.h5p_1.u3r_1.toString() + '.'));
|
|
479
474
|
return null;
|
|
480
475
|
} else {
|
|
481
476
|
tmp_11 = tmp1_elvis_lhs;
|
|
482
477
|
}
|
|
483
478
|
|
|
484
|
-
tmp_9.
|
|
485
|
-
if (this.
|
|
486
|
-
get_LOGGER().
|
|
479
|
+
tmp_9.j5p_1 = tmp_11;
|
|
480
|
+
if (this.h5p_1.y4m() == null) {
|
|
481
|
+
get_LOGGER().m2u('Request has unknown body type. Skipping ContentNegotiation for ' + this.h5p_1.u3r_1.toString() + '.');
|
|
487
482
|
return null;
|
|
488
483
|
}
|
|
489
484
|
|
|
490
|
-
this.
|
|
491
|
-
this.
|
|
485
|
+
this.h5p_1.w3r_1.a2q('Content-Type');
|
|
486
|
+
this.o5p_1 = this.j5p_1;
|
|
492
487
|
this.d9_1 = 1;
|
|
493
488
|
continue $sm;
|
|
494
489
|
case 1:
|
|
495
|
-
this.
|
|
490
|
+
this.n5p_1 = this.o5p_1.t();
|
|
496
491
|
this.d9_1 = 2;
|
|
497
492
|
continue $sm;
|
|
498
493
|
case 2:
|
|
499
|
-
if (!this.
|
|
494
|
+
if (!this.n5p_1.u()) {
|
|
500
495
|
this.d9_1 = 5;
|
|
501
496
|
continue $sm;
|
|
502
497
|
}
|
|
503
498
|
|
|
504
|
-
var element_5 = this.
|
|
505
|
-
this.
|
|
499
|
+
var element_5 = this.n5p_1.v();
|
|
500
|
+
this.m5p_1 = element_5;
|
|
506
501
|
this.d9_1 = 3;
|
|
507
|
-
var tmp0_elvis_lhs_1 = charset(this.
|
|
508
|
-
var tmp_12 = tmp0_elvis_lhs_1 == null ? Charsets_getInstance().
|
|
509
|
-
var tmp_13 = ensureNotNull(this.
|
|
510
|
-
var this_0 = this.
|
|
502
|
+
var tmp0_elvis_lhs_1 = charset(this.k5p_1);
|
|
503
|
+
var tmp_12 = tmp0_elvis_lhs_1 == null ? Charsets_getInstance().c1z_1 : tmp0_elvis_lhs_1;
|
|
504
|
+
var tmp_13 = ensureNotNull(this.h5p_1.y4m());
|
|
505
|
+
var this_0 = this.i5p_1;
|
|
511
506
|
var tmp_14;
|
|
512
507
|
if (!equals(this_0, NullBody_instance)) {
|
|
513
508
|
tmp_14 = this_0;
|
|
@@ -515,7 +510,7 @@
|
|
|
515
510
|
tmp_14 = null;
|
|
516
511
|
}
|
|
517
512
|
|
|
518
|
-
suspendResult = this.
|
|
513
|
+
suspendResult = this.m5p_1.n5o_1.l5r(this.k5p_1, tmp_12, tmp_13, tmp_14, this);
|
|
519
514
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
520
515
|
return suspendResult;
|
|
521
516
|
}
|
|
@@ -524,12 +519,12 @@
|
|
|
524
519
|
case 3:
|
|
525
520
|
var result = suspendResult;
|
|
526
521
|
if (!(result == null)) {
|
|
527
|
-
get_LOGGER().
|
|
522
|
+
get_LOGGER().m2u('Converted request body using ' + toString(this.m5p_1.n5o_1) + ' for ' + this.h5p_1.u3r_1.toString());
|
|
528
523
|
}
|
|
529
524
|
|
|
530
525
|
var result_0 = result;
|
|
531
526
|
if (!(result_0 == null)) {
|
|
532
|
-
this.
|
|
527
|
+
this.l5p_1 = result_0;
|
|
533
528
|
this.d9_1 = 6;
|
|
534
529
|
continue $sm;
|
|
535
530
|
} else {
|
|
@@ -541,7 +536,7 @@
|
|
|
541
536
|
this.d9_1 = 2;
|
|
542
537
|
continue $sm;
|
|
543
538
|
case 5:
|
|
544
|
-
this.
|
|
539
|
+
this.l5p_1 = null;
|
|
545
540
|
if (false) {
|
|
546
541
|
this.d9_1 = 1;
|
|
547
542
|
continue $sm;
|
|
@@ -550,11 +545,11 @@
|
|
|
550
545
|
this.d9_1 = 6;
|
|
551
546
|
continue $sm;
|
|
552
547
|
case 6:
|
|
553
|
-
var tmp2_elvis_lhs = this.
|
|
548
|
+
var tmp2_elvis_lhs = this.l5p_1;
|
|
554
549
|
var tmp_15;
|
|
555
550
|
if (tmp2_elvis_lhs == null) {
|
|
556
|
-
var tmp_16 = "Can't convert " + toString(this.
|
|
557
|
-
throw new ContentConverterException(tmp_16 + joinToString(this.
|
|
551
|
+
var tmp_16 = "Can't convert " + toString(this.i5p_1) + ' with contentType ' + this.k5p_1.toString() + ' using converters ';
|
|
552
|
+
throw new ContentConverterException(tmp_16 + joinToString(this.j5p_1, VOID, VOID, VOID, VOID, VOID, ContentNegotiation$lambda$convertRequest$lambda));
|
|
558
553
|
} else {
|
|
559
554
|
tmp_15 = tmp2_elvis_lhs;
|
|
560
555
|
}
|
|
@@ -577,14 +572,14 @@
|
|
|
577
572
|
};
|
|
578
573
|
function $invoke$convertResponseCOROUTINE$(ignoredTypes, registrations, $this_createClientPlugin, requestUrl, info, body, responseContentType, charset, resultContinuation) {
|
|
579
574
|
CoroutineImpl.call(this, resultContinuation);
|
|
580
|
-
this.
|
|
581
|
-
this.
|
|
582
|
-
this.
|
|
583
|
-
this.
|
|
584
|
-
this.
|
|
585
|
-
this.
|
|
586
|
-
this.
|
|
587
|
-
this.
|
|
575
|
+
this.x5p_1 = ignoredTypes;
|
|
576
|
+
this.y5p_1 = registrations;
|
|
577
|
+
this.z5p_1 = $this_createClientPlugin;
|
|
578
|
+
this.a5q_1 = requestUrl;
|
|
579
|
+
this.b5q_1 = info;
|
|
580
|
+
this.c5q_1 = body;
|
|
581
|
+
this.d5q_1 = responseContentType;
|
|
582
|
+
this.e5q_1 = charset;
|
|
588
583
|
}
|
|
589
584
|
protoOf($invoke$convertResponseCOROUTINE$).l9 = function () {
|
|
590
585
|
var suspendResult = this.f9_1;
|
|
@@ -594,23 +589,23 @@
|
|
|
594
589
|
switch (tmp) {
|
|
595
590
|
case 0:
|
|
596
591
|
this.e9_1 = 2;
|
|
597
|
-
var tmp_0 = this.
|
|
592
|
+
var tmp_0 = this.c5q_1;
|
|
598
593
|
if (!isInterface(tmp_0, ByteReadChannel)) {
|
|
599
|
-
get_LOGGER().
|
|
594
|
+
get_LOGGER().m2u('Response body is already transformed. Skipping ContentNegotiation for ' + this.a5q_1.toString() + '.');
|
|
600
595
|
return null;
|
|
601
596
|
}
|
|
602
597
|
|
|
603
|
-
if (this.
|
|
604
|
-
get_LOGGER().
|
|
598
|
+
if (this.x5p_1.n2(this.b5q_1.v2t_1)) {
|
|
599
|
+
get_LOGGER().m2u('Response body type ' + toString(this.b5q_1.v2t_1) + ' is in ignored types. ' + ('Skipping ContentNegotiation for ' + this.a5q_1.toString() + '.'));
|
|
605
600
|
return null;
|
|
606
601
|
}
|
|
607
602
|
|
|
608
|
-
var tmp0 = this.
|
|
603
|
+
var tmp0 = this.y5p_1;
|
|
609
604
|
var destination = ArrayList_init_$Create$();
|
|
610
605
|
var _iterator__ex2g4s = tmp0.t();
|
|
611
606
|
while (_iterator__ex2g4s.u()) {
|
|
612
607
|
var element = _iterator__ex2g4s.v();
|
|
613
|
-
if (element.
|
|
608
|
+
if (element.p5o_1.r5o(this.d5q_1)) {
|
|
614
609
|
destination.j1(element);
|
|
615
610
|
}
|
|
616
611
|
}
|
|
@@ -619,7 +614,7 @@
|
|
|
619
614
|
var _iterator__ex2g4s_0 = destination.t();
|
|
620
615
|
while (_iterator__ex2g4s_0.u()) {
|
|
621
616
|
var item = _iterator__ex2g4s_0.v();
|
|
622
|
-
destination_0.j1(item.
|
|
617
|
+
destination_0.j1(item.n5o_1);
|
|
623
618
|
}
|
|
624
619
|
|
|
625
620
|
var tmp_1;
|
|
@@ -632,8 +627,8 @@
|
|
|
632
627
|
var tmp0_elvis_lhs = tmp_1;
|
|
633
628
|
var tmp_2;
|
|
634
629
|
if (tmp0_elvis_lhs == null) {
|
|
635
|
-
this.
|
|
636
|
-
get_LOGGER().
|
|
630
|
+
this.z5p_1;
|
|
631
|
+
get_LOGGER().m2u('None of the registered converters match response with Content-Type=' + this.d5q_1.toString() + '. ' + ('Skipping ContentNegotiation for ' + this.a5q_1.toString() + '.'));
|
|
637
632
|
return null;
|
|
638
633
|
} else {
|
|
639
634
|
tmp_2 = tmp0_elvis_lhs;
|
|
@@ -641,7 +636,7 @@
|
|
|
641
636
|
|
|
642
637
|
var suitableConverters = tmp_2;
|
|
643
638
|
this.d9_1 = 1;
|
|
644
|
-
suspendResult = deserialize(suitableConverters, this.
|
|
639
|
+
suspendResult = deserialize(suitableConverters, this.c5q_1, this.b5q_1, this.e5q_1, this);
|
|
645
640
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
646
641
|
return suspendResult;
|
|
647
642
|
}
|
|
@@ -650,7 +645,7 @@
|
|
|
650
645
|
case 1:
|
|
651
646
|
var result = suspendResult;
|
|
652
647
|
if (!isInterface(result, ByteReadChannel)) {
|
|
653
|
-
get_LOGGER().
|
|
648
|
+
get_LOGGER().m2u('Response body was converted to ' + toString(getKClassFromExpression(result)) + ' for ' + this.a5q_1.toString() + '.');
|
|
654
649
|
}
|
|
655
650
|
|
|
656
651
|
return result;
|
|
@@ -673,7 +668,7 @@
|
|
|
673
668
|
if (!properties_initialized_ContentNegotiation_kt_1ayduy) {
|
|
674
669
|
properties_initialized_ContentNegotiation_kt_1ayduy = true;
|
|
675
670
|
LOGGER = KtorSimpleLogger('io.ktor.client.plugins.contentnegotiation.ContentNegotiation');
|
|
676
|
-
DefaultCommonIgnoredTypes = setOf([PrimitiveClasses_getInstance().
|
|
671
|
+
DefaultCommonIgnoredTypes = setOf([PrimitiveClasses_getInstance().lc(), PrimitiveClasses_getInstance().hc(), getKClass(HttpStatusCode), getKClass(ByteReadChannel), getKClass(OutgoingContent), getKClass(ClientSSESession), getKClass(ClientSSESessionWithDeserialization)]);
|
|
677
672
|
// Inline function 'io.ktor.util.AttributeKey' call
|
|
678
673
|
var name = 'ExcludedContentTypesAttr';
|
|
679
674
|
// Inline function 'io.ktor.util.reflect.typeInfo' call
|
|
@@ -701,12 +696,12 @@
|
|
|
701
696
|
}
|
|
702
697
|
function JsonContentTypeMatcher() {
|
|
703
698
|
}
|
|
704
|
-
protoOf(JsonContentTypeMatcher).
|
|
705
|
-
if (contentType.
|
|
699
|
+
protoOf(JsonContentTypeMatcher).r5o = function (contentType) {
|
|
700
|
+
if (contentType.k2x(Application_getInstance().q2v_1)) {
|
|
706
701
|
return true;
|
|
707
702
|
}
|
|
708
|
-
var value = contentType.
|
|
709
|
-
return Application_getInstance().
|
|
703
|
+
var value = contentType.j2x().toString();
|
|
704
|
+
return Application_getInstance().k2w(value) && endsWith(value, '+json', true);
|
|
710
705
|
};
|
|
711
706
|
var JsonContentTypeMatcher_instance;
|
|
712
707
|
function JsonContentTypeMatcher_getInstance() {
|
|
@@ -726,7 +721,7 @@
|
|
|
726
721
|
}
|
|
727
722
|
}
|
|
728
723
|
//region block: post-declaration
|
|
729
|
-
protoOf(ContentNegotiationConfig).
|
|
724
|
+
protoOf(ContentNegotiationConfig).r3n = register$default;
|
|
730
725
|
//endregion
|
|
731
726
|
//region block: init
|
|
732
727
|
JsonContentTypeMatcher_instance = new JsonContentTypeMatcher();
|