@xiuper/mpp-core 0.0.2
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-DateTime-library-kotlinx-datetime.js +7836 -0
- package/Kotlin-DateTime-library-kotlinx-datetime.js.map +1 -0
- package/Kotlin-Immutable-Collections-kotlinx-collections-immutable.js +1241 -0
- package/Kotlin-Immutable-Collections-kotlinx-collections-immutable.js.map +1 -0
- package/Xiuper-mpp-codegraph.js +1471 -0
- package/Xiuper-mpp-codegraph.js.map +1 -0
- package/annotations.js +15 -0
- package/annotations.js.map +1 -0
- package/autodev-mpp-core.d.ts +1312 -0
- package/autodev-mpp-core.js +86483 -0
- package/autodev-mpp-core.js.map +1 -0
- package/kaml.js +3387 -0
- package/kaml.js.map +1 -0
- package/koog-agents-agents-core.js +22927 -0
- package/koog-agents-agents-core.js.map +1 -0
- package/koog-agents-agents-ext.js +15 -0
- package/koog-agents-agents-ext.js.map +1 -0
- package/koog-agents-agents-features-agents-features-event-handler.js +15 -0
- package/koog-agents-agents-features-agents-features-event-handler.js.map +1 -0
- package/koog-agents-agents-features-agents-features-memory.js +15 -0
- package/koog-agents-agents-features-agents-features-memory.js.map +1 -0
- package/koog-agents-agents-features-agents-features-opentelemetry.js +15 -0
- package/koog-agents-agents-features-agents-features-opentelemetry.js.map +1 -0
- package/koog-agents-agents-features-agents-features-snapshot.js +15 -0
- package/koog-agents-agents-features-agents-features-snapshot.js.map +1 -0
- package/koog-agents-agents-features-agents-features-tokenizer.js +15 -0
- package/koog-agents-agents-features-agents-features-tokenizer.js.map +1 -0
- package/koog-agents-agents-features-agents-features-trace.js +15 -0
- package/koog-agents-agents-features-agents-features-trace.js.map +1 -0
- package/koog-agents-agents-mcp.js +15 -0
- package/koog-agents-agents-mcp.js.map +1 -0
- package/koog-agents-agents-tools.js +322 -0
- package/koog-agents-agents-tools.js.map +1 -0
- package/koog-agents-agents-utils.js +232 -0
- package/koog-agents-agents-utils.js.map +1 -0
- package/koog-embeddings-embeddings-base.js +15 -0
- package/koog-embeddings-embeddings-base.js.map +1 -0
- package/koog-embeddings-embeddings-llm.js +15 -0
- package/koog-embeddings-embeddings-llm.js.map +1 -0
- package/koog-http-client-http-client-core.js +57 -0
- package/koog-http-client-http-client-core.js.map +1 -0
- package/koog-http-client-http-client-ktor.js +703 -0
- package/koog-http-client-http-client-ktor.js.map +1 -0
- package/koog-koog-agents.js +15 -0
- package/koog-koog-agents.js.map +1 -0
- package/koog-prompt-prompt-cache-prompt-cache-files.js +15 -0
- package/koog-prompt-prompt-cache-prompt-cache-files.js.map +1 -0
- package/koog-prompt-prompt-cache-prompt-cache-model.js +15 -0
- package/koog-prompt-prompt-cache-prompt-cache-model.js.map +1 -0
- package/koog-prompt-prompt-cache-prompt-cache-redis.js +15 -0
- package/koog-prompt-prompt-cache-prompt-cache-redis.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-cached.js +15 -0
- package/koog-prompt-prompt-executor-prompt-executor-cached.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-anthropic-client.js +4991 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-anthropic-client.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-bedrock-client.js +15 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-bedrock-client.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-dashscope-client.js +15 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-dashscope-client.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-deepseek-client.js +1249 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-deepseek-client.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-google-client.js +4675 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-google-client.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-mistralai-client.js +15 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-mistralai-client.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-ollama-client.js +2343 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-ollama-client.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-openai-client-base.js +6613 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-openai-client-base.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-openai-client.js +19901 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-openai-client.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-openrouter-client.js +2313 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients-prompt-executor-openrouter-client.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients.js +222 -0
- package/koog-prompt-prompt-executor-prompt-executor-clients.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-llms-all.js +70 -0
- package/koog-prompt-prompt-executor-prompt-executor-llms-all.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-llms.js +134 -0
- package/koog-prompt-prompt-executor-prompt-executor-llms.js.map +1 -0
- package/koog-prompt-prompt-executor-prompt-executor-model.js +42 -0
- package/koog-prompt-prompt-executor-prompt-executor-model.js.map +1 -0
- package/koog-prompt-prompt-llm.js +1710 -0
- package/koog-prompt-prompt-llm.js.map +1 -0
- package/koog-prompt-prompt-markdown.js +122 -0
- package/koog-prompt-prompt-markdown.js.map +1 -0
- package/koog-prompt-prompt-model.js +5848 -0
- package/koog-prompt-prompt-model.js.map +1 -0
- package/koog-prompt-prompt-structure.js +1513 -0
- package/koog-prompt-prompt-structure.js.map +1 -0
- package/koog-prompt-prompt-tokenizer.js +15 -0
- package/koog-prompt-prompt-tokenizer.js.map +1 -0
- package/koog-prompt-prompt-xml.js +15 -0
- package/koog-prompt-prompt-xml.js.map +1 -0
- package/koog-rag-rag-base.js +15 -0
- package/koog-rag-rag-base.js.map +1 -0
- package/koog-rag-vector-storage.js +15 -0
- package/koog-rag-vector-storage.js.map +1 -0
- package/koog-utils.js +63 -0
- package/koog-utils.js.map +1 -0
- package/kotlin-kotlin-stdlib.js +18965 -0
- package/kotlin-kotlin-stdlib.js.map +1 -0
- package/kotlin-logging.js +509 -0
- package/kotlin-logging.js.map +1 -0
- package/kotlin-sdk-kotlin-sdk-client.js +1340 -0
- package/kotlin-sdk-kotlin-sdk-client.js.map +1 -0
- package/kotlin-sdk-kotlin-sdk-core.js +15195 -0
- package/kotlin-sdk-kotlin-sdk-core.js.map +1 -0
- package/kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.js +15 -0
- package/kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.js.map +1 -0
- package/kotlinx-atomicfu.js +259 -0
- package/kotlinx-atomicfu.js.map +1 -0
- package/kotlinx-coroutines-core.js +13742 -0
- package/kotlinx-coroutines-core.js.map +1 -0
- package/kotlinx-io-kotlinx-io-bytestring.js +214 -0
- package/kotlinx-io-kotlinx-io-bytestring.js.map +1 -0
- package/kotlinx-io-kotlinx-io-core.js +2892 -0
- package/kotlinx-io-kotlinx-io-core.js.map +1 -0
- package/kotlinx-serialization-kotlinx-serialization-core.js +6563 -0
- package/kotlinx-serialization-kotlinx-serialization-core.js.map +1 -0
- package/kotlinx-serialization-kotlinx-serialization-json-io.js +15 -0
- package/kotlinx-serialization-kotlinx-serialization-json-io.js.map +1 -0
- package/kotlinx-serialization-kotlinx-serialization-json.js +5927 -0
- package/kotlinx-serialization-kotlinx-serialization-json.js.map +1 -0
- package/ktor-ktor-client-content-negotiation.js +775 -0
- package/ktor-ktor-client-content-negotiation.js.map +1 -0
- package/ktor-ktor-client-core.js +11110 -0
- package/ktor-ktor-client-core.js.map +1 -0
- package/ktor-ktor-client-logging.js +15 -0
- package/ktor-ktor-client-logging.js.map +1 -0
- package/ktor-ktor-events.js +126 -0
- package/ktor-ktor-events.js.map +1 -0
- package/ktor-ktor-http-cio.js +4257 -0
- package/ktor-ktor-http-cio.js.map +1 -0
- package/ktor-ktor-http.js +3671 -0
- package/ktor-ktor-http.js.map +1 -0
- package/ktor-ktor-io.js +4114 -0
- package/ktor-ktor-io.js.map +1 -0
- package/ktor-ktor-network.js +1399 -0
- package/ktor-ktor-network.js.map +1 -0
- package/ktor-ktor-serialization-kotlinx-json.js +67 -0
- package/ktor-ktor-serialization-kotlinx-json.js.map +1 -0
- package/ktor-ktor-serialization-kotlinx.js +881 -0
- package/ktor-ktor-serialization-kotlinx.js.map +1 -0
- package/ktor-ktor-serialization.js +388 -0
- package/ktor-ktor-serialization.js.map +1 -0
- package/ktor-ktor-server-cio.js +3735 -0
- package/ktor-ktor-server-cio.js.map +1 -0
- package/ktor-ktor-server-core.js +8696 -0
- package/ktor-ktor-server-core.js.map +1 -0
- package/ktor-ktor-server-sse.js +668 -0
- package/ktor-ktor-server-sse.js.map +1 -0
- package/ktor-ktor-server-websockets.js +15 -0
- package/ktor-ktor-server-websockets.js.map +1 -0
- package/ktor-ktor-sse.js +161 -0
- package/ktor-ktor-sse.js.map +1 -0
- package/ktor-ktor-utils.js +3589 -0
- package/ktor-ktor-utils.js.map +1 -0
- package/ktor-ktor-websocket-serialization.js +15 -0
- package/ktor-ktor-websocket-serialization.js.map +1 -0
- package/ktor-ktor-websockets.js +450 -0
- package/ktor-ktor-websockets.js.map +1 -0
- package/markdown.js +5174 -0
- package/markdown.js.map +1 -0
- package/okio-parent-okio.js +2628 -0
- package/okio-parent-okio.js.map +1 -0
- package/package.json +18 -0
- package/snakeyaml-engine-kmp.js +7079 -0
- package/snakeyaml-engine-kmp.js.map +1 -0
- package/urlencoder-urlencoder-lib.js +322 -0
- package/urlencoder-urlencoder-lib.js.map +1 -0
- package/xiuper-mpp-core.d.ts +1312 -0
- package/xiuper-mpp-core.js +86483 -0
- package/xiuper-mpp-core.js.map +1 -0
|
@@ -0,0 +1,4257 @@
|
|
|
1
|
+
(function (factory) {
|
|
2
|
+
if (typeof define === 'function' && define.amd)
|
|
3
|
+
define(['exports', './kotlin-kotlin-stdlib.js', './ktor-ktor-utils.js', './kotlinx-coroutines-core.js', './ktor-ktor-http.js', './ktor-ktor-io.js', './kotlinx-io-kotlinx-io-core.js', './kotlinx-io-kotlinx-io-bytestring.js'], factory);
|
|
4
|
+
else if (typeof exports === 'object')
|
|
5
|
+
factory(module.exports, require('./kotlin-kotlin-stdlib.js'), require('./ktor-ktor-utils.js'), require('./kotlinx-coroutines-core.js'), require('./ktor-ktor-http.js'), require('./ktor-ktor-io.js'), require('./kotlinx-io-kotlinx-io-core.js'), require('./kotlinx-io-kotlinx-io-bytestring.js'));
|
|
6
|
+
else {
|
|
7
|
+
if (typeof globalThis['kotlin-kotlin-stdlib'] === 'undefined') {
|
|
8
|
+
throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'kotlin-kotlin-stdlib' was not found. Please, check whether 'kotlin-kotlin-stdlib' is loaded prior to 'ktor-ktor-http-cio'.");
|
|
9
|
+
}
|
|
10
|
+
if (typeof globalThis['ktor-ktor-utils'] === 'undefined') {
|
|
11
|
+
throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'ktor-ktor-utils' was not found. Please, check whether 'ktor-ktor-utils' is loaded prior to 'ktor-ktor-http-cio'.");
|
|
12
|
+
}
|
|
13
|
+
if (typeof globalThis['kotlinx-coroutines-core'] === 'undefined') {
|
|
14
|
+
throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'kotlinx-coroutines-core' was not found. Please, check whether 'kotlinx-coroutines-core' is loaded prior to 'ktor-ktor-http-cio'.");
|
|
15
|
+
}
|
|
16
|
+
if (typeof globalThis['ktor-ktor-http'] === 'undefined') {
|
|
17
|
+
throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'ktor-ktor-http' was not found. Please, check whether 'ktor-ktor-http' is loaded prior to 'ktor-ktor-http-cio'.");
|
|
18
|
+
}
|
|
19
|
+
if (typeof globalThis['ktor-ktor-io'] === 'undefined') {
|
|
20
|
+
throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'ktor-ktor-io' was not found. Please, check whether 'ktor-ktor-io' is loaded prior to 'ktor-ktor-http-cio'.");
|
|
21
|
+
}
|
|
22
|
+
if (typeof globalThis['kotlinx-io-kotlinx-io-core'] === 'undefined') {
|
|
23
|
+
throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'kotlinx-io-kotlinx-io-core' was not found. Please, check whether 'kotlinx-io-kotlinx-io-core' is loaded prior to 'ktor-ktor-http-cio'.");
|
|
24
|
+
}
|
|
25
|
+
if (typeof globalThis['kotlinx-io-kotlinx-io-bytestring'] === 'undefined') {
|
|
26
|
+
throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'kotlinx-io-kotlinx-io-bytestring' was not found. Please, check whether 'kotlinx-io-kotlinx-io-bytestring' is loaded prior to 'ktor-ktor-http-cio'.");
|
|
27
|
+
}
|
|
28
|
+
globalThis['ktor-ktor-http-cio'] = factory(typeof globalThis['ktor-ktor-http-cio'] === 'undefined' ? {} : globalThis['ktor-ktor-http-cio'], globalThis['kotlin-kotlin-stdlib'], globalThis['ktor-ktor-utils'], globalThis['kotlinx-coroutines-core'], globalThis['ktor-ktor-http'], globalThis['ktor-ktor-io'], globalThis['kotlinx-io-kotlinx-io-core'], globalThis['kotlinx-io-kotlinx-io-bytestring']);
|
|
29
|
+
}
|
|
30
|
+
}(function (_, kotlin_kotlin, kotlin_io_ktor_ktor_utils, kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core, kotlin_io_ktor_ktor_http, kotlin_io_ktor_ktor_io, kotlin_org_jetbrains_kotlinx_kotlinx_io_core, kotlin_org_jetbrains_kotlinx_kotlinx_io_bytestring) {
|
|
31
|
+
'use strict';
|
|
32
|
+
//region block: imports
|
|
33
|
+
var imul = Math.imul;
|
|
34
|
+
var KProperty1 = kotlin_kotlin.$_$.tf;
|
|
35
|
+
var getPropertyCallableRef = kotlin_kotlin.$_$.rd;
|
|
36
|
+
var toString = kotlin_kotlin.$_$.af;
|
|
37
|
+
var protoOf = kotlin_kotlin.$_$.we;
|
|
38
|
+
var listOf = kotlin_kotlin.$_$.t9;
|
|
39
|
+
var Entry = kotlin_kotlin.$_$.t6;
|
|
40
|
+
var initMetadataForClass = kotlin_kotlin.$_$.ud;
|
|
41
|
+
var VOID = kotlin_kotlin.$_$.h;
|
|
42
|
+
var LinkedHashSet_init_$Create$ = kotlin_kotlin.$_$.e1;
|
|
43
|
+
var Unit_instance = kotlin_kotlin.$_$.h6;
|
|
44
|
+
var LazyThreadSafetyMode_NONE_getInstance = kotlin_kotlin.$_$.n;
|
|
45
|
+
var lazy = kotlin_kotlin.$_$.xl;
|
|
46
|
+
var map = kotlin_kotlin.$_$.ag;
|
|
47
|
+
var toList = kotlin_kotlin.$_$.dg;
|
|
48
|
+
var toSet = kotlin_kotlin.$_$.eg;
|
|
49
|
+
var forEach = kotlin_io_ktor_ktor_utils.$_$.i1;
|
|
50
|
+
var StringValues = kotlin_io_ktor_ktor_utils.$_$.n1;
|
|
51
|
+
var CoroutineImpl = kotlin_kotlin.$_$.tc;
|
|
52
|
+
var ChannelResult__getOrNull_impl_f5e07h = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.r;
|
|
53
|
+
var get_COROUTINE_SUSPENDED = kotlin_kotlin.$_$.dc;
|
|
54
|
+
var initMetadataForCoroutine = kotlin_kotlin.$_$.wd;
|
|
55
|
+
var ClosedReceiveChannelException = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.a1;
|
|
56
|
+
var Companion_getInstance = kotlin_io_ktor_ktor_http.$_$.c;
|
|
57
|
+
var readRemaining = kotlin_io_ktor_ktor_io.$_$.g;
|
|
58
|
+
var FileItem = kotlin_io_ktor_ktor_http.$_$.y;
|
|
59
|
+
var readText = kotlin_io_ktor_ktor_io.$_$.n2;
|
|
60
|
+
var FormItem = kotlin_io_ktor_ktor_http.$_$.z;
|
|
61
|
+
var closeFinally = kotlin_kotlin.$_$.ol;
|
|
62
|
+
var Long = kotlin_kotlin.$_$.sk;
|
|
63
|
+
var MultiPartData = kotlin_io_ktor_ktor_http.$_$.p;
|
|
64
|
+
var CoroutineScope = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.c2;
|
|
65
|
+
var GlobalScope_instance = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.w;
|
|
66
|
+
var reader = kotlin_io_ktor_ktor_io.$_$.o2;
|
|
67
|
+
var ByteChannel = kotlin_io_ktor_ktor_io.$_$.t1;
|
|
68
|
+
var DefaultPool = kotlin_io_ktor_ktor_io.$_$.r1;
|
|
69
|
+
var StringBuilder_init_$Create$ = kotlin_kotlin.$_$.o1;
|
|
70
|
+
var THROW_CCE = kotlin_kotlin.$_$.zk;
|
|
71
|
+
var StringBuilder = kotlin_kotlin.$_$.hg;
|
|
72
|
+
var ReaderScope = kotlin_io_ktor_ktor_io.$_$.a2;
|
|
73
|
+
var initMetadataForLambda = kotlin_kotlin.$_$.zd;
|
|
74
|
+
var readUTF8LineTo = kotlin_io_ktor_ktor_io.$_$.i;
|
|
75
|
+
var EOFException_init_$Create$ = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.a;
|
|
76
|
+
var charSequenceLength = kotlin_kotlin.$_$.id;
|
|
77
|
+
var _Char___init__impl__6a9atx = kotlin_kotlin.$_$.j3;
|
|
78
|
+
var copyTo = kotlin_io_ktor_ktor_io.$_$.b;
|
|
79
|
+
var close = kotlin_io_ktor_ktor_io.$_$.g2;
|
|
80
|
+
var UnsafeBufferOperations_instance = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.f;
|
|
81
|
+
var IllegalArgumentException_init_$Create$ = kotlin_kotlin.$_$.e2;
|
|
82
|
+
var ensureNotNull = kotlin_kotlin.$_$.sl;
|
|
83
|
+
var IllegalStateException_init_$Create$ = kotlin_kotlin.$_$.j2;
|
|
84
|
+
var toLong = kotlin_kotlin.$_$.ye;
|
|
85
|
+
var writeFully = kotlin_io_ktor_ktor_io.$_$.p;
|
|
86
|
+
var writeShort = kotlin_io_ktor_ktor_io.$_$.r;
|
|
87
|
+
var toByteArray = kotlin_io_ktor_ktor_io.$_$.n1;
|
|
88
|
+
var charSequenceGet = kotlin_kotlin.$_$.hd;
|
|
89
|
+
var singleOrNull = kotlin_kotlin.$_$.qa;
|
|
90
|
+
var emptyList = kotlin_kotlin.$_$.m8;
|
|
91
|
+
var ArrayList_init_$Create$ = kotlin_kotlin.$_$.t;
|
|
92
|
+
var charSequenceSubSequence = kotlin_kotlin.$_$.jd;
|
|
93
|
+
var charCodeAt = kotlin_kotlin.$_$.gd;
|
|
94
|
+
var Char = kotlin_kotlin.$_$.hk;
|
|
95
|
+
var to = kotlin_kotlin.$_$.hm;
|
|
96
|
+
var listOf_0 = kotlin_kotlin.$_$.u9;
|
|
97
|
+
var initMetadataForCompanion = kotlin_kotlin.$_$.vd;
|
|
98
|
+
var StringBuilder_init_$Create$_0 = kotlin_kotlin.$_$.p1;
|
|
99
|
+
var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.s;
|
|
100
|
+
var joinTo = kotlin_kotlin.$_$.k9;
|
|
101
|
+
var getKClassFromExpression = kotlin_kotlin.$_$.e;
|
|
102
|
+
var equals = kotlin_kotlin.$_$.md;
|
|
103
|
+
var getBooleanHashCode = kotlin_kotlin.$_$.od;
|
|
104
|
+
var hashCode = kotlin_kotlin.$_$.td;
|
|
105
|
+
var Companion_getInstance_0 = kotlin_io_ktor_ktor_http.$_$.j;
|
|
106
|
+
var split = kotlin_kotlin.$_$.ii;
|
|
107
|
+
var isCharSequence = kotlin_kotlin.$_$.fe;
|
|
108
|
+
var trim = kotlin_kotlin.$_$.yj;
|
|
109
|
+
var Companion_getInstance_1 = kotlin_io_ktor_ktor_http.$_$.k;
|
|
110
|
+
var SequenceScope = kotlin_kotlin.$_$.vf;
|
|
111
|
+
var sequence = kotlin_kotlin.$_$.bg;
|
|
112
|
+
var abs = kotlin_kotlin.$_$.bf;
|
|
113
|
+
var fill = kotlin_kotlin.$_$.p8;
|
|
114
|
+
var isIntArray = kotlin_kotlin.$_$.ie;
|
|
115
|
+
var endsWith = kotlin_kotlin.$_$.sg;
|
|
116
|
+
var Char__compareTo_impl_ypi4mb = kotlin_kotlin.$_$.k3;
|
|
117
|
+
var contains = kotlin_kotlin.$_$.lg;
|
|
118
|
+
var Char__toInt_impl_vasixd = kotlin_kotlin.$_$.q3;
|
|
119
|
+
var IllegalStateException = kotlin_kotlin.$_$.qk;
|
|
120
|
+
var IllegalStateException_init_$Init$ = kotlin_kotlin.$_$.i2;
|
|
121
|
+
var captureStack = kotlin_kotlin.$_$.dd;
|
|
122
|
+
var HttpMethod = kotlin_io_ktor_ktor_http.$_$.g1;
|
|
123
|
+
var HttpHeaders_getInstance = kotlin_io_ktor_ktor_http.$_$.i;
|
|
124
|
+
var setOf = kotlin_kotlin.$_$.pa;
|
|
125
|
+
var Companion_getInstance_2 = kotlin_io_ktor_ktor_io.$_$.w;
|
|
126
|
+
var LineEndingMode__plus_impl_ttpz2j = kotlin_io_ktor_ktor_io.$_$.t;
|
|
127
|
+
var MultiPart_getInstance = kotlin_io_ktor_ktor_http.$_$.f;
|
|
128
|
+
var ByteString_init_$Create$ = kotlin_org_jetbrains_kotlinx_kotlinx_io_bytestring.$_$.a;
|
|
129
|
+
var IOException_init_$Create$ = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.c;
|
|
130
|
+
var toString_0 = kotlin_kotlin.$_$.mj;
|
|
131
|
+
var toByte = kotlin_kotlin.$_$.xe;
|
|
132
|
+
var copyOfRange = kotlin_kotlin.$_$.x7;
|
|
133
|
+
var produce = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.d1;
|
|
134
|
+
var startsWith = kotlin_kotlin.$_$.mi;
|
|
135
|
+
var readUntil = kotlin_io_ktor_ktor_io.$_$.k;
|
|
136
|
+
var WriterScope = kotlin_io_ktor_ktor_io.$_$.b2;
|
|
137
|
+
var ProducerScope = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.b1;
|
|
138
|
+
var isInterface = kotlin_kotlin.$_$.je;
|
|
139
|
+
var counted = kotlin_io_ktor_ktor_io.$_$.h2;
|
|
140
|
+
var writer = kotlin_io_ktor_ktor_io.$_$.q2;
|
|
141
|
+
var get_remaining = kotlin_io_ktor_ktor_io.$_$.l1;
|
|
142
|
+
var skipIfFound = kotlin_io_ktor_ktor_io.$_$.l;
|
|
143
|
+
var CompletableDeferred = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.x1;
|
|
144
|
+
var CancellationException_init_$Create$ = kotlin_kotlin.$_$.i1;
|
|
145
|
+
var readPacket = kotlin_io_ktor_ktor_io.$_$.f;
|
|
146
|
+
var ByteString = kotlin_org_jetbrains_kotlinx_kotlinx_io_bytestring.$_$.c;
|
|
147
|
+
var AutoCloseable = kotlin_kotlin.$_$.fk;
|
|
148
|
+
var LinkedHashMap_init_$Create$ = kotlin_kotlin.$_$.c1;
|
|
149
|
+
var compareTo = kotlin_kotlin.$_$.kd;
|
|
150
|
+
var NoSuchElementException_init_$Create$ = kotlin_kotlin.$_$.r2;
|
|
151
|
+
var Collection = kotlin_kotlin.$_$.n6;
|
|
152
|
+
var toString_1 = kotlin_kotlin.$_$.r3;
|
|
153
|
+
var getStringHashCode = kotlin_kotlin.$_$.sd;
|
|
154
|
+
var CharSequence = kotlin_kotlin.$_$.gk;
|
|
155
|
+
var IndexOutOfBoundsException_init_$Create$ = kotlin_kotlin.$_$.o2;
|
|
156
|
+
var NoPoolImpl = kotlin_io_ktor_ktor_io.$_$.s1;
|
|
157
|
+
var charArray = kotlin_kotlin.$_$.fd;
|
|
158
|
+
var NumberFormatException_init_$Create$ = kotlin_kotlin.$_$.t2;
|
|
159
|
+
var writeByte = kotlin_io_ktor_ktor_io.$_$.o;
|
|
160
|
+
var numberRangeToNumber = kotlin_kotlin.$_$.re;
|
|
161
|
+
var collectionSizeOrDefault = kotlin_kotlin.$_$.p7;
|
|
162
|
+
var numberToLong = kotlin_kotlin.$_$.ue;
|
|
163
|
+
var toLongArray = kotlin_kotlin.$_$.ib;
|
|
164
|
+
var Char__plus_impl_qi7pgj = kotlin_kotlin.$_$.o3;
|
|
165
|
+
var Char__minus_impl_a2frrh = kotlin_kotlin.$_$.n3;
|
|
166
|
+
var toByteArray_0 = kotlin_kotlin.$_$.cb;
|
|
167
|
+
var IOException = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.k;
|
|
168
|
+
var IOException_init_$Init$ = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.b;
|
|
169
|
+
var isWhitespace = kotlin_kotlin.$_$.nh;
|
|
170
|
+
var cancel = kotlin_io_ktor_ktor_io.$_$.e2;
|
|
171
|
+
var BytePacketBuilder = kotlin_io_ktor_ktor_io.$_$.e1;
|
|
172
|
+
var writeText = kotlin_io_ktor_ktor_io.$_$.p1;
|
|
173
|
+
var append = kotlin_io_ktor_ktor_io.$_$.f1;
|
|
174
|
+
var build = kotlin_io_ktor_ktor_io.$_$.g1;
|
|
175
|
+
//endregion
|
|
176
|
+
//region block: pre-declaration
|
|
177
|
+
initMetadataForClass(Entry_0, 'Entry', VOID, VOID, [Entry]);
|
|
178
|
+
initMetadataForClass(CIOHeaders, 'CIOHeaders', VOID, VOID, [StringValues]);
|
|
179
|
+
initMetadataForCoroutine($readPartCOROUTINE$, CoroutineImpl);
|
|
180
|
+
initMetadataForCoroutine($readPartSuspendCOROUTINE$, CoroutineImpl);
|
|
181
|
+
initMetadataForCoroutine($eventToDataCOROUTINE$, CoroutineImpl);
|
|
182
|
+
initMetadataForCoroutine($partToDataCOROUTINE$, CoroutineImpl);
|
|
183
|
+
initMetadataForClass(CIOMultipartDataBase, 'CIOMultipartDataBase', VOID, VOID, [MultiPartData, CoroutineScope], [0, 1]);
|
|
184
|
+
initMetadataForClass(ChunkSizeBufferPool$1, VOID, VOID, DefaultPool);
|
|
185
|
+
initMetadataForLambda(encodeChunked$slambda, CoroutineImpl, VOID, [1]);
|
|
186
|
+
initMetadataForCoroutine($decodeChunkedCOROUTINE$, CoroutineImpl);
|
|
187
|
+
initMetadataForCoroutine($encodeChunkedCOROUTINE$, CoroutineImpl);
|
|
188
|
+
initMetadataForCoroutine($writeChunkCOROUTINE$, CoroutineImpl);
|
|
189
|
+
initMetadataForCompanion(Companion);
|
|
190
|
+
initMetadataForClass(ConnectionOptions, 'ConnectionOptions', ConnectionOptions);
|
|
191
|
+
initMetadataForCoroutine($parseHttpBodyCOROUTINE$, CoroutineImpl);
|
|
192
|
+
initMetadataForLambda(HeadersData$headersStarts$slambda, CoroutineImpl, VOID, [1]);
|
|
193
|
+
initMetadataForClass(HeadersData, 'HeadersData', HeadersData);
|
|
194
|
+
initMetadataForLambda(HttpHeadersMap$getAll$slambda, CoroutineImpl, VOID, [1]);
|
|
195
|
+
initMetadataForClass(HttpHeadersMap, 'HttpHeadersMap');
|
|
196
|
+
initMetadataForClass(IntArrayPool$1, VOID, VOID, DefaultPool);
|
|
197
|
+
initMetadataForClass(HeadersDataPool$1, VOID, VOID, DefaultPool);
|
|
198
|
+
initMetadataForClass(ParserException, 'ParserException', VOID, IllegalStateException);
|
|
199
|
+
initMetadataForCoroutine($parseHeadersCOROUTINE$, CoroutineImpl);
|
|
200
|
+
initMetadataForCoroutine($parseRequestCOROUTINE$, CoroutineImpl);
|
|
201
|
+
initMetadataForClass(MultipartEvent, 'MultipartEvent');
|
|
202
|
+
initMetadataForClass(Preamble, 'Preamble', VOID, MultipartEvent);
|
|
203
|
+
initMetadataForClass(MultipartPart, 'MultipartPart', VOID, MultipartEvent);
|
|
204
|
+
initMetadataForClass(Epilogue, 'Epilogue', VOID, MultipartEvent);
|
|
205
|
+
initMetadataForLambda(parseMultipart$slambda$slambda, CoroutineImpl, VOID, [1]);
|
|
206
|
+
initMetadataForLambda(parseMultipart$slambda, CoroutineImpl, VOID, [1]);
|
|
207
|
+
initMetadataForCoroutine($parsePartHeadersImplCOROUTINE$, CoroutineImpl);
|
|
208
|
+
initMetadataForCoroutine($parsePartBodyImplCOROUTINE$, CoroutineImpl);
|
|
209
|
+
initMetadataForCoroutine($skipIfFoundReadCountCOROUTINE$, CoroutineImpl);
|
|
210
|
+
initMetadataForClass(HttpMessage, 'HttpMessage', VOID, VOID, [AutoCloseable]);
|
|
211
|
+
initMetadataForClass(Request, 'Request', VOID, HttpMessage);
|
|
212
|
+
initMetadataForClass(Node, 'Node');
|
|
213
|
+
initMetadataForCompanion(Companion_0);
|
|
214
|
+
initMetadataForClass(AsciiCharTree, 'AsciiCharTree');
|
|
215
|
+
initMetadataForClass(SubSequenceImpl, 'SubSequenceImpl', VOID, VOID, [CharSequence]);
|
|
216
|
+
initMetadataForClass(CharArrayBuilder, 'CharArrayBuilder', CharArrayBuilder, VOID, [CharSequence]);
|
|
217
|
+
initMetadataForClass(CharArrayPool$1, VOID, VOID, NoPoolImpl);
|
|
218
|
+
initMetadataForClass(CharArrayPool$2, VOID, VOID, DefaultPool);
|
|
219
|
+
initMetadataForCoroutine($writeIntHexCOROUTINE$, CoroutineImpl);
|
|
220
|
+
initMetadataForClass(UnsupportedMediaTypeExceptionCIO, 'UnsupportedMediaTypeExceptionCIO', VOID, IOException);
|
|
221
|
+
initMetadataForClass(MutableRange, 'MutableRange');
|
|
222
|
+
initMetadataForClass(RequestResponseBuilder, 'RequestResponseBuilder', RequestResponseBuilder);
|
|
223
|
+
//endregion
|
|
224
|
+
function _get_names__dwg6t3($this) {
|
|
225
|
+
var tmp0 = $this.b5l_1;
|
|
226
|
+
var tmp = KProperty1;
|
|
227
|
+
// Inline function 'kotlin.getValue' call
|
|
228
|
+
getPropertyCallableRef('names', 1, tmp, CIOHeaders$_get_names_$ref_z8h5o1(), null);
|
|
229
|
+
return tmp0.b1();
|
|
230
|
+
}
|
|
231
|
+
function Entry_0($outer, offset) {
|
|
232
|
+
this.d5l_1 = $outer;
|
|
233
|
+
this.c5l_1 = offset;
|
|
234
|
+
}
|
|
235
|
+
protoOf(Entry_0).a1 = function () {
|
|
236
|
+
return toString(this.d5l_1.a5l_1.i5l(this.c5l_1));
|
|
237
|
+
};
|
|
238
|
+
protoOf(Entry_0).b1 = function () {
|
|
239
|
+
return listOf(toString(this.d5l_1.a5l_1.j5l(this.c5l_1)));
|
|
240
|
+
};
|
|
241
|
+
function CIOHeaders$names$delegate$lambda(this$0) {
|
|
242
|
+
return function () {
|
|
243
|
+
// Inline function 'kotlin.apply' call
|
|
244
|
+
var this_0 = LinkedHashSet_init_$Create$(this$0.a5l_1.f5l_1);
|
|
245
|
+
var _iterator__ex2g4s = this$0.a5l_1.k5l().p();
|
|
246
|
+
while (_iterator__ex2g4s.q()) {
|
|
247
|
+
var offset = _iterator__ex2g4s.r();
|
|
248
|
+
this_0.h(toString(this$0.a5l_1.i5l(offset)));
|
|
249
|
+
}
|
|
250
|
+
return this_0;
|
|
251
|
+
};
|
|
252
|
+
}
|
|
253
|
+
function CIOHeaders$_get_names_$ref_z8h5o1() {
|
|
254
|
+
return function (p0) {
|
|
255
|
+
return _get_names__dwg6t3(p0);
|
|
256
|
+
};
|
|
257
|
+
}
|
|
258
|
+
function CIOHeaders$getAll$lambda(it) {
|
|
259
|
+
return toString(it);
|
|
260
|
+
}
|
|
261
|
+
function CIOHeaders$entries$lambda(this$0) {
|
|
262
|
+
return function (idx) {
|
|
263
|
+
return new Entry_0(this$0, idx);
|
|
264
|
+
};
|
|
265
|
+
}
|
|
266
|
+
function CIOHeaders(headers) {
|
|
267
|
+
this.a5l_1 = headers;
|
|
268
|
+
var tmp = this;
|
|
269
|
+
var tmp_0 = LazyThreadSafetyMode_NONE_getInstance();
|
|
270
|
+
tmp.b5l_1 = lazy(tmp_0, CIOHeaders$names$delegate$lambda(this));
|
|
271
|
+
}
|
|
272
|
+
protoOf(CIOHeaders).a4z = function () {
|
|
273
|
+
return true;
|
|
274
|
+
};
|
|
275
|
+
protoOf(CIOHeaders).c4z = function () {
|
|
276
|
+
return _get_names__dwg6t3(this);
|
|
277
|
+
};
|
|
278
|
+
protoOf(CIOHeaders).cf = function (name) {
|
|
279
|
+
var tmp0_safe_receiver = this.a5l_1.cf(name);
|
|
280
|
+
return tmp0_safe_receiver == null ? null : toString(tmp0_safe_receiver);
|
|
281
|
+
};
|
|
282
|
+
protoOf(CIOHeaders).b4z = function (name) {
|
|
283
|
+
var tmp = this.a5l_1.b4z(name);
|
|
284
|
+
// Inline function 'kotlin.takeIf' call
|
|
285
|
+
var this_0 = toList(map(tmp, CIOHeaders$getAll$lambda));
|
|
286
|
+
var tmp_0;
|
|
287
|
+
// Inline function 'kotlin.collections.isNotEmpty' call
|
|
288
|
+
if (!this_0.m()) {
|
|
289
|
+
tmp_0 = this_0;
|
|
290
|
+
} else {
|
|
291
|
+
tmp_0 = null;
|
|
292
|
+
}
|
|
293
|
+
return tmp_0;
|
|
294
|
+
};
|
|
295
|
+
protoOf(CIOHeaders).d4z = function () {
|
|
296
|
+
var tmp = this.a5l_1.k5l();
|
|
297
|
+
return toSet(map(tmp, CIOHeaders$entries$lambda(this)));
|
|
298
|
+
};
|
|
299
|
+
function readPartSuspend($this, $completion) {
|
|
300
|
+
var tmp = new $readPartSuspendCOROUTINE$($this, $completion);
|
|
301
|
+
tmp.z9_1 = Unit_instance;
|
|
302
|
+
tmp.aa_1 = null;
|
|
303
|
+
return tmp.fa();
|
|
304
|
+
}
|
|
305
|
+
function eventToData($this, event, $completion) {
|
|
306
|
+
var tmp = new $eventToDataCOROUTINE$($this, event, $completion);
|
|
307
|
+
tmp.z9_1 = Unit_instance;
|
|
308
|
+
tmp.aa_1 = null;
|
|
309
|
+
return tmp.fa();
|
|
310
|
+
}
|
|
311
|
+
function partToData($this, part, $completion) {
|
|
312
|
+
var tmp = new $partToDataCOROUTINE$($this, part, $completion);
|
|
313
|
+
tmp.z9_1 = Unit_instance;
|
|
314
|
+
tmp.aa_1 = null;
|
|
315
|
+
return tmp.fa();
|
|
316
|
+
}
|
|
317
|
+
function CIOMultipartDataBase$partToData$lambda($part) {
|
|
318
|
+
return function () {
|
|
319
|
+
$part.m1h();
|
|
320
|
+
return Unit_instance;
|
|
321
|
+
};
|
|
322
|
+
}
|
|
323
|
+
function CIOMultipartDataBase$partToData$lambda_0($part) {
|
|
324
|
+
return function () {
|
|
325
|
+
return $part.x5m_1;
|
|
326
|
+
};
|
|
327
|
+
}
|
|
328
|
+
function CIOMultipartDataBase$partToData$lambda_1($part) {
|
|
329
|
+
return function () {
|
|
330
|
+
$part.m1h();
|
|
331
|
+
return Unit_instance;
|
|
332
|
+
};
|
|
333
|
+
}
|
|
334
|
+
function $readPartCOROUTINE$(_this__u8e3s4, resultContinuation) {
|
|
335
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
336
|
+
this.g5n_1 = _this__u8e3s4;
|
|
337
|
+
}
|
|
338
|
+
protoOf($readPartCOROUTINE$).fa = function () {
|
|
339
|
+
var suspendResult = this.z9_1;
|
|
340
|
+
$sm: do
|
|
341
|
+
try {
|
|
342
|
+
var tmp = this.x9_1;
|
|
343
|
+
switch (tmp) {
|
|
344
|
+
case 0:
|
|
345
|
+
this.y9_1 = 6;
|
|
346
|
+
var tmp0_safe_receiver = this.g5n_1.m5n_1;
|
|
347
|
+
var tmp1_safe_receiver = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.k5j_1;
|
|
348
|
+
if (tmp1_safe_receiver == null)
|
|
349
|
+
null;
|
|
350
|
+
else
|
|
351
|
+
tmp1_safe_receiver();
|
|
352
|
+
this.x9_1 = 1;
|
|
353
|
+
continue $sm;
|
|
354
|
+
case 1:
|
|
355
|
+
if (!true) {
|
|
356
|
+
this.x9_1 = 4;
|
|
357
|
+
continue $sm;
|
|
358
|
+
}
|
|
359
|
+
|
|
360
|
+
this.h5n_1 = ChannelResult__getOrNull_impl_f5e07h(this.g5n_1.n5n_1.s2i());
|
|
361
|
+
if (this.h5n_1 == null) {
|
|
362
|
+
this.x9_1 = 4;
|
|
363
|
+
var tmp_0 = this;
|
|
364
|
+
continue $sm;
|
|
365
|
+
} else {
|
|
366
|
+
this.i5n_1 = this.h5n_1;
|
|
367
|
+
this.x9_1 = 2;
|
|
368
|
+
continue $sm;
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
case 2:
|
|
372
|
+
this.j5n_1 = this.i5n_1;
|
|
373
|
+
this.x9_1 = 3;
|
|
374
|
+
suspendResult = eventToData(this.g5n_1, this.j5n_1, this);
|
|
375
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
376
|
+
return suspendResult;
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
continue $sm;
|
|
380
|
+
case 3:
|
|
381
|
+
this.k5n_1 = suspendResult;
|
|
382
|
+
if (this.k5n_1 == null)
|
|
383
|
+
null;
|
|
384
|
+
else {
|
|
385
|
+
var it = this.k5n_1;
|
|
386
|
+
this.g5n_1.m5n_1 = it;
|
|
387
|
+
return it;
|
|
388
|
+
}
|
|
389
|
+
|
|
390
|
+
this.x9_1 = 1;
|
|
391
|
+
continue $sm;
|
|
392
|
+
case 4:
|
|
393
|
+
this.x9_1 = 5;
|
|
394
|
+
suspendResult = readPartSuspend(this.g5n_1, this);
|
|
395
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
396
|
+
return suspendResult;
|
|
397
|
+
}
|
|
398
|
+
|
|
399
|
+
continue $sm;
|
|
400
|
+
case 5:
|
|
401
|
+
return suspendResult;
|
|
402
|
+
case 6:
|
|
403
|
+
throw this.aa_1;
|
|
404
|
+
}
|
|
405
|
+
} catch ($p) {
|
|
406
|
+
var e = $p;
|
|
407
|
+
if (this.y9_1 === 6) {
|
|
408
|
+
throw e;
|
|
409
|
+
} else {
|
|
410
|
+
this.x9_1 = this.y9_1;
|
|
411
|
+
this.aa_1 = e;
|
|
412
|
+
}
|
|
413
|
+
}
|
|
414
|
+
while (true);
|
|
415
|
+
};
|
|
416
|
+
function $readPartSuspendCOROUTINE$(_this__u8e3s4, resultContinuation) {
|
|
417
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
418
|
+
this.t5l_1 = _this__u8e3s4;
|
|
419
|
+
}
|
|
420
|
+
protoOf($readPartSuspendCOROUTINE$).fa = function () {
|
|
421
|
+
var suspendResult = this.z9_1;
|
|
422
|
+
$sm: do
|
|
423
|
+
try {
|
|
424
|
+
var tmp = this.x9_1;
|
|
425
|
+
switch (tmp) {
|
|
426
|
+
case 0:
|
|
427
|
+
this.y9_1 = 6;
|
|
428
|
+
this.y9_1 = 5;
|
|
429
|
+
this.x9_1 = 1;
|
|
430
|
+
continue $sm;
|
|
431
|
+
case 1:
|
|
432
|
+
if (!true) {
|
|
433
|
+
this.x9_1 = 4;
|
|
434
|
+
continue $sm;
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
this.x9_1 = 2;
|
|
438
|
+
suspendResult = this.t5l_1.n5n_1.q2i(this);
|
|
439
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
440
|
+
return suspendResult;
|
|
441
|
+
}
|
|
442
|
+
|
|
443
|
+
continue $sm;
|
|
444
|
+
case 2:
|
|
445
|
+
this.u5l_1 = suspendResult;
|
|
446
|
+
this.x9_1 = 3;
|
|
447
|
+
suspendResult = eventToData(this.t5l_1, this.u5l_1, this);
|
|
448
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
449
|
+
return suspendResult;
|
|
450
|
+
}
|
|
451
|
+
|
|
452
|
+
continue $sm;
|
|
453
|
+
case 3:
|
|
454
|
+
var tmp0_safe_receiver = suspendResult;
|
|
455
|
+
if (tmp0_safe_receiver == null)
|
|
456
|
+
null;
|
|
457
|
+
else {
|
|
458
|
+
return tmp0_safe_receiver;
|
|
459
|
+
}
|
|
460
|
+
|
|
461
|
+
this.x9_1 = 1;
|
|
462
|
+
continue $sm;
|
|
463
|
+
case 4:
|
|
464
|
+
this.y9_1 = 6;
|
|
465
|
+
this.x9_1 = 7;
|
|
466
|
+
continue $sm;
|
|
467
|
+
case 5:
|
|
468
|
+
this.y9_1 = 6;
|
|
469
|
+
var tmp_0 = this.aa_1;
|
|
470
|
+
if (tmp_0 instanceof ClosedReceiveChannelException) {
|
|
471
|
+
var _unused_var__etf5q3 = this.aa_1;
|
|
472
|
+
return null;
|
|
473
|
+
} else {
|
|
474
|
+
throw this.aa_1;
|
|
475
|
+
}
|
|
476
|
+
|
|
477
|
+
case 6:
|
|
478
|
+
throw this.aa_1;
|
|
479
|
+
case 7:
|
|
480
|
+
this.y9_1 = 6;
|
|
481
|
+
return Unit_instance;
|
|
482
|
+
}
|
|
483
|
+
} catch ($p) {
|
|
484
|
+
var e = $p;
|
|
485
|
+
if (this.y9_1 === 6) {
|
|
486
|
+
throw e;
|
|
487
|
+
} else {
|
|
488
|
+
this.x9_1 = this.y9_1;
|
|
489
|
+
this.aa_1 = e;
|
|
490
|
+
}
|
|
491
|
+
}
|
|
492
|
+
while (true);
|
|
493
|
+
};
|
|
494
|
+
function $eventToDataCOROUTINE$(_this__u8e3s4, event, resultContinuation) {
|
|
495
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
496
|
+
this.d5m_1 = _this__u8e3s4;
|
|
497
|
+
this.e5m_1 = event;
|
|
498
|
+
}
|
|
499
|
+
protoOf($eventToDataCOROUTINE$).fa = function () {
|
|
500
|
+
var suspendResult = this.z9_1;
|
|
501
|
+
$sm: do
|
|
502
|
+
try {
|
|
503
|
+
var tmp = this.x9_1;
|
|
504
|
+
switch (tmp) {
|
|
505
|
+
case 0:
|
|
506
|
+
this.y9_1 = 4;
|
|
507
|
+
this.y9_1 = 3;
|
|
508
|
+
this.g5m_1 = this.e5m_1;
|
|
509
|
+
var tmp_0 = this.g5m_1;
|
|
510
|
+
if (tmp_0 instanceof MultipartPart) {
|
|
511
|
+
this.x9_1 = 1;
|
|
512
|
+
suspendResult = partToData(this.d5m_1, this.e5m_1, this);
|
|
513
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
514
|
+
return suspendResult;
|
|
515
|
+
}
|
|
516
|
+
continue $sm;
|
|
517
|
+
} else {
|
|
518
|
+
var tmp_1 = this;
|
|
519
|
+
this.e5m_1.m1h();
|
|
520
|
+
tmp_1.h5m_1 = null;
|
|
521
|
+
this.x9_1 = 2;
|
|
522
|
+
continue $sm;
|
|
523
|
+
}
|
|
524
|
+
|
|
525
|
+
case 1:
|
|
526
|
+
this.h5m_1 = suspendResult;
|
|
527
|
+
this.x9_1 = 2;
|
|
528
|
+
continue $sm;
|
|
529
|
+
case 2:
|
|
530
|
+
this.f5m_1 = this.h5m_1;
|
|
531
|
+
this.y9_1 = 4;
|
|
532
|
+
this.x9_1 = 5;
|
|
533
|
+
continue $sm;
|
|
534
|
+
case 3:
|
|
535
|
+
this.y9_1 = 4;
|
|
536
|
+
var tmp_2 = this.aa_1;
|
|
537
|
+
if (tmp_2 instanceof Error) {
|
|
538
|
+
var cause = this.aa_1;
|
|
539
|
+
var tmp_3 = this;
|
|
540
|
+
this.e5m_1.m1h();
|
|
541
|
+
throw cause;
|
|
542
|
+
} else {
|
|
543
|
+
throw this.aa_1;
|
|
544
|
+
}
|
|
545
|
+
|
|
546
|
+
case 4:
|
|
547
|
+
throw this.aa_1;
|
|
548
|
+
case 5:
|
|
549
|
+
this.y9_1 = 4;
|
|
550
|
+
return this.f5m_1;
|
|
551
|
+
}
|
|
552
|
+
} catch ($p) {
|
|
553
|
+
var e = $p;
|
|
554
|
+
if (this.y9_1 === 4) {
|
|
555
|
+
throw e;
|
|
556
|
+
} else {
|
|
557
|
+
this.x9_1 = this.y9_1;
|
|
558
|
+
this.aa_1 = e;
|
|
559
|
+
}
|
|
560
|
+
}
|
|
561
|
+
while (true);
|
|
562
|
+
};
|
|
563
|
+
function $partToDataCOROUTINE$(_this__u8e3s4, part, resultContinuation) {
|
|
564
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
565
|
+
this.q5m_1 = _this__u8e3s4;
|
|
566
|
+
this.r5m_1 = part;
|
|
567
|
+
}
|
|
568
|
+
protoOf($partToDataCOROUTINE$).fa = function () {
|
|
569
|
+
var suspendResult = this.z9_1;
|
|
570
|
+
$sm: do
|
|
571
|
+
try {
|
|
572
|
+
var tmp = this.x9_1;
|
|
573
|
+
switch (tmp) {
|
|
574
|
+
case 0:
|
|
575
|
+
this.y9_1 = 4;
|
|
576
|
+
this.x9_1 = 1;
|
|
577
|
+
suspendResult = this.r5m_1.w5m_1.w21(this);
|
|
578
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
579
|
+
return suspendResult;
|
|
580
|
+
}
|
|
581
|
+
|
|
582
|
+
continue $sm;
|
|
583
|
+
case 1:
|
|
584
|
+
this.s5m_1 = suspendResult;
|
|
585
|
+
var tmp_0 = this;
|
|
586
|
+
var tmp0_safe_receiver = this.s5m_1.cf('Content-Disposition');
|
|
587
|
+
var tmp_1;
|
|
588
|
+
if (tmp0_safe_receiver == null) {
|
|
589
|
+
tmp_1 = null;
|
|
590
|
+
} else {
|
|
591
|
+
tmp_1 = Companion_getInstance().dt(toString(tmp0_safe_receiver));
|
|
592
|
+
}
|
|
593
|
+
|
|
594
|
+
tmp_0.t5m_1 = tmp_1;
|
|
595
|
+
var tmp_2 = this;
|
|
596
|
+
var tmp1_safe_receiver = this.t5m_1;
|
|
597
|
+
tmp_2.u5m_1 = tmp1_safe_receiver == null ? null : tmp1_safe_receiver.y56('filename');
|
|
598
|
+
this.v5m_1 = this.r5m_1.x5m_1;
|
|
599
|
+
if (this.u5m_1 == null) {
|
|
600
|
+
this.x9_1 = 3;
|
|
601
|
+
suspendResult = readRemaining(this.v5m_1, this);
|
|
602
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
603
|
+
return suspendResult;
|
|
604
|
+
}
|
|
605
|
+
continue $sm;
|
|
606
|
+
} else {
|
|
607
|
+
this.x9_1 = 2;
|
|
608
|
+
continue $sm;
|
|
609
|
+
}
|
|
610
|
+
|
|
611
|
+
case 2:
|
|
612
|
+
var tmp_3 = CIOMultipartDataBase$partToData$lambda_0(this.r5m_1);
|
|
613
|
+
return new FileItem(tmp_3, CIOMultipartDataBase$partToData$lambda_1(this.r5m_1), new CIOHeaders(this.s5m_1));
|
|
614
|
+
case 3:
|
|
615
|
+
var packet = suspendResult;
|
|
616
|
+
l$ret$7: do {
|
|
617
|
+
var exception = null;
|
|
618
|
+
l$ret$5: do {
|
|
619
|
+
l$ret$3: do {
|
|
620
|
+
var tmp$ret$0;
|
|
621
|
+
l$ret$1: do {
|
|
622
|
+
var tmp_4;
|
|
623
|
+
try {
|
|
624
|
+
var tmp_5;
|
|
625
|
+
try {
|
|
626
|
+
var tmp_6 = readText(packet);
|
|
627
|
+
tmp$ret$0 = new FormItem(tmp_6, CIOMultipartDataBase$partToData$lambda(this.r5m_1), new CIOHeaders(this.s5m_1));
|
|
628
|
+
break l$ret$1;
|
|
629
|
+
} catch ($p) {
|
|
630
|
+
var tmp_7;
|
|
631
|
+
if ($p instanceof Error) {
|
|
632
|
+
var e = $p;
|
|
633
|
+
exception = e;
|
|
634
|
+
throw e;
|
|
635
|
+
} else {
|
|
636
|
+
throw $p;
|
|
637
|
+
}
|
|
638
|
+
}
|
|
639
|
+
} catch ($p) {
|
|
640
|
+
var tmp_8;
|
|
641
|
+
var t = $p;
|
|
642
|
+
closeFinally(packet, exception);
|
|
643
|
+
throw t;
|
|
644
|
+
}
|
|
645
|
+
}
|
|
646
|
+
while (false);
|
|
647
|
+
var tmp_9 = tmp$ret$0;
|
|
648
|
+
closeFinally(packet, exception);
|
|
649
|
+
return tmp_9;
|
|
650
|
+
}
|
|
651
|
+
while (false);
|
|
652
|
+
closeFinally(packet, exception);
|
|
653
|
+
break l$ret$7;
|
|
654
|
+
}
|
|
655
|
+
while (false);
|
|
656
|
+
closeFinally(packet, exception);
|
|
657
|
+
}
|
|
658
|
+
while (false);
|
|
659
|
+
break;
|
|
660
|
+
case 4:
|
|
661
|
+
throw this.aa_1;
|
|
662
|
+
}
|
|
663
|
+
} catch ($p) {
|
|
664
|
+
var e_0 = $p;
|
|
665
|
+
if (this.y9_1 === 4) {
|
|
666
|
+
throw e_0;
|
|
667
|
+
} else {
|
|
668
|
+
this.x9_1 = this.y9_1;
|
|
669
|
+
this.aa_1 = e_0;
|
|
670
|
+
}
|
|
671
|
+
}
|
|
672
|
+
while (true);
|
|
673
|
+
};
|
|
674
|
+
function CIOMultipartDataBase(coroutineContext, channel, contentType, contentLength, formFieldLimit) {
|
|
675
|
+
formFieldLimit = formFieldLimit === VOID ? new Long(65536, 0) : formFieldLimit;
|
|
676
|
+
this.l5n_1 = coroutineContext;
|
|
677
|
+
this.m5n_1 = null;
|
|
678
|
+
this.n5n_1 = parseMultipart(this, channel, contentType, contentLength, formFieldLimit);
|
|
679
|
+
}
|
|
680
|
+
protoOf(CIOMultipartDataBase).z1v = function () {
|
|
681
|
+
return this.l5n_1;
|
|
682
|
+
};
|
|
683
|
+
protoOf(CIOMultipartDataBase).e5j = function ($completion) {
|
|
684
|
+
var tmp = new $readPartCOROUTINE$(this, $completion);
|
|
685
|
+
tmp.z9_1 = Unit_instance;
|
|
686
|
+
tmp.aa_1 = null;
|
|
687
|
+
return tmp.fa();
|
|
688
|
+
};
|
|
689
|
+
function get_ChunkSizeBufferPool() {
|
|
690
|
+
_init_properties_ChunkedTransferEncoding_kt__hi13vs();
|
|
691
|
+
return ChunkSizeBufferPool;
|
|
692
|
+
}
|
|
693
|
+
var ChunkSizeBufferPool;
|
|
694
|
+
function get_CrLf() {
|
|
695
|
+
_init_properties_ChunkedTransferEncoding_kt__hi13vs();
|
|
696
|
+
return CrLf;
|
|
697
|
+
}
|
|
698
|
+
var CrLf;
|
|
699
|
+
function get_LastChunkBytes() {
|
|
700
|
+
_init_properties_ChunkedTransferEncoding_kt__hi13vs();
|
|
701
|
+
return LastChunkBytes;
|
|
702
|
+
}
|
|
703
|
+
var LastChunkBytes;
|
|
704
|
+
function encodeChunked(output, coroutineContext) {
|
|
705
|
+
_init_properties_ChunkedTransferEncoding_kt__hi13vs();
|
|
706
|
+
var tmp = GlobalScope_instance;
|
|
707
|
+
return reader(tmp, coroutineContext, false, encodeChunked$slambda_0(output, null));
|
|
708
|
+
}
|
|
709
|
+
function decodeChunked(input, out, $completion) {
|
|
710
|
+
var tmp = new $decodeChunkedCOROUTINE$(input, out, $completion);
|
|
711
|
+
tmp.z9_1 = Unit_instance;
|
|
712
|
+
tmp.aa_1 = null;
|
|
713
|
+
return tmp.fa();
|
|
714
|
+
}
|
|
715
|
+
function encodeChunked_0(output, input, $completion) {
|
|
716
|
+
var tmp = new $encodeChunkedCOROUTINE$(output, input, $completion);
|
|
717
|
+
tmp.z9_1 = Unit_instance;
|
|
718
|
+
tmp.aa_1 = null;
|
|
719
|
+
return tmp.fa();
|
|
720
|
+
}
|
|
721
|
+
function writeChunk(_this__u8e3s4, memory, startIndex, endIndex, $completion) {
|
|
722
|
+
var tmp = new $writeChunkCOROUTINE$(_this__u8e3s4, memory, startIndex, endIndex, $completion);
|
|
723
|
+
tmp.z9_1 = Unit_instance;
|
|
724
|
+
tmp.aa_1 = null;
|
|
725
|
+
return tmp.fa();
|
|
726
|
+
}
|
|
727
|
+
function rethrowCloseCause(_this__u8e3s4) {
|
|
728
|
+
_init_properties_ChunkedTransferEncoding_kt__hi13vs();
|
|
729
|
+
var tmp;
|
|
730
|
+
if (_this__u8e3s4 instanceof ByteChannel) {
|
|
731
|
+
tmp = _this__u8e3s4.j4i();
|
|
732
|
+
} else {
|
|
733
|
+
tmp = null;
|
|
734
|
+
}
|
|
735
|
+
var cause = tmp;
|
|
736
|
+
if (!(cause == null))
|
|
737
|
+
throw cause;
|
|
738
|
+
}
|
|
739
|
+
function ChunkSizeBufferPool$1() {
|
|
740
|
+
DefaultPool.call(this, 2048);
|
|
741
|
+
}
|
|
742
|
+
protoOf(ChunkSizeBufferPool$1).p4w = function () {
|
|
743
|
+
return StringBuilder_init_$Create$(128);
|
|
744
|
+
};
|
|
745
|
+
protoOf(ChunkSizeBufferPool$1).f5q = function (instance) {
|
|
746
|
+
// Inline function 'kotlin.apply' call
|
|
747
|
+
instance.xd();
|
|
748
|
+
return instance;
|
|
749
|
+
};
|
|
750
|
+
protoOf(ChunkSizeBufferPool$1).u4w = function (instance) {
|
|
751
|
+
return this.f5q(instance instanceof StringBuilder ? instance : THROW_CCE());
|
|
752
|
+
};
|
|
753
|
+
function encodeChunked$slambda($output, resultContinuation) {
|
|
754
|
+
this.o5q_1 = $output;
|
|
755
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
756
|
+
}
|
|
757
|
+
protoOf(encodeChunked$slambda).q5q = function ($this$reader, $completion) {
|
|
758
|
+
var tmp = this.r5q($this$reader, $completion);
|
|
759
|
+
tmp.z9_1 = Unit_instance;
|
|
760
|
+
tmp.aa_1 = null;
|
|
761
|
+
return tmp.fa();
|
|
762
|
+
};
|
|
763
|
+
protoOf(encodeChunked$slambda).ra = function (p1, $completion) {
|
|
764
|
+
return this.q5q(p1 instanceof ReaderScope ? p1 : THROW_CCE(), $completion);
|
|
765
|
+
};
|
|
766
|
+
protoOf(encodeChunked$slambda).fa = function () {
|
|
767
|
+
var suspendResult = this.z9_1;
|
|
768
|
+
$sm: do
|
|
769
|
+
try {
|
|
770
|
+
var tmp = this.x9_1;
|
|
771
|
+
switch (tmp) {
|
|
772
|
+
case 0:
|
|
773
|
+
this.y9_1 = 2;
|
|
774
|
+
this.x9_1 = 1;
|
|
775
|
+
suspendResult = encodeChunked_0(this.o5q_1, this.p5q_1.a4s_1, this);
|
|
776
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
777
|
+
return suspendResult;
|
|
778
|
+
}
|
|
779
|
+
|
|
780
|
+
continue $sm;
|
|
781
|
+
case 1:
|
|
782
|
+
return Unit_instance;
|
|
783
|
+
case 2:
|
|
784
|
+
throw this.aa_1;
|
|
785
|
+
}
|
|
786
|
+
} catch ($p) {
|
|
787
|
+
var e = $p;
|
|
788
|
+
if (this.y9_1 === 2) {
|
|
789
|
+
throw e;
|
|
790
|
+
} else {
|
|
791
|
+
this.x9_1 = this.y9_1;
|
|
792
|
+
this.aa_1 = e;
|
|
793
|
+
}
|
|
794
|
+
}
|
|
795
|
+
while (true);
|
|
796
|
+
};
|
|
797
|
+
protoOf(encodeChunked$slambda).r5q = function ($this$reader, completion) {
|
|
798
|
+
var i = new encodeChunked$slambda(this.o5q_1, completion);
|
|
799
|
+
i.p5q_1 = $this$reader;
|
|
800
|
+
return i;
|
|
801
|
+
};
|
|
802
|
+
function encodeChunked$slambda_0($output, resultContinuation) {
|
|
803
|
+
var i = new encodeChunked$slambda($output, resultContinuation);
|
|
804
|
+
var l = function ($this$reader, $completion) {
|
|
805
|
+
return i.q5q($this$reader, $completion);
|
|
806
|
+
};
|
|
807
|
+
l.$arity = 1;
|
|
808
|
+
return l;
|
|
809
|
+
}
|
|
810
|
+
function $decodeChunkedCOROUTINE$(input, out, resultContinuation) {
|
|
811
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
812
|
+
this.w5n_1 = input;
|
|
813
|
+
this.x5n_1 = out;
|
|
814
|
+
}
|
|
815
|
+
protoOf($decodeChunkedCOROUTINE$).fa = function () {
|
|
816
|
+
var suspendResult = this.z9_1;
|
|
817
|
+
$sm: do
|
|
818
|
+
try {
|
|
819
|
+
var tmp = this.x9_1;
|
|
820
|
+
switch (tmp) {
|
|
821
|
+
case 0:
|
|
822
|
+
this.y9_1 = 16;
|
|
823
|
+
this.y5n_1 = get_ChunkSizeBufferPool().w4w();
|
|
824
|
+
this.z5n_1 = new Long(0, 0);
|
|
825
|
+
this.x9_1 = 1;
|
|
826
|
+
continue $sm;
|
|
827
|
+
case 1:
|
|
828
|
+
this.y9_1 = 12;
|
|
829
|
+
this.y9_1 = 11;
|
|
830
|
+
this.x9_1 = 2;
|
|
831
|
+
continue $sm;
|
|
832
|
+
case 2:
|
|
833
|
+
this.x9_1 = 3;
|
|
834
|
+
suspendResult = readUTF8LineTo(this.w5n_1, this.y5n_1, 128, get_httpLineEndings(), this);
|
|
835
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
836
|
+
return suspendResult;
|
|
837
|
+
}
|
|
838
|
+
|
|
839
|
+
continue $sm;
|
|
840
|
+
case 3:
|
|
841
|
+
if (!suspendResult) {
|
|
842
|
+
this.x9_1 = 10;
|
|
843
|
+
continue $sm;
|
|
844
|
+
}
|
|
845
|
+
|
|
846
|
+
var this_0 = this.y5n_1;
|
|
847
|
+
if (charSequenceLength(this_0) === 0) {
|
|
848
|
+
throw EOFException_init_$Create$('Invalid chunk size: empty');
|
|
849
|
+
}
|
|
850
|
+
|
|
851
|
+
this.b5o_1 = this.y5n_1.a() === 1 && this.y5n_1.b(0) === _Char___init__impl__6a9atx(48) ? new Long(0, 0) : parseHexLong(this.y5n_1);
|
|
852
|
+
if (this.b5o_1.j1(new Long(0, 0)) > 0) {
|
|
853
|
+
this.x9_1 = 4;
|
|
854
|
+
suspendResult = copyTo(this.w5n_1, this.x5n_1, this.b5o_1, this);
|
|
855
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
856
|
+
return suspendResult;
|
|
857
|
+
}
|
|
858
|
+
continue $sm;
|
|
859
|
+
} else {
|
|
860
|
+
this.x9_1 = 6;
|
|
861
|
+
continue $sm;
|
|
862
|
+
}
|
|
863
|
+
|
|
864
|
+
case 4:
|
|
865
|
+
this.x9_1 = 5;
|
|
866
|
+
suspendResult = this.x5n_1.c4i(this);
|
|
867
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
868
|
+
return suspendResult;
|
|
869
|
+
}
|
|
870
|
+
|
|
871
|
+
continue $sm;
|
|
872
|
+
case 5:
|
|
873
|
+
this.z5n_1 = this.z5n_1.b3(this.b5o_1);
|
|
874
|
+
this.x9_1 = 6;
|
|
875
|
+
continue $sm;
|
|
876
|
+
case 6:
|
|
877
|
+
this.y5n_1.xd();
|
|
878
|
+
this.x9_1 = 7;
|
|
879
|
+
suspendResult = readUTF8LineTo(this.w5n_1, this.y5n_1, 2, get_httpLineEndings(), this);
|
|
880
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
881
|
+
return suspendResult;
|
|
882
|
+
}
|
|
883
|
+
|
|
884
|
+
continue $sm;
|
|
885
|
+
case 7:
|
|
886
|
+
this.c5o_1 = suspendResult;
|
|
887
|
+
if (!this.c5o_1) {
|
|
888
|
+
throw EOFException_init_$Create$('Invalid chunk: content block of size ' + this.b5o_1.toString() + ' ended unexpectedly');
|
|
889
|
+
} else {
|
|
890
|
+
this.x9_1 = 8;
|
|
891
|
+
continue $sm;
|
|
892
|
+
}
|
|
893
|
+
|
|
894
|
+
case 8:
|
|
895
|
+
var this_1 = this.y5n_1;
|
|
896
|
+
if (charSequenceLength(this_1) > 0) {
|
|
897
|
+
throw EOFException_init_$Create$('Invalid chunk: content block should end with CR+LF');
|
|
898
|
+
}
|
|
899
|
+
|
|
900
|
+
if (this.b5o_1.equals(new Long(0, 0))) {
|
|
901
|
+
this.x9_1 = 10;
|
|
902
|
+
continue $sm;
|
|
903
|
+
} else {
|
|
904
|
+
this.x9_1 = 9;
|
|
905
|
+
continue $sm;
|
|
906
|
+
}
|
|
907
|
+
|
|
908
|
+
case 9:
|
|
909
|
+
this.x9_1 = 2;
|
|
910
|
+
continue $sm;
|
|
911
|
+
case 10:
|
|
912
|
+
this.a5o_1 = Unit_instance;
|
|
913
|
+
this.y9_1 = 16;
|
|
914
|
+
this.x9_1 = 14;
|
|
915
|
+
continue $sm;
|
|
916
|
+
case 11:
|
|
917
|
+
this.y9_1 = 12;
|
|
918
|
+
var tmp_0 = this.aa_1;
|
|
919
|
+
if (tmp_0 instanceof Error) {
|
|
920
|
+
this.d5o_1 = this.aa_1;
|
|
921
|
+
var tmp_1 = this;
|
|
922
|
+
close(this.x5n_1, this.d5o_1);
|
|
923
|
+
throw this.d5o_1;
|
|
924
|
+
} else {
|
|
925
|
+
throw this.aa_1;
|
|
926
|
+
}
|
|
927
|
+
|
|
928
|
+
case 12:
|
|
929
|
+
this.y9_1 = 16;
|
|
930
|
+
this.e5o_1 = this.aa_1;
|
|
931
|
+
get_ChunkSizeBufferPool().x4w(this.y5n_1);
|
|
932
|
+
this.x9_1 = 13;
|
|
933
|
+
suspendResult = this.x5n_1.o4i(this);
|
|
934
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
935
|
+
return suspendResult;
|
|
936
|
+
}
|
|
937
|
+
|
|
938
|
+
continue $sm;
|
|
939
|
+
case 13:
|
|
940
|
+
throw this.e5o_1;
|
|
941
|
+
case 14:
|
|
942
|
+
this.y9_1 = 16;
|
|
943
|
+
get_ChunkSizeBufferPool().x4w(this.y5n_1);
|
|
944
|
+
this.x9_1 = 15;
|
|
945
|
+
suspendResult = this.x5n_1.o4i(this);
|
|
946
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
947
|
+
return suspendResult;
|
|
948
|
+
}
|
|
949
|
+
|
|
950
|
+
continue $sm;
|
|
951
|
+
case 15:
|
|
952
|
+
return Unit_instance;
|
|
953
|
+
case 16:
|
|
954
|
+
throw this.aa_1;
|
|
955
|
+
}
|
|
956
|
+
} catch ($p) {
|
|
957
|
+
var e = $p;
|
|
958
|
+
if (this.y9_1 === 16) {
|
|
959
|
+
throw e;
|
|
960
|
+
} else {
|
|
961
|
+
this.x9_1 = this.y9_1;
|
|
962
|
+
this.aa_1 = e;
|
|
963
|
+
}
|
|
964
|
+
}
|
|
965
|
+
while (true);
|
|
966
|
+
};
|
|
967
|
+
function $encodeChunkedCOROUTINE$(output, input, resultContinuation) {
|
|
968
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
969
|
+
this.n5o_1 = output;
|
|
970
|
+
this.o5o_1 = input;
|
|
971
|
+
}
|
|
972
|
+
protoOf($encodeChunkedCOROUTINE$).fa = function () {
|
|
973
|
+
var suspendResult = this.z9_1;
|
|
974
|
+
$sm: do
|
|
975
|
+
try {
|
|
976
|
+
var tmp = this.x9_1;
|
|
977
|
+
switch (tmp) {
|
|
978
|
+
case 0:
|
|
979
|
+
this.y9_1 = 20;
|
|
980
|
+
this.x9_1 = 1;
|
|
981
|
+
continue $sm;
|
|
982
|
+
case 1:
|
|
983
|
+
this.y9_1 = 16;
|
|
984
|
+
this.y9_1 = 15;
|
|
985
|
+
this.x9_1 = 2;
|
|
986
|
+
continue $sm;
|
|
987
|
+
case 2:
|
|
988
|
+
if (!!this.o5o_1.l4i()) {
|
|
989
|
+
this.x9_1 = 13;
|
|
990
|
+
continue $sm;
|
|
991
|
+
}
|
|
992
|
+
|
|
993
|
+
var tmp_0 = this;
|
|
994
|
+
tmp_0.q5o_1 = this.o5o_1;
|
|
995
|
+
this.x9_1 = 3;
|
|
996
|
+
continue $sm;
|
|
997
|
+
case 3:
|
|
998
|
+
this.s5o_1 = this.q5o_1;
|
|
999
|
+
if (this.s5o_1.l4i()) {
|
|
1000
|
+
this.r5o_1 = -1;
|
|
1001
|
+
this.x9_1 = 12;
|
|
1002
|
+
continue $sm;
|
|
1003
|
+
} else {
|
|
1004
|
+
this.x9_1 = 4;
|
|
1005
|
+
continue $sm;
|
|
1006
|
+
}
|
|
1007
|
+
|
|
1008
|
+
case 4:
|
|
1009
|
+
if (this.s5o_1.e4i().r3a()) {
|
|
1010
|
+
this.x9_1 = 5;
|
|
1011
|
+
suspendResult = this.s5o_1.n4i(VOID, this);
|
|
1012
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1013
|
+
return suspendResult;
|
|
1014
|
+
}
|
|
1015
|
+
continue $sm;
|
|
1016
|
+
} else {
|
|
1017
|
+
this.x9_1 = 6;
|
|
1018
|
+
continue $sm;
|
|
1019
|
+
}
|
|
1020
|
+
|
|
1021
|
+
case 5:
|
|
1022
|
+
this.x9_1 = 6;
|
|
1023
|
+
continue $sm;
|
|
1024
|
+
case 6:
|
|
1025
|
+
if (this.s5o_1.l4i()) {
|
|
1026
|
+
this.r5o_1 = -1;
|
|
1027
|
+
this.x9_1 = 12;
|
|
1028
|
+
continue $sm;
|
|
1029
|
+
} else {
|
|
1030
|
+
this.x9_1 = 7;
|
|
1031
|
+
continue $sm;
|
|
1032
|
+
}
|
|
1033
|
+
|
|
1034
|
+
case 7:
|
|
1035
|
+
var tmp_1 = this;
|
|
1036
|
+
tmp_1.u5o_1 = UnsafeBufferOperations_instance;
|
|
1037
|
+
var tmp_2 = this;
|
|
1038
|
+
tmp_2.v5o_1 = this.s5o_1.e4i().q3a();
|
|
1039
|
+
this.w5o_1 = this.u5o_1;
|
|
1040
|
+
this.x5o_1 = this.v5o_1;
|
|
1041
|
+
if (!!this.x5o_1.r3a()) {
|
|
1042
|
+
var message = 'Buffer is empty';
|
|
1043
|
+
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
1044
|
+
}
|
|
1045
|
+
|
|
1046
|
+
this.y5o_1 = ensureNotNull(this.x5o_1.n3a_1);
|
|
1047
|
+
var tmp_3 = this;
|
|
1048
|
+
tmp_3.z5o_1 = this.y5o_1.j3d(true);
|
|
1049
|
+
var tmp_4 = this;
|
|
1050
|
+
tmp_4.a5p_1 = this.y5o_1.w3a_1;
|
|
1051
|
+
var tmp_5 = this;
|
|
1052
|
+
tmp_5.b5p_1 = this.y5o_1.x3a_1;
|
|
1053
|
+
this.c5p_1 = this.z5o_1;
|
|
1054
|
+
this.d5p_1 = this.a5p_1;
|
|
1055
|
+
this.e5p_1 = this.b5p_1;
|
|
1056
|
+
var tmp_6 = this;
|
|
1057
|
+
tmp_6.f5p_1 = this.c5p_1;
|
|
1058
|
+
var tmp_7 = this;
|
|
1059
|
+
tmp_7.g5p_1 = this.d5p_1;
|
|
1060
|
+
var tmp_8 = this;
|
|
1061
|
+
tmp_8.h5p_1 = this.e5p_1;
|
|
1062
|
+
this.x9_1 = 8;
|
|
1063
|
+
continue $sm;
|
|
1064
|
+
case 8:
|
|
1065
|
+
this.j5p_1 = this.f5p_1;
|
|
1066
|
+
this.k5p_1 = this.g5p_1;
|
|
1067
|
+
this.l5p_1 = this.h5p_1;
|
|
1068
|
+
if (this.l5p_1 === this.k5p_1) {
|
|
1069
|
+
this.i5p_1 = 0;
|
|
1070
|
+
this.x9_1 = 11;
|
|
1071
|
+
continue $sm;
|
|
1072
|
+
} else {
|
|
1073
|
+
this.x9_1 = 9;
|
|
1074
|
+
continue $sm;
|
|
1075
|
+
}
|
|
1076
|
+
|
|
1077
|
+
case 9:
|
|
1078
|
+
this.x9_1 = 10;
|
|
1079
|
+
suspendResult = writeChunk(this.n5o_1, this.j5p_1, this.k5p_1, this.l5p_1, this);
|
|
1080
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1081
|
+
return suspendResult;
|
|
1082
|
+
}
|
|
1083
|
+
|
|
1084
|
+
continue $sm;
|
|
1085
|
+
case 10:
|
|
1086
|
+
this.i5p_1 = suspendResult;
|
|
1087
|
+
if (false) {
|
|
1088
|
+
this.x9_1 = 8;
|
|
1089
|
+
continue $sm;
|
|
1090
|
+
}
|
|
1091
|
+
|
|
1092
|
+
this.x9_1 = 11;
|
|
1093
|
+
continue $sm;
|
|
1094
|
+
case 11:
|
|
1095
|
+
this.t5o_1 = this.i5p_1;
|
|
1096
|
+
this.m5p_1 = this.t5o_1;
|
|
1097
|
+
if (!(this.m5p_1 === 0)) {
|
|
1098
|
+
if (this.m5p_1 < 0)
|
|
1099
|
+
throw IllegalStateException_init_$Create$('Returned negative read bytes count');
|
|
1100
|
+
if (this.m5p_1 > this.y5o_1.s())
|
|
1101
|
+
throw IllegalStateException_init_$Create$('Returned too many bytes');
|
|
1102
|
+
this.x5o_1.o3b(toLong(this.m5p_1));
|
|
1103
|
+
}
|
|
1104
|
+
|
|
1105
|
+
this.r5o_1 = this.t5o_1;
|
|
1106
|
+
if (false) {
|
|
1107
|
+
this.x9_1 = 3;
|
|
1108
|
+
continue $sm;
|
|
1109
|
+
}
|
|
1110
|
+
|
|
1111
|
+
this.x9_1 = 12;
|
|
1112
|
+
continue $sm;
|
|
1113
|
+
case 12:
|
|
1114
|
+
this.x9_1 = 2;
|
|
1115
|
+
continue $sm;
|
|
1116
|
+
case 13:
|
|
1117
|
+
rethrowCloseCause(this.o5o_1);
|
|
1118
|
+
this.x9_1 = 14;
|
|
1119
|
+
suspendResult = writeFully(this.n5o_1, get_LastChunkBytes(), VOID, VOID, this);
|
|
1120
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1121
|
+
return suspendResult;
|
|
1122
|
+
}
|
|
1123
|
+
|
|
1124
|
+
continue $sm;
|
|
1125
|
+
case 14:
|
|
1126
|
+
this.p5o_1 = suspendResult;
|
|
1127
|
+
this.y9_1 = 20;
|
|
1128
|
+
this.x9_1 = 18;
|
|
1129
|
+
continue $sm;
|
|
1130
|
+
case 15:
|
|
1131
|
+
this.y9_1 = 16;
|
|
1132
|
+
var tmp_9 = this.aa_1;
|
|
1133
|
+
if (tmp_9 instanceof Error) {
|
|
1134
|
+
this.n5p_1 = this.aa_1;
|
|
1135
|
+
var tmp_10 = this;
|
|
1136
|
+
close(this.n5o_1, this.n5p_1);
|
|
1137
|
+
this.o5o_1.p4i(this.n5p_1);
|
|
1138
|
+
throw this.n5p_1;
|
|
1139
|
+
} else {
|
|
1140
|
+
throw this.aa_1;
|
|
1141
|
+
}
|
|
1142
|
+
|
|
1143
|
+
case 16:
|
|
1144
|
+
this.y9_1 = 20;
|
|
1145
|
+
this.o5p_1 = this.aa_1;
|
|
1146
|
+
this.x9_1 = 17;
|
|
1147
|
+
suspendResult = this.n5o_1.c4i(this);
|
|
1148
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1149
|
+
return suspendResult;
|
|
1150
|
+
}
|
|
1151
|
+
|
|
1152
|
+
continue $sm;
|
|
1153
|
+
case 17:
|
|
1154
|
+
throw this.o5p_1;
|
|
1155
|
+
case 18:
|
|
1156
|
+
this.y9_1 = 20;
|
|
1157
|
+
this.x9_1 = 19;
|
|
1158
|
+
suspendResult = this.n5o_1.c4i(this);
|
|
1159
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1160
|
+
return suspendResult;
|
|
1161
|
+
}
|
|
1162
|
+
|
|
1163
|
+
continue $sm;
|
|
1164
|
+
case 19:
|
|
1165
|
+
return Unit_instance;
|
|
1166
|
+
case 20:
|
|
1167
|
+
throw this.aa_1;
|
|
1168
|
+
}
|
|
1169
|
+
} catch ($p) {
|
|
1170
|
+
var e = $p;
|
|
1171
|
+
if (this.y9_1 === 20) {
|
|
1172
|
+
throw e;
|
|
1173
|
+
} else {
|
|
1174
|
+
this.x9_1 = this.y9_1;
|
|
1175
|
+
this.aa_1 = e;
|
|
1176
|
+
}
|
|
1177
|
+
}
|
|
1178
|
+
while (true);
|
|
1179
|
+
};
|
|
1180
|
+
function $writeChunkCOROUTINE$(_this__u8e3s4, memory, startIndex, endIndex, resultContinuation) {
|
|
1181
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
1182
|
+
this.x5p_1 = _this__u8e3s4;
|
|
1183
|
+
this.y5p_1 = memory;
|
|
1184
|
+
this.z5p_1 = startIndex;
|
|
1185
|
+
this.a5q_1 = endIndex;
|
|
1186
|
+
}
|
|
1187
|
+
protoOf($writeChunkCOROUTINE$).fa = function () {
|
|
1188
|
+
var suspendResult = this.z9_1;
|
|
1189
|
+
$sm: do
|
|
1190
|
+
try {
|
|
1191
|
+
var tmp = this.x9_1;
|
|
1192
|
+
switch (tmp) {
|
|
1193
|
+
case 0:
|
|
1194
|
+
this.y9_1 = 6;
|
|
1195
|
+
this.b5q_1 = this.a5q_1 - this.z5p_1 | 0;
|
|
1196
|
+
this.x9_1 = 1;
|
|
1197
|
+
suspendResult = writeIntHex(this.x5p_1, this.b5q_1, this);
|
|
1198
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1199
|
+
return suspendResult;
|
|
1200
|
+
}
|
|
1201
|
+
|
|
1202
|
+
continue $sm;
|
|
1203
|
+
case 1:
|
|
1204
|
+
this.x9_1 = 2;
|
|
1205
|
+
suspendResult = writeShort(this.x5p_1, 3338, this);
|
|
1206
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1207
|
+
return suspendResult;
|
|
1208
|
+
}
|
|
1209
|
+
|
|
1210
|
+
continue $sm;
|
|
1211
|
+
case 2:
|
|
1212
|
+
this.x9_1 = 3;
|
|
1213
|
+
suspendResult = writeFully(this.x5p_1, this.y5p_1, this.z5p_1, this.a5q_1, this);
|
|
1214
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1215
|
+
return suspendResult;
|
|
1216
|
+
}
|
|
1217
|
+
|
|
1218
|
+
continue $sm;
|
|
1219
|
+
case 3:
|
|
1220
|
+
this.x9_1 = 4;
|
|
1221
|
+
suspendResult = writeFully(this.x5p_1, get_CrLf(), VOID, VOID, this);
|
|
1222
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1223
|
+
return suspendResult;
|
|
1224
|
+
}
|
|
1225
|
+
|
|
1226
|
+
continue $sm;
|
|
1227
|
+
case 4:
|
|
1228
|
+
this.x9_1 = 5;
|
|
1229
|
+
suspendResult = this.x5p_1.c4i(this);
|
|
1230
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1231
|
+
return suspendResult;
|
|
1232
|
+
}
|
|
1233
|
+
|
|
1234
|
+
continue $sm;
|
|
1235
|
+
case 5:
|
|
1236
|
+
return this.b5q_1;
|
|
1237
|
+
case 6:
|
|
1238
|
+
throw this.aa_1;
|
|
1239
|
+
}
|
|
1240
|
+
} catch ($p) {
|
|
1241
|
+
var e = $p;
|
|
1242
|
+
if (this.y9_1 === 6) {
|
|
1243
|
+
throw e;
|
|
1244
|
+
} else {
|
|
1245
|
+
this.x9_1 = this.y9_1;
|
|
1246
|
+
this.aa_1 = e;
|
|
1247
|
+
}
|
|
1248
|
+
}
|
|
1249
|
+
while (true);
|
|
1250
|
+
};
|
|
1251
|
+
var properties_initialized_ChunkedTransferEncoding_kt_x17w8q;
|
|
1252
|
+
function _init_properties_ChunkedTransferEncoding_kt__hi13vs() {
|
|
1253
|
+
if (!properties_initialized_ChunkedTransferEncoding_kt_x17w8q) {
|
|
1254
|
+
properties_initialized_ChunkedTransferEncoding_kt_x17w8q = true;
|
|
1255
|
+
ChunkSizeBufferPool = new ChunkSizeBufferPool$1();
|
|
1256
|
+
CrLf = toByteArray('\r\n');
|
|
1257
|
+
LastChunkBytes = toByteArray('0\r\n\r\n');
|
|
1258
|
+
}
|
|
1259
|
+
}
|
|
1260
|
+
function parseSlow($this, connection) {
|
|
1261
|
+
var idx = 0;
|
|
1262
|
+
var start = 0;
|
|
1263
|
+
var length = charSequenceLength(connection);
|
|
1264
|
+
var connectionOptions = null;
|
|
1265
|
+
var hopHeadersList = null;
|
|
1266
|
+
while (idx < length) {
|
|
1267
|
+
$l$loop: do {
|
|
1268
|
+
var ch = charSequenceGet(connection, idx);
|
|
1269
|
+
if (!(ch === _Char___init__impl__6a9atx(32)) && !(ch === _Char___init__impl__6a9atx(44))) {
|
|
1270
|
+
start = idx;
|
|
1271
|
+
break $l$loop;
|
|
1272
|
+
}
|
|
1273
|
+
idx = idx + 1 | 0;
|
|
1274
|
+
}
|
|
1275
|
+
while (idx < length);
|
|
1276
|
+
$l$loop_0: while (idx < length) {
|
|
1277
|
+
var ch_0 = charSequenceGet(connection, idx);
|
|
1278
|
+
if (ch_0 === _Char___init__impl__6a9atx(32) || ch_0 === _Char___init__impl__6a9atx(44))
|
|
1279
|
+
break $l$loop_0;
|
|
1280
|
+
idx = idx + 1 | 0;
|
|
1281
|
+
}
|
|
1282
|
+
var tmp = start;
|
|
1283
|
+
var tmp_0 = idx;
|
|
1284
|
+
var detected = singleOrNull($this.v5q_1.x5q(connection, tmp, tmp_0, true, ConnectionOptions$Companion$parseSlow$lambda));
|
|
1285
|
+
if (detected == null) {
|
|
1286
|
+
if (hopHeadersList == null) {
|
|
1287
|
+
hopHeadersList = ArrayList_init_$Create$();
|
|
1288
|
+
}
|
|
1289
|
+
var tmp_1 = hopHeadersList;
|
|
1290
|
+
var tmp2 = start;
|
|
1291
|
+
// Inline function 'kotlin.text.substring' call
|
|
1292
|
+
var endIndex = idx;
|
|
1293
|
+
var tmp$ret$0 = toString(charSequenceSubSequence(connection, tmp2, endIndex));
|
|
1294
|
+
tmp_1.h(tmp$ret$0);
|
|
1295
|
+
} else if (connectionOptions == null) {
|
|
1296
|
+
connectionOptions = detected.ri_1;
|
|
1297
|
+
} else {
|
|
1298
|
+
connectionOptions = new ConnectionOptions(connectionOptions.y5q_1 || detected.ri_1.y5q_1, connectionOptions.z5q_1 || detected.ri_1.z5q_1, connectionOptions.a5r_1 || detected.ri_1.a5r_1, emptyList());
|
|
1299
|
+
}
|
|
1300
|
+
}
|
|
1301
|
+
if (connectionOptions == null)
|
|
1302
|
+
connectionOptions = $this.t5q_1;
|
|
1303
|
+
var tmp_2;
|
|
1304
|
+
if (hopHeadersList == null) {
|
|
1305
|
+
tmp_2 = connectionOptions;
|
|
1306
|
+
} else {
|
|
1307
|
+
tmp_2 = new ConnectionOptions(connectionOptions.y5q_1, connectionOptions.z5q_1, connectionOptions.a5r_1, hopHeadersList);
|
|
1308
|
+
}
|
|
1309
|
+
return tmp_2;
|
|
1310
|
+
}
|
|
1311
|
+
function ConnectionOptions$Companion$knownTypes$lambda(it) {
|
|
1312
|
+
return it.qi_1.length;
|
|
1313
|
+
}
|
|
1314
|
+
function ConnectionOptions$Companion$knownTypes$lambda_0(t, idx) {
|
|
1315
|
+
return new Char(charCodeAt(t.qi_1, idx));
|
|
1316
|
+
}
|
|
1317
|
+
function ConnectionOptions$Companion$parse$lambda(_unused_var__etf5q3, _unused_var__etf5q3_0) {
|
|
1318
|
+
return false;
|
|
1319
|
+
}
|
|
1320
|
+
function ConnectionOptions$Companion$parseSlow$lambda(_unused_var__etf5q3, _unused_var__etf5q3_0) {
|
|
1321
|
+
return false;
|
|
1322
|
+
}
|
|
1323
|
+
function Companion() {
|
|
1324
|
+
Companion_instance = this;
|
|
1325
|
+
this.s5q_1 = new ConnectionOptions(true);
|
|
1326
|
+
this.t5q_1 = new ConnectionOptions(VOID, true);
|
|
1327
|
+
this.u5q_1 = new ConnectionOptions(VOID, VOID, true);
|
|
1328
|
+
var tmp = this;
|
|
1329
|
+
var tmp_0 = Companion_instance_0;
|
|
1330
|
+
var tmp_1 = listOf_0([to('close', this.s5q_1), to('keep-alive', this.t5q_1), to('upgrade', this.u5q_1)]);
|
|
1331
|
+
var tmp_2 = ConnectionOptions$Companion$knownTypes$lambda;
|
|
1332
|
+
tmp.v5q_1 = tmp_0.c5r(tmp_1, tmp_2, ConnectionOptions$Companion$knownTypes$lambda_0);
|
|
1333
|
+
}
|
|
1334
|
+
protoOf(Companion).d5r = function (connection) {
|
|
1335
|
+
if (connection == null)
|
|
1336
|
+
return null;
|
|
1337
|
+
var known = this.v5q_1.e5r(connection, VOID, VOID, true, ConnectionOptions$Companion$parse$lambda);
|
|
1338
|
+
if (known.s() === 1)
|
|
1339
|
+
return known.u(0).ri_1;
|
|
1340
|
+
return parseSlow(this, connection);
|
|
1341
|
+
};
|
|
1342
|
+
var Companion_instance;
|
|
1343
|
+
function Companion_getInstance_3() {
|
|
1344
|
+
if (Companion_instance == null)
|
|
1345
|
+
new Companion();
|
|
1346
|
+
return Companion_instance;
|
|
1347
|
+
}
|
|
1348
|
+
function buildToString($this) {
|
|
1349
|
+
// Inline function 'kotlin.text.buildString' call
|
|
1350
|
+
// Inline function 'kotlin.apply' call
|
|
1351
|
+
var this_0 = StringBuilder_init_$Create$_0();
|
|
1352
|
+
var items = ArrayList_init_$Create$_0($this.b5r_1.s() + 3 | 0);
|
|
1353
|
+
if ($this.y5q_1) {
|
|
1354
|
+
items.h('close');
|
|
1355
|
+
}
|
|
1356
|
+
if ($this.z5q_1) {
|
|
1357
|
+
items.h('keep-alive');
|
|
1358
|
+
}
|
|
1359
|
+
if ($this.a5r_1) {
|
|
1360
|
+
items.h('Upgrade');
|
|
1361
|
+
}
|
|
1362
|
+
// Inline function 'kotlin.collections.isNotEmpty' call
|
|
1363
|
+
if (!$this.b5r_1.m()) {
|
|
1364
|
+
items.t($this.b5r_1);
|
|
1365
|
+
}
|
|
1366
|
+
joinTo(items, this_0);
|
|
1367
|
+
return this_0.toString();
|
|
1368
|
+
}
|
|
1369
|
+
function ConnectionOptions(close, keepAlive, upgrade, extraOptions) {
|
|
1370
|
+
Companion_getInstance_3();
|
|
1371
|
+
close = close === VOID ? false : close;
|
|
1372
|
+
keepAlive = keepAlive === VOID ? false : keepAlive;
|
|
1373
|
+
upgrade = upgrade === VOID ? false : upgrade;
|
|
1374
|
+
extraOptions = extraOptions === VOID ? emptyList() : extraOptions;
|
|
1375
|
+
this.y5q_1 = close;
|
|
1376
|
+
this.z5q_1 = keepAlive;
|
|
1377
|
+
this.a5r_1 = upgrade;
|
|
1378
|
+
this.b5r_1 = extraOptions;
|
|
1379
|
+
}
|
|
1380
|
+
protoOf(ConnectionOptions).toString = function () {
|
|
1381
|
+
var tmp;
|
|
1382
|
+
if (this.b5r_1.m()) {
|
|
1383
|
+
tmp = this.y5q_1 && !this.z5q_1 && !this.a5r_1 ? 'close' : !this.y5q_1 && this.z5q_1 && !this.a5r_1 ? 'keep-alive' : !this.y5q_1 && this.z5q_1 && this.a5r_1 ? 'keep-alive, Upgrade' : buildToString(this);
|
|
1384
|
+
} else {
|
|
1385
|
+
tmp = buildToString(this);
|
|
1386
|
+
}
|
|
1387
|
+
return tmp;
|
|
1388
|
+
};
|
|
1389
|
+
protoOf(ConnectionOptions).equals = function (other) {
|
|
1390
|
+
if (this === other)
|
|
1391
|
+
return true;
|
|
1392
|
+
if (other == null || !getKClassFromExpression(this).equals(getKClassFromExpression(other)))
|
|
1393
|
+
return false;
|
|
1394
|
+
if (!(other instanceof ConnectionOptions))
|
|
1395
|
+
THROW_CCE();
|
|
1396
|
+
if (!(this.y5q_1 === other.y5q_1))
|
|
1397
|
+
return false;
|
|
1398
|
+
if (!(this.z5q_1 === other.z5q_1))
|
|
1399
|
+
return false;
|
|
1400
|
+
if (!(this.a5r_1 === other.a5r_1))
|
|
1401
|
+
return false;
|
|
1402
|
+
if (!equals(this.b5r_1, other.b5r_1))
|
|
1403
|
+
return false;
|
|
1404
|
+
return true;
|
|
1405
|
+
};
|
|
1406
|
+
protoOf(ConnectionOptions).hashCode = function () {
|
|
1407
|
+
var result = getBooleanHashCode(this.y5q_1);
|
|
1408
|
+
result = imul(31, result) + getBooleanHashCode(this.z5q_1) | 0;
|
|
1409
|
+
result = imul(31, result) + getBooleanHashCode(this.a5r_1) | 0;
|
|
1410
|
+
result = imul(31, result) + hashCode(this.b5r_1) | 0;
|
|
1411
|
+
return result;
|
|
1412
|
+
};
|
|
1413
|
+
function expectHttpBody(method, contentLength, transferEncoding, connectionOptions, contentType) {
|
|
1414
|
+
if (!(transferEncoding == null)) {
|
|
1415
|
+
isTransferEncodingChunked(transferEncoding);
|
|
1416
|
+
return true;
|
|
1417
|
+
}
|
|
1418
|
+
if (!contentLength.equals(new Long(-1, -1)))
|
|
1419
|
+
return contentLength.j1(new Long(0, 0)) > 0;
|
|
1420
|
+
if (method.equals(Companion_getInstance_0().l5d_1) || method.equals(Companion_getInstance_0().q5d_1) || method.equals(Companion_getInstance_0().r5d_1))
|
|
1421
|
+
return false;
|
|
1422
|
+
if ((connectionOptions == null ? null : connectionOptions.y5q_1) === true)
|
|
1423
|
+
return true;
|
|
1424
|
+
return false;
|
|
1425
|
+
}
|
|
1426
|
+
function expectHttpUpgrade(method, upgrade, connectionOptions) {
|
|
1427
|
+
var tmp;
|
|
1428
|
+
if (method.equals(Companion_getInstance_0().l5d_1) && !(upgrade == null)) {
|
|
1429
|
+
tmp = (connectionOptions == null ? null : connectionOptions.a5r_1) === true;
|
|
1430
|
+
} else {
|
|
1431
|
+
tmp = false;
|
|
1432
|
+
}
|
|
1433
|
+
return tmp;
|
|
1434
|
+
}
|
|
1435
|
+
function parseHttpBody(version, contentLength, transferEncoding, connectionOptions, input, out, $completion) {
|
|
1436
|
+
var tmp = new $parseHttpBodyCOROUTINE$(version, contentLength, transferEncoding, connectionOptions, input, out, $completion);
|
|
1437
|
+
tmp.z9_1 = Unit_instance;
|
|
1438
|
+
tmp.aa_1 = null;
|
|
1439
|
+
return tmp.fa();
|
|
1440
|
+
}
|
|
1441
|
+
function isTransferEncodingChunked(transferEncoding) {
|
|
1442
|
+
if (equalsLowerCase(transferEncoding, VOID, VOID, 'chunked')) {
|
|
1443
|
+
return true;
|
|
1444
|
+
}
|
|
1445
|
+
if (equalsLowerCase(transferEncoding, VOID, VOID, 'identity')) {
|
|
1446
|
+
return false;
|
|
1447
|
+
}
|
|
1448
|
+
var chunked = false;
|
|
1449
|
+
// Inline function 'kotlin.collections.forEach' call
|
|
1450
|
+
var _iterator__ex2g4s = split(transferEncoding, [',']).p();
|
|
1451
|
+
while (_iterator__ex2g4s.q()) {
|
|
1452
|
+
var element = _iterator__ex2g4s.r();
|
|
1453
|
+
// Inline function 'kotlin.text.trim' call
|
|
1454
|
+
// Inline function 'kotlin.text.lowercase' call
|
|
1455
|
+
// Inline function 'kotlin.js.asDynamic' call
|
|
1456
|
+
var name = toString(trim(isCharSequence(element) ? element : THROW_CCE())).toLowerCase();
|
|
1457
|
+
switch (name) {
|
|
1458
|
+
case 'chunked':
|
|
1459
|
+
if (chunked) {
|
|
1460
|
+
throw IllegalArgumentException_init_$Create$('Double-chunked TE is not supported: ' + toString(transferEncoding));
|
|
1461
|
+
}
|
|
1462
|
+
|
|
1463
|
+
chunked = true;
|
|
1464
|
+
break;
|
|
1465
|
+
case 'identity':
|
|
1466
|
+
break;
|
|
1467
|
+
default:
|
|
1468
|
+
throw IllegalArgumentException_init_$Create$('Unsupported transfer encoding ' + name);
|
|
1469
|
+
}
|
|
1470
|
+
}
|
|
1471
|
+
return chunked;
|
|
1472
|
+
}
|
|
1473
|
+
function $parseHttpBodyCOROUTINE$(version, contentLength, transferEncoding, connectionOptions, input, out, resultContinuation) {
|
|
1474
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
1475
|
+
this.n5r_1 = version;
|
|
1476
|
+
this.o5r_1 = contentLength;
|
|
1477
|
+
this.p5r_1 = transferEncoding;
|
|
1478
|
+
this.q5r_1 = connectionOptions;
|
|
1479
|
+
this.r5r_1 = input;
|
|
1480
|
+
this.s5r_1 = out;
|
|
1481
|
+
}
|
|
1482
|
+
protoOf($parseHttpBodyCOROUTINE$).fa = function () {
|
|
1483
|
+
var suspendResult = this.z9_1;
|
|
1484
|
+
$sm: do
|
|
1485
|
+
try {
|
|
1486
|
+
var tmp = this.x9_1;
|
|
1487
|
+
switch (tmp) {
|
|
1488
|
+
case 0:
|
|
1489
|
+
this.y9_1 = 7;
|
|
1490
|
+
if (!(this.p5r_1 == null) && isTransferEncodingChunked(this.p5r_1)) {
|
|
1491
|
+
this.x9_1 = 6;
|
|
1492
|
+
suspendResult = decodeChunked(this.r5r_1, this.s5r_1, this);
|
|
1493
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1494
|
+
return suspendResult;
|
|
1495
|
+
}
|
|
1496
|
+
continue $sm;
|
|
1497
|
+
} else {
|
|
1498
|
+
this.x9_1 = 1;
|
|
1499
|
+
continue $sm;
|
|
1500
|
+
}
|
|
1501
|
+
|
|
1502
|
+
case 1:
|
|
1503
|
+
if (!this.o5r_1.equals(new Long(-1, -1))) {
|
|
1504
|
+
this.x9_1 = 5;
|
|
1505
|
+
suspendResult = copyTo(this.r5r_1, this.s5r_1, this.o5r_1, this);
|
|
1506
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1507
|
+
return suspendResult;
|
|
1508
|
+
}
|
|
1509
|
+
continue $sm;
|
|
1510
|
+
} else {
|
|
1511
|
+
this.x9_1 = 2;
|
|
1512
|
+
continue $sm;
|
|
1513
|
+
}
|
|
1514
|
+
|
|
1515
|
+
case 2:
|
|
1516
|
+
var tmp_0;
|
|
1517
|
+
var tmp0_safe_receiver = this.q5r_1;
|
|
1518
|
+
if ((tmp0_safe_receiver == null ? null : tmp0_safe_receiver.y5q_1) === true) {
|
|
1519
|
+
tmp_0 = true;
|
|
1520
|
+
} else {
|
|
1521
|
+
tmp_0 = (this.q5r_1 == null && equals(this.n5r_1, Companion_getInstance_1().x5d_1));
|
|
1522
|
+
}
|
|
1523
|
+
|
|
1524
|
+
if (tmp_0) {
|
|
1525
|
+
this.x9_1 = 4;
|
|
1526
|
+
suspendResult = copyTo(this.r5r_1, this.s5r_1, new Long(-1, 2147483647), this);
|
|
1527
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1528
|
+
return suspendResult;
|
|
1529
|
+
}
|
|
1530
|
+
continue $sm;
|
|
1531
|
+
} else {
|
|
1532
|
+
this.x9_1 = 3;
|
|
1533
|
+
continue $sm;
|
|
1534
|
+
}
|
|
1535
|
+
|
|
1536
|
+
case 3:
|
|
1537
|
+
var cause = IllegalStateException_init_$Create$('Failed to parse request body: request body length should be specified,\nchunked transfer encoding should be used or\nkeep-alive should be disabled (connection: close)');
|
|
1538
|
+
close(this.s5r_1, cause);
|
|
1539
|
+
return Unit_instance;
|
|
1540
|
+
case 4:
|
|
1541
|
+
return Unit_instance;
|
|
1542
|
+
case 5:
|
|
1543
|
+
return Unit_instance;
|
|
1544
|
+
case 6:
|
|
1545
|
+
return Unit_instance;
|
|
1546
|
+
case 7:
|
|
1547
|
+
throw this.aa_1;
|
|
1548
|
+
}
|
|
1549
|
+
} catch ($p) {
|
|
1550
|
+
var e = $p;
|
|
1551
|
+
if (this.y9_1 === 7) {
|
|
1552
|
+
throw e;
|
|
1553
|
+
} else {
|
|
1554
|
+
this.x9_1 = this.y9_1;
|
|
1555
|
+
this.aa_1 = e;
|
|
1556
|
+
}
|
|
1557
|
+
}
|
|
1558
|
+
while (true);
|
|
1559
|
+
};
|
|
1560
|
+
function get_IntArrayPool() {
|
|
1561
|
+
_init_properties_HttpHeadersMap_kt__hwatby();
|
|
1562
|
+
return IntArrayPool;
|
|
1563
|
+
}
|
|
1564
|
+
var IntArrayPool;
|
|
1565
|
+
function get_HeadersDataPool() {
|
|
1566
|
+
_init_properties_HttpHeadersMap_kt__hwatby();
|
|
1567
|
+
return HeadersDataPool;
|
|
1568
|
+
}
|
|
1569
|
+
var HeadersDataPool;
|
|
1570
|
+
function HeadersData$headersStarts$slambda(this$0, resultContinuation) {
|
|
1571
|
+
this.b5s_1 = this$0;
|
|
1572
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
1573
|
+
}
|
|
1574
|
+
protoOf(HeadersData$headersStarts$slambda).h5s = function ($this$sequence, $completion) {
|
|
1575
|
+
var tmp = this.i5s($this$sequence, $completion);
|
|
1576
|
+
tmp.z9_1 = Unit_instance;
|
|
1577
|
+
tmp.aa_1 = null;
|
|
1578
|
+
return tmp.fa();
|
|
1579
|
+
};
|
|
1580
|
+
protoOf(HeadersData$headersStarts$slambda).ra = function (p1, $completion) {
|
|
1581
|
+
return this.h5s(p1 instanceof SequenceScope ? p1 : THROW_CCE(), $completion);
|
|
1582
|
+
};
|
|
1583
|
+
protoOf(HeadersData$headersStarts$slambda).fa = function () {
|
|
1584
|
+
var suspendResult = this.z9_1;
|
|
1585
|
+
$sm: do
|
|
1586
|
+
try {
|
|
1587
|
+
var tmp = this.x9_1;
|
|
1588
|
+
switch (tmp) {
|
|
1589
|
+
case 0:
|
|
1590
|
+
this.y9_1 = 7;
|
|
1591
|
+
this.d5s_1 = 0;
|
|
1592
|
+
this.e5s_1 = this.b5s_1.j5s_1.p();
|
|
1593
|
+
this.x9_1 = 1;
|
|
1594
|
+
continue $sm;
|
|
1595
|
+
case 1:
|
|
1596
|
+
if (!this.e5s_1.q()) {
|
|
1597
|
+
this.x9_1 = 6;
|
|
1598
|
+
continue $sm;
|
|
1599
|
+
}
|
|
1600
|
+
|
|
1601
|
+
this.f5s_1 = this.e5s_1.r();
|
|
1602
|
+
this.g5s_1 = 0;
|
|
1603
|
+
this.x9_1 = 2;
|
|
1604
|
+
continue $sm;
|
|
1605
|
+
case 2:
|
|
1606
|
+
if (!(this.g5s_1 < this.f5s_1.length)) {
|
|
1607
|
+
this.x9_1 = 5;
|
|
1608
|
+
continue $sm;
|
|
1609
|
+
}
|
|
1610
|
+
|
|
1611
|
+
if (!(this.b5s_1.k5s(this.d5s_1 + 0 | 0) === -1)) {
|
|
1612
|
+
this.x9_1 = 3;
|
|
1613
|
+
suspendResult = this.c5s_1.ej(this.d5s_1, this);
|
|
1614
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1615
|
+
return suspendResult;
|
|
1616
|
+
}
|
|
1617
|
+
continue $sm;
|
|
1618
|
+
} else {
|
|
1619
|
+
this.x9_1 = 4;
|
|
1620
|
+
continue $sm;
|
|
1621
|
+
}
|
|
1622
|
+
|
|
1623
|
+
case 3:
|
|
1624
|
+
this.x9_1 = 4;
|
|
1625
|
+
continue $sm;
|
|
1626
|
+
case 4:
|
|
1627
|
+
this.g5s_1 = this.g5s_1 + 6 | 0;
|
|
1628
|
+
this.d5s_1 = this.d5s_1 + 6 | 0;
|
|
1629
|
+
this.x9_1 = 2;
|
|
1630
|
+
continue $sm;
|
|
1631
|
+
case 5:
|
|
1632
|
+
this.x9_1 = 1;
|
|
1633
|
+
continue $sm;
|
|
1634
|
+
case 6:
|
|
1635
|
+
return Unit_instance;
|
|
1636
|
+
case 7:
|
|
1637
|
+
throw this.aa_1;
|
|
1638
|
+
}
|
|
1639
|
+
} catch ($p) {
|
|
1640
|
+
var e = $p;
|
|
1641
|
+
if (this.y9_1 === 7) {
|
|
1642
|
+
throw e;
|
|
1643
|
+
} else {
|
|
1644
|
+
this.x9_1 = this.y9_1;
|
|
1645
|
+
this.aa_1 = e;
|
|
1646
|
+
}
|
|
1647
|
+
}
|
|
1648
|
+
while (true);
|
|
1649
|
+
};
|
|
1650
|
+
protoOf(HeadersData$headersStarts$slambda).i5s = function ($this$sequence, completion) {
|
|
1651
|
+
var i = new HeadersData$headersStarts$slambda(this.b5s_1, completion);
|
|
1652
|
+
i.c5s_1 = $this$sequence;
|
|
1653
|
+
return i;
|
|
1654
|
+
};
|
|
1655
|
+
function HeadersData$headersStarts$slambda_0(this$0, resultContinuation) {
|
|
1656
|
+
var i = new HeadersData$headersStarts$slambda(this$0, resultContinuation);
|
|
1657
|
+
var l = function ($this$sequence, $completion) {
|
|
1658
|
+
return i.h5s($this$sequence, $completion);
|
|
1659
|
+
};
|
|
1660
|
+
l.$arity = 1;
|
|
1661
|
+
return l;
|
|
1662
|
+
}
|
|
1663
|
+
function HeadersData() {
|
|
1664
|
+
var tmp = this;
|
|
1665
|
+
// Inline function 'kotlin.collections.mutableListOf' call
|
|
1666
|
+
tmp.j5s_1 = ArrayList_init_$Create$();
|
|
1667
|
+
}
|
|
1668
|
+
protoOf(HeadersData).l5s = function () {
|
|
1669
|
+
return this.j5s_1.s();
|
|
1670
|
+
};
|
|
1671
|
+
protoOf(HeadersData).m5s = function (subArraysCount) {
|
|
1672
|
+
// Inline function 'kotlin.repeat' call
|
|
1673
|
+
var inductionVariable = 0;
|
|
1674
|
+
if (inductionVariable < subArraysCount)
|
|
1675
|
+
do {
|
|
1676
|
+
var index = inductionVariable;
|
|
1677
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
1678
|
+
this.j5s_1.h(get_IntArrayPool().w4w());
|
|
1679
|
+
}
|
|
1680
|
+
while (inductionVariable < subArraysCount);
|
|
1681
|
+
};
|
|
1682
|
+
protoOf(HeadersData).k5s = function (index) {
|
|
1683
|
+
return this.j5s_1.u(index / 768 | 0)[index % 768 | 0];
|
|
1684
|
+
};
|
|
1685
|
+
protoOf(HeadersData).n5s = function (index, value) {
|
|
1686
|
+
this.j5s_1.u(index / 768 | 0)[index % 768 | 0] = value;
|
|
1687
|
+
};
|
|
1688
|
+
protoOf(HeadersData).o5s = function () {
|
|
1689
|
+
return sequence(HeadersData$headersStarts$slambda_0(this, null));
|
|
1690
|
+
};
|
|
1691
|
+
protoOf(HeadersData).m1h = function () {
|
|
1692
|
+
var _iterator__ex2g4s = this.j5s_1.p();
|
|
1693
|
+
while (_iterator__ex2g4s.q()) {
|
|
1694
|
+
var array = _iterator__ex2g4s.r();
|
|
1695
|
+
get_IntArrayPool().x4w(array);
|
|
1696
|
+
}
|
|
1697
|
+
this.j5s_1.n2();
|
|
1698
|
+
};
|
|
1699
|
+
function thresholdReached($this) {
|
|
1700
|
+
return $this.f5l_1 >= $this.g5l_1 * 0.75;
|
|
1701
|
+
}
|
|
1702
|
+
function resize($this) {
|
|
1703
|
+
var prevSize = $this.f5l_1;
|
|
1704
|
+
var prevData = $this.h5l_1;
|
|
1705
|
+
$this.f5l_1 = 0;
|
|
1706
|
+
$this.g5l_1 = imul($this.g5l_1, 2) | 128;
|
|
1707
|
+
var tmp = $this;
|
|
1708
|
+
// Inline function 'kotlin.apply' call
|
|
1709
|
+
var this_0 = get_HeadersDataPool().w4w();
|
|
1710
|
+
this_0.m5s(imul(prevData.l5s(), 2) | 1);
|
|
1711
|
+
tmp.h5l_1 = this_0;
|
|
1712
|
+
var _iterator__ex2g4s = prevData.o5s().p();
|
|
1713
|
+
while (_iterator__ex2g4s.q()) {
|
|
1714
|
+
var headerOffset = _iterator__ex2g4s.r();
|
|
1715
|
+
$this.p5s(prevData.k5s(headerOffset + 1 | 0), prevData.k5s(headerOffset + 2 | 0), prevData.k5s(headerOffset + 3 | 0), prevData.k5s(headerOffset + 4 | 0));
|
|
1716
|
+
}
|
|
1717
|
+
get_HeadersDataPool().x4w(prevData);
|
|
1718
|
+
// Inline function 'kotlin.require' call
|
|
1719
|
+
// Inline function 'kotlin.require' call
|
|
1720
|
+
if (!(prevSize === $this.f5l_1)) {
|
|
1721
|
+
var message = 'Failed requirement.';
|
|
1722
|
+
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
1723
|
+
}
|
|
1724
|
+
}
|
|
1725
|
+
function headerHasName($this, name, headerOffset) {
|
|
1726
|
+
var nameStartIndex = $this.h5l_1.k5s(headerOffset + 1 | 0);
|
|
1727
|
+
var nameEndIndex = $this.h5l_1.k5s(headerOffset + 2 | 0);
|
|
1728
|
+
return equalsLowerCase($this.e5l_1, nameStartIndex, nameEndIndex, name);
|
|
1729
|
+
}
|
|
1730
|
+
function HttpHeadersMap$getAll$slambda(this$0, $name, resultContinuation) {
|
|
1731
|
+
this.y5s_1 = this$0;
|
|
1732
|
+
this.z5s_1 = $name;
|
|
1733
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
1734
|
+
}
|
|
1735
|
+
protoOf(HttpHeadersMap$getAll$slambda).d5t = function ($this$sequence, $completion) {
|
|
1736
|
+
var tmp = this.e5t($this$sequence, $completion);
|
|
1737
|
+
tmp.z9_1 = Unit_instance;
|
|
1738
|
+
tmp.aa_1 = null;
|
|
1739
|
+
return tmp.fa();
|
|
1740
|
+
};
|
|
1741
|
+
protoOf(HttpHeadersMap$getAll$slambda).ra = function (p1, $completion) {
|
|
1742
|
+
return this.d5t(p1 instanceof SequenceScope ? p1 : THROW_CCE(), $completion);
|
|
1743
|
+
};
|
|
1744
|
+
protoOf(HttpHeadersMap$getAll$slambda).fa = function () {
|
|
1745
|
+
var suspendResult = this.z9_1;
|
|
1746
|
+
$sm: do
|
|
1747
|
+
try {
|
|
1748
|
+
var tmp = this.x9_1;
|
|
1749
|
+
switch (tmp) {
|
|
1750
|
+
case 0:
|
|
1751
|
+
this.y9_1 = 6;
|
|
1752
|
+
if (this.y5s_1.f5l_1 === 0)
|
|
1753
|
+
return Unit_instance;
|
|
1754
|
+
var tmp_0 = this;
|
|
1755
|
+
var this_0 = hashCodeLowerCase(this.z5s_1);
|
|
1756
|
+
tmp_0.b5t_1 = abs(this_0);
|
|
1757
|
+
this.c5t_1 = this.b5t_1 % this.y5s_1.g5l_1 | 0;
|
|
1758
|
+
this.x9_1 = 1;
|
|
1759
|
+
continue $sm;
|
|
1760
|
+
case 1:
|
|
1761
|
+
if (!!(this.y5s_1.h5l_1.k5s(imul(this.c5t_1, 6) + 0 | 0) === -1)) {
|
|
1762
|
+
this.x9_1 = 5;
|
|
1763
|
+
continue $sm;
|
|
1764
|
+
}
|
|
1765
|
+
|
|
1766
|
+
if (headerHasName(this.y5s_1, this.z5s_1, imul(this.c5t_1, 6))) {
|
|
1767
|
+
this.x9_1 = 3;
|
|
1768
|
+
suspendResult = this.a5t_1.ej(this.y5s_1.j5l(imul(this.c5t_1, 6)), this);
|
|
1769
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1770
|
+
return suspendResult;
|
|
1771
|
+
}
|
|
1772
|
+
continue $sm;
|
|
1773
|
+
} else {
|
|
1774
|
+
this.x9_1 = 2;
|
|
1775
|
+
continue $sm;
|
|
1776
|
+
}
|
|
1777
|
+
|
|
1778
|
+
case 2:
|
|
1779
|
+
this.c5t_1 = (this.c5t_1 + 1 | 0) % this.y5s_1.g5l_1 | 0;
|
|
1780
|
+
this.x9_1 = 1;
|
|
1781
|
+
continue $sm;
|
|
1782
|
+
case 3:
|
|
1783
|
+
var nextHeaderIndex = this.y5s_1.h5l_1.k5s(imul(this.c5t_1, 6) + 5 | 0);
|
|
1784
|
+
if (nextHeaderIndex === -1) {
|
|
1785
|
+
this.x9_1 = 5;
|
|
1786
|
+
continue $sm;
|
|
1787
|
+
} else {
|
|
1788
|
+
this.x9_1 = 4;
|
|
1789
|
+
continue $sm;
|
|
1790
|
+
}
|
|
1791
|
+
|
|
1792
|
+
case 4:
|
|
1793
|
+
this.c5t_1 = nextHeaderIndex;
|
|
1794
|
+
this.x9_1 = 1;
|
|
1795
|
+
continue $sm;
|
|
1796
|
+
case 5:
|
|
1797
|
+
return Unit_instance;
|
|
1798
|
+
case 6:
|
|
1799
|
+
throw this.aa_1;
|
|
1800
|
+
}
|
|
1801
|
+
} catch ($p) {
|
|
1802
|
+
var e = $p;
|
|
1803
|
+
if (this.y9_1 === 6) {
|
|
1804
|
+
throw e;
|
|
1805
|
+
} else {
|
|
1806
|
+
this.x9_1 = this.y9_1;
|
|
1807
|
+
this.aa_1 = e;
|
|
1808
|
+
}
|
|
1809
|
+
}
|
|
1810
|
+
while (true);
|
|
1811
|
+
};
|
|
1812
|
+
protoOf(HttpHeadersMap$getAll$slambda).e5t = function ($this$sequence, completion) {
|
|
1813
|
+
var i = new HttpHeadersMap$getAll$slambda(this.y5s_1, this.z5s_1, completion);
|
|
1814
|
+
i.a5t_1 = $this$sequence;
|
|
1815
|
+
return i;
|
|
1816
|
+
};
|
|
1817
|
+
function HttpHeadersMap$getAll$slambda_0(this$0, $name, resultContinuation) {
|
|
1818
|
+
var i = new HttpHeadersMap$getAll$slambda(this$0, $name, resultContinuation);
|
|
1819
|
+
var l = function ($this$sequence, $completion) {
|
|
1820
|
+
return i.d5t($this$sequence, $completion);
|
|
1821
|
+
};
|
|
1822
|
+
l.$arity = 1;
|
|
1823
|
+
return l;
|
|
1824
|
+
}
|
|
1825
|
+
function HttpHeadersMap(builder) {
|
|
1826
|
+
this.e5l_1 = builder;
|
|
1827
|
+
this.f5l_1 = 0;
|
|
1828
|
+
this.g5l_1 = 0;
|
|
1829
|
+
this.h5l_1 = get_HeadersDataPool().w4w();
|
|
1830
|
+
}
|
|
1831
|
+
protoOf(HttpHeadersMap).cf = function (name) {
|
|
1832
|
+
if (this.f5l_1 === 0)
|
|
1833
|
+
return null;
|
|
1834
|
+
// Inline function 'kotlin.math.absoluteValue' call
|
|
1835
|
+
var this_0 = hashCodeLowerCase(name);
|
|
1836
|
+
var hash = abs(this_0);
|
|
1837
|
+
var headerIndex = hash % this.g5l_1 | 0;
|
|
1838
|
+
while (!(this.h5l_1.k5s(imul(headerIndex, 6) + 0 | 0) === -1)) {
|
|
1839
|
+
if (headerHasName(this, name, imul(headerIndex, 6))) {
|
|
1840
|
+
return this.j5l(imul(headerIndex, 6));
|
|
1841
|
+
}
|
|
1842
|
+
headerIndex = (headerIndex + 1 | 0) % this.g5l_1 | 0;
|
|
1843
|
+
}
|
|
1844
|
+
return null;
|
|
1845
|
+
};
|
|
1846
|
+
protoOf(HttpHeadersMap).b4z = function (name) {
|
|
1847
|
+
return sequence(HttpHeadersMap$getAll$slambda_0(this, name, null));
|
|
1848
|
+
};
|
|
1849
|
+
protoOf(HttpHeadersMap).k5l = function () {
|
|
1850
|
+
return this.h5l_1.o5s();
|
|
1851
|
+
};
|
|
1852
|
+
protoOf(HttpHeadersMap).p5s = function (nameStartIndex, nameEndIndex, valueStartIndex, valueEndIndex) {
|
|
1853
|
+
if (thresholdReached(this)) {
|
|
1854
|
+
resize(this);
|
|
1855
|
+
}
|
|
1856
|
+
// Inline function 'kotlin.math.absoluteValue' call
|
|
1857
|
+
var this_0 = hashCodeLowerCase(this.e5l_1, nameStartIndex, nameEndIndex);
|
|
1858
|
+
var hash = abs(this_0);
|
|
1859
|
+
var name = this.e5l_1.c(nameStartIndex, nameEndIndex);
|
|
1860
|
+
var headerIndex = hash % this.g5l_1 | 0;
|
|
1861
|
+
var sameNameHeaderIndex = -1;
|
|
1862
|
+
while (!(this.h5l_1.k5s(imul(headerIndex, 6) + 0 | 0) === -1)) {
|
|
1863
|
+
if (headerHasName(this, name, imul(headerIndex, 6))) {
|
|
1864
|
+
sameNameHeaderIndex = headerIndex;
|
|
1865
|
+
}
|
|
1866
|
+
headerIndex = (headerIndex + 1 | 0) % this.g5l_1 | 0;
|
|
1867
|
+
}
|
|
1868
|
+
var headerOffset = imul(headerIndex, 6);
|
|
1869
|
+
this.h5l_1.n5s(headerOffset + 0 | 0, hash);
|
|
1870
|
+
this.h5l_1.n5s(headerOffset + 1 | 0, nameStartIndex);
|
|
1871
|
+
this.h5l_1.n5s(headerOffset + 2 | 0, nameEndIndex);
|
|
1872
|
+
this.h5l_1.n5s(headerOffset + 3 | 0, valueStartIndex);
|
|
1873
|
+
this.h5l_1.n5s(headerOffset + 4 | 0, valueEndIndex);
|
|
1874
|
+
this.h5l_1.n5s(headerOffset + 5 | 0, -1);
|
|
1875
|
+
if (!(sameNameHeaderIndex === -1)) {
|
|
1876
|
+
this.h5l_1.n5s(imul(sameNameHeaderIndex, 6) + 5 | 0, headerIndex);
|
|
1877
|
+
}
|
|
1878
|
+
this.f5l_1 = this.f5l_1 + 1 | 0;
|
|
1879
|
+
};
|
|
1880
|
+
protoOf(HttpHeadersMap).i5l = function (headerOffset) {
|
|
1881
|
+
var nameStartIndex = this.h5l_1.k5s(headerOffset + 1 | 0);
|
|
1882
|
+
var nameEndIndex = this.h5l_1.k5s(headerOffset + 2 | 0);
|
|
1883
|
+
return this.e5l_1.c(nameStartIndex, nameEndIndex);
|
|
1884
|
+
};
|
|
1885
|
+
protoOf(HttpHeadersMap).j5l = function (headerOffset) {
|
|
1886
|
+
var valueStartIndex = this.h5l_1.k5s(headerOffset + 3 | 0);
|
|
1887
|
+
var valueEndIndex = this.h5l_1.k5s(headerOffset + 4 | 0);
|
|
1888
|
+
return this.e5l_1.c(valueStartIndex, valueEndIndex);
|
|
1889
|
+
};
|
|
1890
|
+
protoOf(HttpHeadersMap).m1h = function () {
|
|
1891
|
+
this.f5l_1 = 0;
|
|
1892
|
+
this.g5l_1 = 0;
|
|
1893
|
+
get_HeadersDataPool().x4w(this.h5l_1);
|
|
1894
|
+
this.h5l_1 = get_HeadersDataPool().w4w();
|
|
1895
|
+
};
|
|
1896
|
+
protoOf(HttpHeadersMap).toString = function () {
|
|
1897
|
+
// Inline function 'kotlin.text.buildString' call
|
|
1898
|
+
// Inline function 'kotlin.apply' call
|
|
1899
|
+
var this_0 = StringBuilder_init_$Create$_0();
|
|
1900
|
+
dumpTo(this, '', this_0);
|
|
1901
|
+
return this_0.toString();
|
|
1902
|
+
};
|
|
1903
|
+
function dumpTo(_this__u8e3s4, indent, out) {
|
|
1904
|
+
_init_properties_HttpHeadersMap_kt__hwatby();
|
|
1905
|
+
var _iterator__ex2g4s = _this__u8e3s4.k5l().p();
|
|
1906
|
+
while (_iterator__ex2g4s.q()) {
|
|
1907
|
+
var offset = _iterator__ex2g4s.r();
|
|
1908
|
+
out.i(indent);
|
|
1909
|
+
out.i(_this__u8e3s4.i5l(offset));
|
|
1910
|
+
out.i(' => ');
|
|
1911
|
+
out.i(_this__u8e3s4.j5l(offset));
|
|
1912
|
+
out.i('\n');
|
|
1913
|
+
}
|
|
1914
|
+
}
|
|
1915
|
+
function IntArrayPool$1() {
|
|
1916
|
+
DefaultPool.call(this, 1000);
|
|
1917
|
+
}
|
|
1918
|
+
protoOf(IntArrayPool$1).p4w = function () {
|
|
1919
|
+
var tmp = 0;
|
|
1920
|
+
var tmp_0 = new Int32Array(768);
|
|
1921
|
+
while (tmp < 768) {
|
|
1922
|
+
tmp_0[tmp] = -1;
|
|
1923
|
+
tmp = tmp + 1 | 0;
|
|
1924
|
+
}
|
|
1925
|
+
return tmp_0;
|
|
1926
|
+
};
|
|
1927
|
+
protoOf(IntArrayPool$1).p5t = function (instance) {
|
|
1928
|
+
fill(instance, -1);
|
|
1929
|
+
return protoOf(DefaultPool).u4w.call(this, instance);
|
|
1930
|
+
};
|
|
1931
|
+
protoOf(IntArrayPool$1).u4w = function (instance) {
|
|
1932
|
+
return this.p5t(isIntArray(instance) ? instance : THROW_CCE());
|
|
1933
|
+
};
|
|
1934
|
+
function HeadersDataPool$1() {
|
|
1935
|
+
DefaultPool.call(this, 1000);
|
|
1936
|
+
}
|
|
1937
|
+
protoOf(HeadersDataPool$1).p4w = function () {
|
|
1938
|
+
return new HeadersData();
|
|
1939
|
+
};
|
|
1940
|
+
protoOf(HeadersDataPool$1).t5t = function (instance) {
|
|
1941
|
+
instance.m1h();
|
|
1942
|
+
return protoOf(DefaultPool).u4w.call(this, instance);
|
|
1943
|
+
};
|
|
1944
|
+
protoOf(HeadersDataPool$1).u4w = function (instance) {
|
|
1945
|
+
return this.t5t(instance instanceof HeadersData ? instance : THROW_CCE());
|
|
1946
|
+
};
|
|
1947
|
+
var properties_initialized_HttpHeadersMap_kt_kotj4w;
|
|
1948
|
+
function _init_properties_HttpHeadersMap_kt__hwatby() {
|
|
1949
|
+
if (!properties_initialized_HttpHeadersMap_kt_kotj4w) {
|
|
1950
|
+
properties_initialized_HttpHeadersMap_kt_kotj4w = true;
|
|
1951
|
+
IntArrayPool = new IntArrayPool$1();
|
|
1952
|
+
HeadersDataPool = new HeadersDataPool$1();
|
|
1953
|
+
}
|
|
1954
|
+
}
|
|
1955
|
+
function get_hostForbiddenSymbols() {
|
|
1956
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
1957
|
+
return hostForbiddenSymbols;
|
|
1958
|
+
}
|
|
1959
|
+
var hostForbiddenSymbols;
|
|
1960
|
+
function get_httpLineEndings() {
|
|
1961
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
1962
|
+
return httpLineEndings;
|
|
1963
|
+
}
|
|
1964
|
+
var httpLineEndings;
|
|
1965
|
+
function get_versions() {
|
|
1966
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
1967
|
+
return versions;
|
|
1968
|
+
}
|
|
1969
|
+
var versions;
|
|
1970
|
+
function parseHeaders(input, builder, range, $completion) {
|
|
1971
|
+
range = range === VOID ? new MutableRange(0, 0) : range;
|
|
1972
|
+
var tmp = new $parseHeadersCOROUTINE$(input, builder, range, $completion);
|
|
1973
|
+
tmp.z9_1 = Unit_instance;
|
|
1974
|
+
tmp.aa_1 = null;
|
|
1975
|
+
return tmp.fa();
|
|
1976
|
+
}
|
|
1977
|
+
function parseHeaderName(text, range) {
|
|
1978
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
1979
|
+
var index = range.g5u_1;
|
|
1980
|
+
var end = range.h5u_1;
|
|
1981
|
+
while (index < end) {
|
|
1982
|
+
var ch = text.b(index);
|
|
1983
|
+
if (ch === _Char___init__impl__6a9atx(58) && !(index === range.g5u_1)) {
|
|
1984
|
+
range.g5u_1 = index + 1 | 0;
|
|
1985
|
+
return index;
|
|
1986
|
+
}
|
|
1987
|
+
if (isDelimiter(ch)) {
|
|
1988
|
+
parseHeaderNameFailed(text, index, range.g5u_1, ch);
|
|
1989
|
+
}
|
|
1990
|
+
index = index + 1 | 0;
|
|
1991
|
+
}
|
|
1992
|
+
noColonFound(text, range);
|
|
1993
|
+
}
|
|
1994
|
+
function parseHeaderValue(text, range) {
|
|
1995
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
1996
|
+
var start = range.g5u_1;
|
|
1997
|
+
var end = range.h5u_1;
|
|
1998
|
+
var index = start;
|
|
1999
|
+
index = skipSpacesAndHorizontalTabs(text, index, end);
|
|
2000
|
+
if (index >= end) {
|
|
2001
|
+
range.g5u_1 = end;
|
|
2002
|
+
return Unit_instance;
|
|
2003
|
+
}
|
|
2004
|
+
var valueStart = index;
|
|
2005
|
+
var valueLastIndex = index;
|
|
2006
|
+
while (index < end) {
|
|
2007
|
+
var ch = text.b(index);
|
|
2008
|
+
if (ch !== _Char___init__impl__6a9atx(9) && ch !== _Char___init__impl__6a9atx(32))
|
|
2009
|
+
if (ch === _Char___init__impl__6a9atx(13) || ch === _Char___init__impl__6a9atx(10)) {
|
|
2010
|
+
characterIsNotAllowed(text, ch);
|
|
2011
|
+
} else
|
|
2012
|
+
valueLastIndex = index;
|
|
2013
|
+
index = index + 1 | 0;
|
|
2014
|
+
}
|
|
2015
|
+
range.g5u_1 = valueStart;
|
|
2016
|
+
range.h5u_1 = valueLastIndex + 1 | 0;
|
|
2017
|
+
}
|
|
2018
|
+
function validateHostHeader(host) {
|
|
2019
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2020
|
+
if (endsWith(host, ':')) {
|
|
2021
|
+
throw new ParserException("Host header with ':' should contains port: " + toString(host));
|
|
2022
|
+
}
|
|
2023
|
+
var tmp$ret$1;
|
|
2024
|
+
$l$block: {
|
|
2025
|
+
// Inline function 'kotlin.text.any' call
|
|
2026
|
+
var inductionVariable = 0;
|
|
2027
|
+
while (inductionVariable < charSequenceLength(host)) {
|
|
2028
|
+
var element = charSequenceGet(host, inductionVariable);
|
|
2029
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
2030
|
+
if (get_hostForbiddenSymbols().w(new Char(element))) {
|
|
2031
|
+
tmp$ret$1 = true;
|
|
2032
|
+
break $l$block;
|
|
2033
|
+
}
|
|
2034
|
+
}
|
|
2035
|
+
tmp$ret$1 = false;
|
|
2036
|
+
}
|
|
2037
|
+
if (tmp$ret$1) {
|
|
2038
|
+
throw new ParserException('Host cannot contain any of the following symbols: ' + toString(get_hostForbiddenSymbols()));
|
|
2039
|
+
}
|
|
2040
|
+
}
|
|
2041
|
+
function isDelimiter(ch) {
|
|
2042
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2043
|
+
return Char__compareTo_impl_ypi4mb(ch, _Char___init__impl__6a9atx(32)) <= 0 || contains('"(),/:;<=>?@[\\]{}', ch);
|
|
2044
|
+
}
|
|
2045
|
+
function parseHeaderNameFailed(text, index, start, ch) {
|
|
2046
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2047
|
+
if (ch === _Char___init__impl__6a9atx(58)) {
|
|
2048
|
+
throw new ParserException('Empty header names are not allowed as per RFC7230.');
|
|
2049
|
+
}
|
|
2050
|
+
if (index === start) {
|
|
2051
|
+
throw new ParserException('Multiline headers via line folding is not supported since it is deprecated as per RFC7230.');
|
|
2052
|
+
}
|
|
2053
|
+
characterIsNotAllowed(text, ch);
|
|
2054
|
+
}
|
|
2055
|
+
function noColonFound(text, range) {
|
|
2056
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2057
|
+
var tmp2 = range.g5u_1;
|
|
2058
|
+
// Inline function 'kotlin.text.substring' call
|
|
2059
|
+
var endIndex = range.h5u_1;
|
|
2060
|
+
var tmp$ret$0 = toString(charSequenceSubSequence(text, tmp2, endIndex));
|
|
2061
|
+
throw new ParserException('No colon in HTTP header in ' + tmp$ret$0 + ' in builder: \n' + toString(text));
|
|
2062
|
+
}
|
|
2063
|
+
function characterIsNotAllowed(text, ch) {
|
|
2064
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2065
|
+
// Inline function 'kotlin.code' call
|
|
2066
|
+
var tmp$ret$0 = Char__toInt_impl_vasixd(ch);
|
|
2067
|
+
throw new ParserException('Character with code ' + (tmp$ret$0 & 255) + ' is not allowed in header names, \n' + toString(text));
|
|
2068
|
+
}
|
|
2069
|
+
function ParserException(message) {
|
|
2070
|
+
IllegalStateException_init_$Init$(message, this);
|
|
2071
|
+
captureStack(this, ParserException);
|
|
2072
|
+
}
|
|
2073
|
+
function parseRequest(input, $completion) {
|
|
2074
|
+
var tmp = new $parseRequestCOROUTINE$(input, $completion);
|
|
2075
|
+
tmp.z9_1 = Unit_instance;
|
|
2076
|
+
tmp.aa_1 = null;
|
|
2077
|
+
return tmp.fa();
|
|
2078
|
+
}
|
|
2079
|
+
function parseHttpMethod(text, range) {
|
|
2080
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2081
|
+
skipSpaces(text, range);
|
|
2082
|
+
var tmp = get_DefaultHttpMethods();
|
|
2083
|
+
var tmp_0 = range.g5u_1;
|
|
2084
|
+
var tmp_1 = range.h5u_1;
|
|
2085
|
+
var exact = singleOrNull(tmp.e5r(text, tmp_0, tmp_1, VOID, parseHttpMethod$lambda));
|
|
2086
|
+
if (!(exact == null)) {
|
|
2087
|
+
range.g5u_1 = range.g5u_1 + exact.t5d_1.length | 0;
|
|
2088
|
+
return exact;
|
|
2089
|
+
}
|
|
2090
|
+
return parseHttpMethodFull(text, range);
|
|
2091
|
+
}
|
|
2092
|
+
function parseUri(text, range) {
|
|
2093
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2094
|
+
skipSpaces(text, range);
|
|
2095
|
+
var start = range.g5u_1;
|
|
2096
|
+
var spaceOrEnd = findSpaceOrEnd(text, range);
|
|
2097
|
+
var length = spaceOrEnd - start | 0;
|
|
2098
|
+
if (length <= 0)
|
|
2099
|
+
return '';
|
|
2100
|
+
if (length === 1 && charSequenceGet(text, start) === _Char___init__impl__6a9atx(47)) {
|
|
2101
|
+
range.g5u_1 = spaceOrEnd;
|
|
2102
|
+
return '/';
|
|
2103
|
+
}
|
|
2104
|
+
var s = charSequenceSubSequence(text, start, spaceOrEnd);
|
|
2105
|
+
range.g5u_1 = spaceOrEnd;
|
|
2106
|
+
return s;
|
|
2107
|
+
}
|
|
2108
|
+
function parseVersion(text, range) {
|
|
2109
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2110
|
+
skipSpaces(text, range);
|
|
2111
|
+
// Inline function 'kotlin.check' call
|
|
2112
|
+
if (!(range.g5u_1 < range.h5u_1)) {
|
|
2113
|
+
var message = 'Failed to parse version: ' + toString(text);
|
|
2114
|
+
throw IllegalStateException_init_$Create$(toString(message));
|
|
2115
|
+
}
|
|
2116
|
+
var tmp = get_versions();
|
|
2117
|
+
var tmp_0 = range.g5u_1;
|
|
2118
|
+
var tmp_1 = range.h5u_1;
|
|
2119
|
+
var exact = singleOrNull(tmp.e5r(text, tmp_0, tmp_1, VOID, parseVersion$lambda));
|
|
2120
|
+
if (!(exact == null)) {
|
|
2121
|
+
range.g5u_1 = range.g5u_1 + exact.length | 0;
|
|
2122
|
+
return exact;
|
|
2123
|
+
}
|
|
2124
|
+
unsupportedHttpVersion(nextToken(text, range));
|
|
2125
|
+
}
|
|
2126
|
+
function parseHttpMethodFull(text, range) {
|
|
2127
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2128
|
+
return new HttpMethod(toString(nextToken(text, range)));
|
|
2129
|
+
}
|
|
2130
|
+
function unsupportedHttpVersion(result) {
|
|
2131
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2132
|
+
throw new ParserException('Unsupported HTTP version: ' + toString(result));
|
|
2133
|
+
}
|
|
2134
|
+
function parseHttpMethod$lambda(ch, _unused_var__etf5q3) {
|
|
2135
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2136
|
+
return equals(ch, new Char(_Char___init__impl__6a9atx(32)));
|
|
2137
|
+
}
|
|
2138
|
+
function parseVersion$lambda(ch, _unused_var__etf5q3) {
|
|
2139
|
+
_init_properties_HttpParser_kt__gbdom1();
|
|
2140
|
+
return equals(ch, new Char(_Char___init__impl__6a9atx(32)));
|
|
2141
|
+
}
|
|
2142
|
+
function $parseHeadersCOROUTINE$(input, builder, range, resultContinuation) {
|
|
2143
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
2144
|
+
this.c5u_1 = input;
|
|
2145
|
+
this.d5u_1 = builder;
|
|
2146
|
+
this.e5u_1 = range;
|
|
2147
|
+
}
|
|
2148
|
+
protoOf($parseHeadersCOROUTINE$).fa = function () {
|
|
2149
|
+
var suspendResult = this.z9_1;
|
|
2150
|
+
$sm: do
|
|
2151
|
+
try {
|
|
2152
|
+
var tmp = this.x9_1;
|
|
2153
|
+
switch (tmp) {
|
|
2154
|
+
case 0:
|
|
2155
|
+
this.y9_1 = 7;
|
|
2156
|
+
this.f5u_1 = new HttpHeadersMap(this.d5u_1);
|
|
2157
|
+
this.y9_1 = 6;
|
|
2158
|
+
this.x9_1 = 1;
|
|
2159
|
+
continue $sm;
|
|
2160
|
+
case 1:
|
|
2161
|
+
if (!true) {
|
|
2162
|
+
this.x9_1 = 5;
|
|
2163
|
+
continue $sm;
|
|
2164
|
+
}
|
|
2165
|
+
|
|
2166
|
+
this.x9_1 = 2;
|
|
2167
|
+
suspendResult = readUTF8LineTo(this.c5u_1, this.d5u_1, 8192, get_httpLineEndings(), this);
|
|
2168
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2169
|
+
return suspendResult;
|
|
2170
|
+
}
|
|
2171
|
+
|
|
2172
|
+
continue $sm;
|
|
2173
|
+
case 2:
|
|
2174
|
+
var ARGUMENT = suspendResult;
|
|
2175
|
+
if (!ARGUMENT) {
|
|
2176
|
+
this.f5u_1.m1h();
|
|
2177
|
+
return null;
|
|
2178
|
+
} else {
|
|
2179
|
+
this.x9_1 = 3;
|
|
2180
|
+
continue $sm;
|
|
2181
|
+
}
|
|
2182
|
+
|
|
2183
|
+
case 3:
|
|
2184
|
+
this.e5u_1.h5u_1 = this.d5u_1.l5t_1;
|
|
2185
|
+
var rangeLength = this.e5u_1.h5u_1 - this.e5u_1.g5u_1 | 0;
|
|
2186
|
+
if (rangeLength === 0) {
|
|
2187
|
+
this.x9_1 = 5;
|
|
2188
|
+
continue $sm;
|
|
2189
|
+
} else {
|
|
2190
|
+
this.x9_1 = 4;
|
|
2191
|
+
continue $sm;
|
|
2192
|
+
}
|
|
2193
|
+
|
|
2194
|
+
case 4:
|
|
2195
|
+
if (rangeLength >= 8192) {
|
|
2196
|
+
var message = 'Header line length limit exceeded';
|
|
2197
|
+
throw IllegalStateException_init_$Create$(toString(message));
|
|
2198
|
+
}
|
|
2199
|
+
|
|
2200
|
+
var nameStart = this.e5u_1.g5u_1;
|
|
2201
|
+
var nameEnd = parseHeaderName(this.d5u_1, this.e5u_1);
|
|
2202
|
+
var headerEnd = this.e5u_1.h5u_1;
|
|
2203
|
+
parseHeaderValue(this.d5u_1, this.e5u_1);
|
|
2204
|
+
var valueStart = this.e5u_1.g5u_1;
|
|
2205
|
+
var valueEnd = this.e5u_1.h5u_1;
|
|
2206
|
+
this.e5u_1.g5u_1 = headerEnd;
|
|
2207
|
+
this.f5u_1.p5s(nameStart, nameEnd, valueStart, valueEnd);
|
|
2208
|
+
this.x9_1 = 1;
|
|
2209
|
+
continue $sm;
|
|
2210
|
+
case 5:
|
|
2211
|
+
var host = this.f5u_1.cf(HttpHeaders_getInstance().j5a_1);
|
|
2212
|
+
if (!(host == null)) {
|
|
2213
|
+
validateHostHeader(host);
|
|
2214
|
+
}
|
|
2215
|
+
|
|
2216
|
+
return this.f5u_1;
|
|
2217
|
+
case 6:
|
|
2218
|
+
this.y9_1 = 7;
|
|
2219
|
+
var tmp_0 = this.aa_1;
|
|
2220
|
+
if (tmp_0 instanceof Error) {
|
|
2221
|
+
var t = this.aa_1;
|
|
2222
|
+
this.f5u_1.m1h();
|
|
2223
|
+
throw t;
|
|
2224
|
+
} else {
|
|
2225
|
+
throw this.aa_1;
|
|
2226
|
+
}
|
|
2227
|
+
|
|
2228
|
+
case 7:
|
|
2229
|
+
throw this.aa_1;
|
|
2230
|
+
}
|
|
2231
|
+
} catch ($p) {
|
|
2232
|
+
var e = $p;
|
|
2233
|
+
if (this.y9_1 === 7) {
|
|
2234
|
+
throw e;
|
|
2235
|
+
} else {
|
|
2236
|
+
this.x9_1 = this.y9_1;
|
|
2237
|
+
this.aa_1 = e;
|
|
2238
|
+
}
|
|
2239
|
+
}
|
|
2240
|
+
while (true);
|
|
2241
|
+
};
|
|
2242
|
+
function $parseRequestCOROUTINE$(input, resultContinuation) {
|
|
2243
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
2244
|
+
this.q5u_1 = input;
|
|
2245
|
+
}
|
|
2246
|
+
protoOf($parseRequestCOROUTINE$).fa = function () {
|
|
2247
|
+
var suspendResult = this.z9_1;
|
|
2248
|
+
$sm: do
|
|
2249
|
+
try {
|
|
2250
|
+
var tmp = this.x9_1;
|
|
2251
|
+
switch (tmp) {
|
|
2252
|
+
case 0:
|
|
2253
|
+
this.y9_1 = 8;
|
|
2254
|
+
this.r5u_1 = new CharArrayBuilder();
|
|
2255
|
+
this.s5u_1 = new MutableRange(0, 0);
|
|
2256
|
+
this.y9_1 = 7;
|
|
2257
|
+
this.x9_1 = 1;
|
|
2258
|
+
continue $sm;
|
|
2259
|
+
case 1:
|
|
2260
|
+
if (!true) {
|
|
2261
|
+
this.x9_1 = 6;
|
|
2262
|
+
continue $sm;
|
|
2263
|
+
}
|
|
2264
|
+
|
|
2265
|
+
this.x9_1 = 2;
|
|
2266
|
+
suspendResult = readUTF8LineTo(this.q5u_1, this.r5u_1, 8192, get_httpLineEndings(), this);
|
|
2267
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2268
|
+
return suspendResult;
|
|
2269
|
+
}
|
|
2270
|
+
|
|
2271
|
+
continue $sm;
|
|
2272
|
+
case 2:
|
|
2273
|
+
this.t5u_1 = suspendResult;
|
|
2274
|
+
if (!this.t5u_1) {
|
|
2275
|
+
return null;
|
|
2276
|
+
} else {
|
|
2277
|
+
this.x9_1 = 3;
|
|
2278
|
+
continue $sm;
|
|
2279
|
+
}
|
|
2280
|
+
|
|
2281
|
+
case 3:
|
|
2282
|
+
this.s5u_1.h5u_1 = this.r5u_1.l5t_1;
|
|
2283
|
+
if (this.s5u_1.g5u_1 === this.s5u_1.h5u_1) {
|
|
2284
|
+
this.x9_1 = 1;
|
|
2285
|
+
continue $sm;
|
|
2286
|
+
} else {
|
|
2287
|
+
this.x9_1 = 4;
|
|
2288
|
+
continue $sm;
|
|
2289
|
+
}
|
|
2290
|
+
|
|
2291
|
+
case 4:
|
|
2292
|
+
this.u5u_1 = parseHttpMethod(this.r5u_1, this.s5u_1);
|
|
2293
|
+
this.v5u_1 = parseUri(this.r5u_1, this.s5u_1);
|
|
2294
|
+
this.w5u_1 = parseVersion(this.r5u_1, this.s5u_1);
|
|
2295
|
+
skipSpaces(this.r5u_1, this.s5u_1);
|
|
2296
|
+
if (!(this.s5u_1.g5u_1 === this.s5u_1.h5u_1)) {
|
|
2297
|
+
var tmp0 = this.r5u_1;
|
|
2298
|
+
var tmp2 = this.s5u_1.g5u_1;
|
|
2299
|
+
var endIndex = this.s5u_1.h5u_1;
|
|
2300
|
+
throw new ParserException('Extra characters in request line: ' + toString(charSequenceSubSequence(tmp0, tmp2, endIndex)));
|
|
2301
|
+
}
|
|
2302
|
+
|
|
2303
|
+
var this_0 = this.v5u_1;
|
|
2304
|
+
if (charSequenceLength(this_0) === 0)
|
|
2305
|
+
throw new ParserException('URI is not specified');
|
|
2306
|
+
var this_1 = this.w5u_1;
|
|
2307
|
+
if (charSequenceLength(this_1) === 0)
|
|
2308
|
+
throw new ParserException('HTTP version is not specified');
|
|
2309
|
+
this.x9_1 = 5;
|
|
2310
|
+
suspendResult = parseHeaders(this.q5u_1, this.r5u_1, this.s5u_1, this);
|
|
2311
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2312
|
+
return suspendResult;
|
|
2313
|
+
}
|
|
2314
|
+
|
|
2315
|
+
continue $sm;
|
|
2316
|
+
case 5:
|
|
2317
|
+
var tmp0_elvis_lhs = suspendResult;
|
|
2318
|
+
var tmp_0;
|
|
2319
|
+
if (tmp0_elvis_lhs == null) {
|
|
2320
|
+
return null;
|
|
2321
|
+
} else {
|
|
2322
|
+
tmp_0 = tmp0_elvis_lhs;
|
|
2323
|
+
}
|
|
2324
|
+
|
|
2325
|
+
var headers = tmp_0;
|
|
2326
|
+
return new Request(this.u5u_1, this.v5u_1, this.w5u_1, headers, this.r5u_1);
|
|
2327
|
+
case 6:
|
|
2328
|
+
this.y9_1 = 8;
|
|
2329
|
+
this.x9_1 = 9;
|
|
2330
|
+
continue $sm;
|
|
2331
|
+
case 7:
|
|
2332
|
+
this.y9_1 = 8;
|
|
2333
|
+
var tmp_1 = this.aa_1;
|
|
2334
|
+
if (tmp_1 instanceof Error) {
|
|
2335
|
+
var t = this.aa_1;
|
|
2336
|
+
this.r5u_1.m1h();
|
|
2337
|
+
throw t;
|
|
2338
|
+
} else {
|
|
2339
|
+
throw this.aa_1;
|
|
2340
|
+
}
|
|
2341
|
+
|
|
2342
|
+
case 8:
|
|
2343
|
+
throw this.aa_1;
|
|
2344
|
+
case 9:
|
|
2345
|
+
this.y9_1 = 8;
|
|
2346
|
+
return Unit_instance;
|
|
2347
|
+
}
|
|
2348
|
+
} catch ($p) {
|
|
2349
|
+
var e = $p;
|
|
2350
|
+
if (this.y9_1 === 8) {
|
|
2351
|
+
throw e;
|
|
2352
|
+
} else {
|
|
2353
|
+
this.x9_1 = this.y9_1;
|
|
2354
|
+
this.aa_1 = e;
|
|
2355
|
+
}
|
|
2356
|
+
}
|
|
2357
|
+
while (true);
|
|
2358
|
+
};
|
|
2359
|
+
var properties_initialized_HttpParser_kt_uedryv;
|
|
2360
|
+
function _init_properties_HttpParser_kt__gbdom1() {
|
|
2361
|
+
if (!properties_initialized_HttpParser_kt_uedryv) {
|
|
2362
|
+
properties_initialized_HttpParser_kt_uedryv = true;
|
|
2363
|
+
hostForbiddenSymbols = setOf([new Char(_Char___init__impl__6a9atx(47)), new Char(_Char___init__impl__6a9atx(63)), new Char(_Char___init__impl__6a9atx(35)), new Char(_Char___init__impl__6a9atx(64))]);
|
|
2364
|
+
httpLineEndings = LineEndingMode__plus_impl_ttpz2j(Companion_getInstance_2().k4o_1, Companion_getInstance_2().j4o_1);
|
|
2365
|
+
versions = Companion_instance_0.x5u(listOf_0(['HTTP/1.0', 'HTTP/1.1']));
|
|
2366
|
+
}
|
|
2367
|
+
}
|
|
2368
|
+
function get_CrLf_0() {
|
|
2369
|
+
_init_properties_Multipart_kt__ato98a();
|
|
2370
|
+
return CrLf_0;
|
|
2371
|
+
}
|
|
2372
|
+
var CrLf_0;
|
|
2373
|
+
function get_PrefixString() {
|
|
2374
|
+
_init_properties_Multipart_kt__ato98a();
|
|
2375
|
+
return PrefixString;
|
|
2376
|
+
}
|
|
2377
|
+
var PrefixString;
|
|
2378
|
+
function MultipartEvent$MultipartPart$release$lambda(this$0) {
|
|
2379
|
+
return function (t) {
|
|
2380
|
+
var tmp;
|
|
2381
|
+
if (!(t == null)) {
|
|
2382
|
+
this$0.w5m_1.f1z().m1h();
|
|
2383
|
+
tmp = Unit_instance;
|
|
2384
|
+
}
|
|
2385
|
+
return Unit_instance;
|
|
2386
|
+
};
|
|
2387
|
+
}
|
|
2388
|
+
function Preamble(body) {
|
|
2389
|
+
MultipartEvent.call(this);
|
|
2390
|
+
this.y5u_1 = body;
|
|
2391
|
+
}
|
|
2392
|
+
protoOf(Preamble).m1h = function () {
|
|
2393
|
+
this.y5u_1.u4();
|
|
2394
|
+
};
|
|
2395
|
+
function MultipartPart(headers, body) {
|
|
2396
|
+
MultipartEvent.call(this);
|
|
2397
|
+
this.w5m_1 = headers;
|
|
2398
|
+
this.x5m_1 = body;
|
|
2399
|
+
}
|
|
2400
|
+
protoOf(MultipartPart).m1h = function () {
|
|
2401
|
+
this.w5m_1.c1x(MultipartEvent$MultipartPart$release$lambda(this));
|
|
2402
|
+
discardBlocking(this.x5m_1);
|
|
2403
|
+
};
|
|
2404
|
+
function Epilogue(body) {
|
|
2405
|
+
MultipartEvent.call(this);
|
|
2406
|
+
this.z5u_1 = body;
|
|
2407
|
+
}
|
|
2408
|
+
protoOf(Epilogue).m1h = function () {
|
|
2409
|
+
this.z5u_1.u4();
|
|
2410
|
+
};
|
|
2411
|
+
function MultipartEvent() {
|
|
2412
|
+
}
|
|
2413
|
+
function parseMultipart(_this__u8e3s4, input, contentType, contentLength, maxPartSize) {
|
|
2414
|
+
maxPartSize = maxPartSize === VOID ? new Long(-1, 2147483647) : maxPartSize;
|
|
2415
|
+
_init_properties_Multipart_kt__ato98a();
|
|
2416
|
+
if (!MultiPart_getInstance().b58(contentType)) {
|
|
2417
|
+
throw new UnsupportedMediaTypeExceptionCIO('Failed to parse multipart: Content-Type should be multipart/* but it is ' + toString(contentType));
|
|
2418
|
+
}
|
|
2419
|
+
var boundaryByteBuffer = parseBoundaryInternal(contentType);
|
|
2420
|
+
var boundaryBytes = ByteString_init_$Create$(boundaryByteBuffer);
|
|
2421
|
+
return parseMultipart_0(_this__u8e3s4, boundaryBytes, input, contentLength, maxPartSize);
|
|
2422
|
+
}
|
|
2423
|
+
function parseBoundaryInternal(contentType) {
|
|
2424
|
+
_init_properties_Multipart_kt__ato98a();
|
|
2425
|
+
var boundaryParameter = findBoundary(contentType);
|
|
2426
|
+
if (boundaryParameter === -1) {
|
|
2427
|
+
throw IOException_init_$Create$("Failed to parse multipart: Content-Type's boundary parameter is missing");
|
|
2428
|
+
}
|
|
2429
|
+
var boundaryStart = boundaryParameter + 9 | 0;
|
|
2430
|
+
var boundaryBytes = new Int8Array(74);
|
|
2431
|
+
var position = {_v: 0};
|
|
2432
|
+
parseBoundaryInternal$put(position, boundaryBytes, 13);
|
|
2433
|
+
parseBoundaryInternal$put(position, boundaryBytes, 10);
|
|
2434
|
+
parseBoundaryInternal$put(position, boundaryBytes, 45);
|
|
2435
|
+
parseBoundaryInternal$put(position, boundaryBytes, 45);
|
|
2436
|
+
var state = 0;
|
|
2437
|
+
var inductionVariable = boundaryStart;
|
|
2438
|
+
var last = charSequenceLength(contentType);
|
|
2439
|
+
if (inductionVariable < last)
|
|
2440
|
+
loop: do {
|
|
2441
|
+
var i = inductionVariable;
|
|
2442
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
2443
|
+
var ch = charSequenceGet(contentType, i);
|
|
2444
|
+
// Inline function 'kotlin.code' call
|
|
2445
|
+
var v = Char__toInt_impl_vasixd(ch) & 65535;
|
|
2446
|
+
if ((v & 65535) > 127) {
|
|
2447
|
+
throw IOException_init_$Create$('Failed to parse multipart: wrong boundary byte 0x' + toString_0(v, 16) + ' - should be 7bit character');
|
|
2448
|
+
}
|
|
2449
|
+
switch (state) {
|
|
2450
|
+
case 0:
|
|
2451
|
+
if (ch !== _Char___init__impl__6a9atx(32))
|
|
2452
|
+
if (ch === _Char___init__impl__6a9atx(34)) {
|
|
2453
|
+
state = 2;
|
|
2454
|
+
} else if (ch === _Char___init__impl__6a9atx(59) || ch === _Char___init__impl__6a9atx(44)) {
|
|
2455
|
+
break loop;
|
|
2456
|
+
} else {
|
|
2457
|
+
state = 1;
|
|
2458
|
+
parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
|
|
2459
|
+
}
|
|
2460
|
+
|
|
2461
|
+
break;
|
|
2462
|
+
case 1:
|
|
2463
|
+
if (ch === _Char___init__impl__6a9atx(32) || ch === _Char___init__impl__6a9atx(44) || ch === _Char___init__impl__6a9atx(59)) {
|
|
2464
|
+
break loop;
|
|
2465
|
+
} else {
|
|
2466
|
+
parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
|
|
2467
|
+
}
|
|
2468
|
+
|
|
2469
|
+
break;
|
|
2470
|
+
case 2:
|
|
2471
|
+
if (ch === _Char___init__impl__6a9atx(92)) {
|
|
2472
|
+
state = 3;
|
|
2473
|
+
} else if (ch === _Char___init__impl__6a9atx(34)) {
|
|
2474
|
+
break loop;
|
|
2475
|
+
} else {
|
|
2476
|
+
parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
|
|
2477
|
+
}
|
|
2478
|
+
|
|
2479
|
+
break;
|
|
2480
|
+
case 3:
|
|
2481
|
+
parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
|
|
2482
|
+
state = 2;
|
|
2483
|
+
break;
|
|
2484
|
+
}
|
|
2485
|
+
}
|
|
2486
|
+
while (inductionVariable < last);
|
|
2487
|
+
if (position._v === 4) {
|
|
2488
|
+
throw IOException_init_$Create$('Empty multipart boundary is not allowed');
|
|
2489
|
+
}
|
|
2490
|
+
return copyOfRange(boundaryBytes, 0, position._v);
|
|
2491
|
+
}
|
|
2492
|
+
function parseMultipart_0(_this__u8e3s4, boundaryPrefixed, input, totalLength, maxPartSize) {
|
|
2493
|
+
_init_properties_Multipart_kt__ato98a();
|
|
2494
|
+
return produce(_this__u8e3s4, VOID, VOID, parseMultipart$slambda_0(input, boundaryPrefixed, maxPartSize, totalLength, null));
|
|
2495
|
+
}
|
|
2496
|
+
function findBoundary(contentType) {
|
|
2497
|
+
_init_properties_Multipart_kt__ato98a();
|
|
2498
|
+
var state = 0;
|
|
2499
|
+
var paramNameCount = 0;
|
|
2500
|
+
var inductionVariable = 0;
|
|
2501
|
+
var last = charSequenceLength(contentType) - 1 | 0;
|
|
2502
|
+
if (inductionVariable <= last)
|
|
2503
|
+
do {
|
|
2504
|
+
var i = inductionVariable;
|
|
2505
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
2506
|
+
var ch = charSequenceGet(contentType, i);
|
|
2507
|
+
switch (state) {
|
|
2508
|
+
case 0:
|
|
2509
|
+
if (ch === _Char___init__impl__6a9atx(59)) {
|
|
2510
|
+
state = 1;
|
|
2511
|
+
paramNameCount = 0;
|
|
2512
|
+
}
|
|
2513
|
+
|
|
2514
|
+
break;
|
|
2515
|
+
case 1:
|
|
2516
|
+
if (ch === _Char___init__impl__6a9atx(61)) {
|
|
2517
|
+
state = 2;
|
|
2518
|
+
} else if (ch === _Char___init__impl__6a9atx(59)) {
|
|
2519
|
+
paramNameCount = 0;
|
|
2520
|
+
} else if (ch === _Char___init__impl__6a9atx(44)) {
|
|
2521
|
+
state = 0;
|
|
2522
|
+
} else if (ch !== _Char___init__impl__6a9atx(32))
|
|
2523
|
+
if (paramNameCount === 0 && startsWith(contentType, 'boundary=', i, true)) {
|
|
2524
|
+
return i;
|
|
2525
|
+
} else {
|
|
2526
|
+
paramNameCount = paramNameCount + 1 | 0;
|
|
2527
|
+
}
|
|
2528
|
+
|
|
2529
|
+
break;
|
|
2530
|
+
case 2:
|
|
2531
|
+
if (ch === _Char___init__impl__6a9atx(34))
|
|
2532
|
+
state = 3;
|
|
2533
|
+
else if (ch === _Char___init__impl__6a9atx(44))
|
|
2534
|
+
state = 0;
|
|
2535
|
+
else if (ch === _Char___init__impl__6a9atx(59)) {
|
|
2536
|
+
state = 1;
|
|
2537
|
+
paramNameCount = 0;
|
|
2538
|
+
}
|
|
2539
|
+
|
|
2540
|
+
break;
|
|
2541
|
+
case 3:
|
|
2542
|
+
if (ch === _Char___init__impl__6a9atx(34)) {
|
|
2543
|
+
state = 1;
|
|
2544
|
+
paramNameCount = 0;
|
|
2545
|
+
} else if (ch === _Char___init__impl__6a9atx(92)) {
|
|
2546
|
+
state = 4;
|
|
2547
|
+
}
|
|
2548
|
+
|
|
2549
|
+
break;
|
|
2550
|
+
case 4:
|
|
2551
|
+
state = 3;
|
|
2552
|
+
break;
|
|
2553
|
+
}
|
|
2554
|
+
}
|
|
2555
|
+
while (inductionVariable <= last);
|
|
2556
|
+
return -1;
|
|
2557
|
+
}
|
|
2558
|
+
function parsePreambleImpl(boundary, input, output, limit, $completion) {
|
|
2559
|
+
limit = limit === VOID ? new Long(-1, 2147483647) : limit;
|
|
2560
|
+
return readUntil(input, boundary, output, limit, true, $completion);
|
|
2561
|
+
}
|
|
2562
|
+
function parsePartHeadersImpl(input, $completion) {
|
|
2563
|
+
var tmp = new $parsePartHeadersImplCOROUTINE$(input, $completion);
|
|
2564
|
+
tmp.z9_1 = Unit_instance;
|
|
2565
|
+
tmp.aa_1 = null;
|
|
2566
|
+
return tmp.fa();
|
|
2567
|
+
}
|
|
2568
|
+
function parsePartBodyImpl(boundaryPrefixed, input, output, headers, limit, $completion) {
|
|
2569
|
+
var tmp = new $parsePartBodyImplCOROUTINE$(boundaryPrefixed, input, output, headers, limit, $completion);
|
|
2570
|
+
tmp.z9_1 = Unit_instance;
|
|
2571
|
+
tmp.aa_1 = null;
|
|
2572
|
+
return tmp.fa();
|
|
2573
|
+
}
|
|
2574
|
+
function skipIfFoundReadCount(_this__u8e3s4, prefix, $completion) {
|
|
2575
|
+
var tmp = new $skipIfFoundReadCountCOROUTINE$(_this__u8e3s4, prefix, $completion);
|
|
2576
|
+
tmp.z9_1 = Unit_instance;
|
|
2577
|
+
tmp.aa_1 = null;
|
|
2578
|
+
return tmp.fa();
|
|
2579
|
+
}
|
|
2580
|
+
function throwLimitExceeded(actual, limit) {
|
|
2581
|
+
_init_properties_Multipart_kt__ato98a();
|
|
2582
|
+
throw IOException_init_$Create$('Multipart content length exceeds limit ' + actual.toString() + ' > ' + limit.toString() + '; ' + "limit is defined using 'formFieldLimit' argument");
|
|
2583
|
+
}
|
|
2584
|
+
function parseBoundaryInternal$put(position, boundaryBytes, value) {
|
|
2585
|
+
if (position._v >= boundaryBytes.length) {
|
|
2586
|
+
throw IOException_init_$Create$("Failed to parse multipart: boundary shouldn't be longer than 70 characters");
|
|
2587
|
+
}
|
|
2588
|
+
var _unary__edvuaz = position._v;
|
|
2589
|
+
position._v = _unary__edvuaz + 1 | 0;
|
|
2590
|
+
boundaryBytes[_unary__edvuaz] = value;
|
|
2591
|
+
}
|
|
2592
|
+
function parseMultipart$slambda$slambda($firstBoundary, $countedInput, resultContinuation) {
|
|
2593
|
+
this.v5w_1 = $firstBoundary;
|
|
2594
|
+
this.w5w_1 = $countedInput;
|
|
2595
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
2596
|
+
}
|
|
2597
|
+
protoOf(parseMultipart$slambda$slambda).y5w = function ($this$writer, $completion) {
|
|
2598
|
+
var tmp = this.z5w($this$writer, $completion);
|
|
2599
|
+
tmp.z9_1 = Unit_instance;
|
|
2600
|
+
tmp.aa_1 = null;
|
|
2601
|
+
return tmp.fa();
|
|
2602
|
+
};
|
|
2603
|
+
protoOf(parseMultipart$slambda$slambda).ra = function (p1, $completion) {
|
|
2604
|
+
return this.y5w(p1 instanceof WriterScope ? p1 : THROW_CCE(), $completion);
|
|
2605
|
+
};
|
|
2606
|
+
protoOf(parseMultipart$slambda$slambda).fa = function () {
|
|
2607
|
+
var suspendResult = this.z9_1;
|
|
2608
|
+
$sm: do
|
|
2609
|
+
try {
|
|
2610
|
+
var tmp = this.x9_1;
|
|
2611
|
+
switch (tmp) {
|
|
2612
|
+
case 0:
|
|
2613
|
+
this.y9_1 = 3;
|
|
2614
|
+
this.x9_1 = 1;
|
|
2615
|
+
suspendResult = parsePreambleImpl(this.v5w_1, this.w5w_1, this.x5w_1.o4t_1, new Long(8193, 0), this);
|
|
2616
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2617
|
+
return suspendResult;
|
|
2618
|
+
}
|
|
2619
|
+
|
|
2620
|
+
continue $sm;
|
|
2621
|
+
case 1:
|
|
2622
|
+
this.x9_1 = 2;
|
|
2623
|
+
suspendResult = this.x5w_1.o4t_1.o4i(this);
|
|
2624
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2625
|
+
return suspendResult;
|
|
2626
|
+
}
|
|
2627
|
+
|
|
2628
|
+
continue $sm;
|
|
2629
|
+
case 2:
|
|
2630
|
+
return Unit_instance;
|
|
2631
|
+
case 3:
|
|
2632
|
+
throw this.aa_1;
|
|
2633
|
+
}
|
|
2634
|
+
} catch ($p) {
|
|
2635
|
+
var e = $p;
|
|
2636
|
+
if (this.y9_1 === 3) {
|
|
2637
|
+
throw e;
|
|
2638
|
+
} else {
|
|
2639
|
+
this.x9_1 = this.y9_1;
|
|
2640
|
+
this.aa_1 = e;
|
|
2641
|
+
}
|
|
2642
|
+
}
|
|
2643
|
+
while (true);
|
|
2644
|
+
};
|
|
2645
|
+
protoOf(parseMultipart$slambda$slambda).z5w = function ($this$writer, completion) {
|
|
2646
|
+
var i = new parseMultipart$slambda$slambda(this.v5w_1, this.w5w_1, completion);
|
|
2647
|
+
i.x5w_1 = $this$writer;
|
|
2648
|
+
return i;
|
|
2649
|
+
};
|
|
2650
|
+
function parseMultipart$slambda$slambda_0($firstBoundary, $countedInput, resultContinuation) {
|
|
2651
|
+
var i = new parseMultipart$slambda$slambda($firstBoundary, $countedInput, resultContinuation);
|
|
2652
|
+
var l = function ($this$writer, $completion) {
|
|
2653
|
+
return i.y5w($this$writer, $completion);
|
|
2654
|
+
};
|
|
2655
|
+
l.$arity = 1;
|
|
2656
|
+
return l;
|
|
2657
|
+
}
|
|
2658
|
+
function parseMultipart$slambda($input, $boundaryPrefixed, $maxPartSize, $totalLength, resultContinuation) {
|
|
2659
|
+
this.i5x_1 = $input;
|
|
2660
|
+
this.j5x_1 = $boundaryPrefixed;
|
|
2661
|
+
this.k5x_1 = $maxPartSize;
|
|
2662
|
+
this.l5x_1 = $totalLength;
|
|
2663
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
2664
|
+
}
|
|
2665
|
+
protoOf(parseMultipart$slambda).d5y = function ($this$produce, $completion) {
|
|
2666
|
+
var tmp = this.e5y($this$produce, $completion);
|
|
2667
|
+
tmp.z9_1 = Unit_instance;
|
|
2668
|
+
tmp.aa_1 = null;
|
|
2669
|
+
return tmp.fa();
|
|
2670
|
+
};
|
|
2671
|
+
protoOf(parseMultipart$slambda).ra = function (p1, $completion) {
|
|
2672
|
+
return this.d5y((!(p1 == null) ? isInterface(p1, ProducerScope) : false) ? p1 : THROW_CCE(), $completion);
|
|
2673
|
+
};
|
|
2674
|
+
protoOf(parseMultipart$slambda).fa = function () {
|
|
2675
|
+
var suspendResult = this.z9_1;
|
|
2676
|
+
$sm: do
|
|
2677
|
+
try {
|
|
2678
|
+
var tmp = this.x9_1;
|
|
2679
|
+
switch (tmp) {
|
|
2680
|
+
case 0:
|
|
2681
|
+
this.y9_1 = 25;
|
|
2682
|
+
this.n5x_1 = counted(this.i5x_1);
|
|
2683
|
+
this.o5x_1 = this.n5x_1.f4w();
|
|
2684
|
+
this.p5x_1 = this.j5x_1.j3a(get_PrefixString().s());
|
|
2685
|
+
this.x9_1 = 1;
|
|
2686
|
+
suspendResult = readRemaining(writer(this.m5x_1, VOID, VOID, parseMultipart$slambda$slambda_0(this.p5x_1, this.n5x_1, null)).m4t_1, this);
|
|
2687
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2688
|
+
return suspendResult;
|
|
2689
|
+
}
|
|
2690
|
+
|
|
2691
|
+
continue $sm;
|
|
2692
|
+
case 1:
|
|
2693
|
+
this.q5x_1 = suspendResult;
|
|
2694
|
+
if (get_remaining(this.q5x_1).j1(new Long(0, 0)) > 0) {
|
|
2695
|
+
this.x9_1 = 2;
|
|
2696
|
+
suspendResult = this.m5x_1.m2i(new Preamble(this.q5x_1), this);
|
|
2697
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2698
|
+
return suspendResult;
|
|
2699
|
+
}
|
|
2700
|
+
continue $sm;
|
|
2701
|
+
} else {
|
|
2702
|
+
this.x9_1 = 3;
|
|
2703
|
+
continue $sm;
|
|
2704
|
+
}
|
|
2705
|
+
|
|
2706
|
+
case 2:
|
|
2707
|
+
this.x9_1 = 3;
|
|
2708
|
+
continue $sm;
|
|
2709
|
+
case 3:
|
|
2710
|
+
this.x9_1 = 4;
|
|
2711
|
+
continue $sm;
|
|
2712
|
+
case 4:
|
|
2713
|
+
if (!this.n5x_1.l4i()) {
|
|
2714
|
+
this.x9_1 = 5;
|
|
2715
|
+
suspendResult = skipIfFound(this.n5x_1, get_PrefixString(), this);
|
|
2716
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2717
|
+
return suspendResult;
|
|
2718
|
+
}
|
|
2719
|
+
continue $sm;
|
|
2720
|
+
} else {
|
|
2721
|
+
this.r5x_1 = false;
|
|
2722
|
+
this.x9_1 = 6;
|
|
2723
|
+
continue $sm;
|
|
2724
|
+
}
|
|
2725
|
+
|
|
2726
|
+
case 5:
|
|
2727
|
+
this.s5x_1 = suspendResult;
|
|
2728
|
+
this.r5x_1 = !this.s5x_1;
|
|
2729
|
+
this.x9_1 = 6;
|
|
2730
|
+
continue $sm;
|
|
2731
|
+
case 6:
|
|
2732
|
+
if (!this.r5x_1) {
|
|
2733
|
+
this.x9_1 = 15;
|
|
2734
|
+
continue $sm;
|
|
2735
|
+
}
|
|
2736
|
+
|
|
2737
|
+
this.x9_1 = 7;
|
|
2738
|
+
suspendResult = skipIfFound(this.n5x_1, get_CrLf_0(), this);
|
|
2739
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2740
|
+
return suspendResult;
|
|
2741
|
+
}
|
|
2742
|
+
|
|
2743
|
+
continue $sm;
|
|
2744
|
+
case 7:
|
|
2745
|
+
this.x9_1 = 8;
|
|
2746
|
+
suspendResult = skipIfFound(this.n5x_1, this.p5x_1, this);
|
|
2747
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2748
|
+
return suspendResult;
|
|
2749
|
+
}
|
|
2750
|
+
|
|
2751
|
+
continue $sm;
|
|
2752
|
+
case 8:
|
|
2753
|
+
if (suspendResult) {
|
|
2754
|
+
this.x9_1 = 4;
|
|
2755
|
+
continue $sm;
|
|
2756
|
+
} else {
|
|
2757
|
+
this.x9_1 = 9;
|
|
2758
|
+
continue $sm;
|
|
2759
|
+
}
|
|
2760
|
+
|
|
2761
|
+
case 9:
|
|
2762
|
+
this.t5x_1 = new ByteChannel();
|
|
2763
|
+
this.u5x_1 = CompletableDeferred();
|
|
2764
|
+
this.v5x_1 = new MultipartPart(this.u5x_1, this.t5x_1);
|
|
2765
|
+
this.x9_1 = 10;
|
|
2766
|
+
suspendResult = this.m5x_1.m2i(this.v5x_1, this);
|
|
2767
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2768
|
+
return suspendResult;
|
|
2769
|
+
}
|
|
2770
|
+
|
|
2771
|
+
continue $sm;
|
|
2772
|
+
case 10:
|
|
2773
|
+
this.w5x_1 = null;
|
|
2774
|
+
this.y9_1 = 14;
|
|
2775
|
+
this.x9_1 = 11;
|
|
2776
|
+
suspendResult = parsePartHeadersImpl(this.n5x_1, this);
|
|
2777
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2778
|
+
return suspendResult;
|
|
2779
|
+
}
|
|
2780
|
+
|
|
2781
|
+
continue $sm;
|
|
2782
|
+
case 11:
|
|
2783
|
+
this.w5x_1 = suspendResult;
|
|
2784
|
+
if (!this.u5x_1.n24(this.w5x_1)) {
|
|
2785
|
+
this.w5x_1.m1h();
|
|
2786
|
+
throw CancellationException_init_$Create$('Multipart processing has been cancelled');
|
|
2787
|
+
}
|
|
2788
|
+
|
|
2789
|
+
this.x9_1 = 12;
|
|
2790
|
+
suspendResult = parsePartBodyImpl(this.j5x_1, this.n5x_1, this.t5x_1, this.w5x_1, this.k5x_1, this);
|
|
2791
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2792
|
+
return suspendResult;
|
|
2793
|
+
}
|
|
2794
|
+
|
|
2795
|
+
continue $sm;
|
|
2796
|
+
case 12:
|
|
2797
|
+
this.t5x_1.u4();
|
|
2798
|
+
this.y9_1 = 25;
|
|
2799
|
+
this.x9_1 = 13;
|
|
2800
|
+
continue $sm;
|
|
2801
|
+
case 13:
|
|
2802
|
+
this.y9_1 = 25;
|
|
2803
|
+
this.x9_1 = 4;
|
|
2804
|
+
continue $sm;
|
|
2805
|
+
case 14:
|
|
2806
|
+
this.y9_1 = 25;
|
|
2807
|
+
var tmp_0 = this.aa_1;
|
|
2808
|
+
if (tmp_0 instanceof Error) {
|
|
2809
|
+
this.x5x_1 = this.aa_1;
|
|
2810
|
+
if (this.u5x_1.x24(this.x5x_1)) {
|
|
2811
|
+
var tmp0_safe_receiver = this.w5x_1;
|
|
2812
|
+
if (tmp0_safe_receiver == null)
|
|
2813
|
+
null;
|
|
2814
|
+
else {
|
|
2815
|
+
tmp0_safe_receiver.m1h();
|
|
2816
|
+
}
|
|
2817
|
+
}
|
|
2818
|
+
close(this.t5x_1, this.x5x_1);
|
|
2819
|
+
throw this.x5x_1;
|
|
2820
|
+
} else {
|
|
2821
|
+
throw this.aa_1;
|
|
2822
|
+
}
|
|
2823
|
+
|
|
2824
|
+
case 15:
|
|
2825
|
+
this.x9_1 = 16;
|
|
2826
|
+
suspendResult = skipIfFound(this.n5x_1, get_CrLf_0(), this);
|
|
2827
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2828
|
+
return suspendResult;
|
|
2829
|
+
}
|
|
2830
|
+
|
|
2831
|
+
continue $sm;
|
|
2832
|
+
case 16:
|
|
2833
|
+
this.x9_1 = 17;
|
|
2834
|
+
suspendResult = skipIfFound(this.n5x_1, get_CrLf_0(), this);
|
|
2835
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2836
|
+
return suspendResult;
|
|
2837
|
+
}
|
|
2838
|
+
|
|
2839
|
+
continue $sm;
|
|
2840
|
+
case 17:
|
|
2841
|
+
if (!(this.l5x_1 == null)) {
|
|
2842
|
+
this.y5x_1 = this.n5x_1.f4w().c3(this.o5x_1);
|
|
2843
|
+
this.z5x_1 = this.l5x_1.c3(this.y5x_1);
|
|
2844
|
+
if (this.z5x_1.j1(new Long(2147483647, 0)) > 0)
|
|
2845
|
+
throw IOException_init_$Create$('Failed to parse multipart: prologue is too long');
|
|
2846
|
+
if (this.z5x_1.j1(new Long(0, 0)) > 0) {
|
|
2847
|
+
this.x9_1 = 21;
|
|
2848
|
+
suspendResult = readPacket(this.n5x_1, this.z5x_1.l1(), this);
|
|
2849
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2850
|
+
return suspendResult;
|
|
2851
|
+
}
|
|
2852
|
+
continue $sm;
|
|
2853
|
+
} else {
|
|
2854
|
+
this.x9_1 = 23;
|
|
2855
|
+
continue $sm;
|
|
2856
|
+
}
|
|
2857
|
+
} else {
|
|
2858
|
+
this.x9_1 = 18;
|
|
2859
|
+
suspendResult = readRemaining(this.n5x_1, this);
|
|
2860
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2861
|
+
return suspendResult;
|
|
2862
|
+
}
|
|
2863
|
+
continue $sm;
|
|
2864
|
+
}
|
|
2865
|
+
|
|
2866
|
+
case 18:
|
|
2867
|
+
this.a5y_1 = suspendResult;
|
|
2868
|
+
if (!this.a5y_1.r3a()) {
|
|
2869
|
+
this.x9_1 = 19;
|
|
2870
|
+
suspendResult = this.m5x_1.m2i(new Epilogue(this.a5y_1), this);
|
|
2871
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2872
|
+
return suspendResult;
|
|
2873
|
+
}
|
|
2874
|
+
continue $sm;
|
|
2875
|
+
} else {
|
|
2876
|
+
this.x9_1 = 20;
|
|
2877
|
+
continue $sm;
|
|
2878
|
+
}
|
|
2879
|
+
|
|
2880
|
+
case 19:
|
|
2881
|
+
this.x9_1 = 20;
|
|
2882
|
+
continue $sm;
|
|
2883
|
+
case 20:
|
|
2884
|
+
this.x9_1 = 24;
|
|
2885
|
+
continue $sm;
|
|
2886
|
+
case 21:
|
|
2887
|
+
this.b5y_1 = suspendResult;
|
|
2888
|
+
this.c5y_1 = new Epilogue(this.b5y_1);
|
|
2889
|
+
this.x9_1 = 22;
|
|
2890
|
+
suspendResult = this.m5x_1.m2i(this.c5y_1, this);
|
|
2891
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2892
|
+
return suspendResult;
|
|
2893
|
+
}
|
|
2894
|
+
|
|
2895
|
+
continue $sm;
|
|
2896
|
+
case 22:
|
|
2897
|
+
this.x9_1 = 23;
|
|
2898
|
+
continue $sm;
|
|
2899
|
+
case 23:
|
|
2900
|
+
this.x9_1 = 24;
|
|
2901
|
+
continue $sm;
|
|
2902
|
+
case 24:
|
|
2903
|
+
return Unit_instance;
|
|
2904
|
+
case 25:
|
|
2905
|
+
throw this.aa_1;
|
|
2906
|
+
}
|
|
2907
|
+
} catch ($p) {
|
|
2908
|
+
var e = $p;
|
|
2909
|
+
if (this.y9_1 === 25) {
|
|
2910
|
+
throw e;
|
|
2911
|
+
} else {
|
|
2912
|
+
this.x9_1 = this.y9_1;
|
|
2913
|
+
this.aa_1 = e;
|
|
2914
|
+
}
|
|
2915
|
+
}
|
|
2916
|
+
while (true);
|
|
2917
|
+
};
|
|
2918
|
+
protoOf(parseMultipart$slambda).e5y = function ($this$produce, completion) {
|
|
2919
|
+
var i = new parseMultipart$slambda(this.i5x_1, this.j5x_1, this.k5x_1, this.l5x_1, completion);
|
|
2920
|
+
i.m5x_1 = $this$produce;
|
|
2921
|
+
return i;
|
|
2922
|
+
};
|
|
2923
|
+
function parseMultipart$slambda_0($input, $boundaryPrefixed, $maxPartSize, $totalLength, resultContinuation) {
|
|
2924
|
+
var i = new parseMultipart$slambda($input, $boundaryPrefixed, $maxPartSize, $totalLength, resultContinuation);
|
|
2925
|
+
var l = function ($this$produce, $completion) {
|
|
2926
|
+
return i.d5y($this$produce, $completion);
|
|
2927
|
+
};
|
|
2928
|
+
l.$arity = 1;
|
|
2929
|
+
return l;
|
|
2930
|
+
}
|
|
2931
|
+
function $parsePartHeadersImplCOROUTINE$(input, resultContinuation) {
|
|
2932
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
2933
|
+
this.i5v_1 = input;
|
|
2934
|
+
}
|
|
2935
|
+
protoOf($parsePartHeadersImplCOROUTINE$).fa = function () {
|
|
2936
|
+
var suspendResult = this.z9_1;
|
|
2937
|
+
$sm: do
|
|
2938
|
+
try {
|
|
2939
|
+
var tmp = this.x9_1;
|
|
2940
|
+
switch (tmp) {
|
|
2941
|
+
case 0:
|
|
2942
|
+
this.y9_1 = 3;
|
|
2943
|
+
this.j5v_1 = new CharArrayBuilder();
|
|
2944
|
+
this.y9_1 = 2;
|
|
2945
|
+
this.x9_1 = 1;
|
|
2946
|
+
suspendResult = parseHeaders(this.i5v_1, this.j5v_1, VOID, this);
|
|
2947
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
2948
|
+
return suspendResult;
|
|
2949
|
+
}
|
|
2950
|
+
|
|
2951
|
+
continue $sm;
|
|
2952
|
+
case 1:
|
|
2953
|
+
var tmp0_elvis_lhs = suspendResult;
|
|
2954
|
+
var tmp_0;
|
|
2955
|
+
if (tmp0_elvis_lhs == null) {
|
|
2956
|
+
throw EOFException_init_$Create$('Failed to parse multipart headers: unexpected end of stream');
|
|
2957
|
+
} else {
|
|
2958
|
+
tmp_0 = tmp0_elvis_lhs;
|
|
2959
|
+
}
|
|
2960
|
+
|
|
2961
|
+
return tmp_0;
|
|
2962
|
+
case 2:
|
|
2963
|
+
this.y9_1 = 3;
|
|
2964
|
+
var tmp_1 = this.aa_1;
|
|
2965
|
+
if (tmp_1 instanceof Error) {
|
|
2966
|
+
var t = this.aa_1;
|
|
2967
|
+
this.j5v_1.m1h();
|
|
2968
|
+
throw t;
|
|
2969
|
+
} else {
|
|
2970
|
+
throw this.aa_1;
|
|
2971
|
+
}
|
|
2972
|
+
|
|
2973
|
+
case 3:
|
|
2974
|
+
throw this.aa_1;
|
|
2975
|
+
}
|
|
2976
|
+
} catch ($p) {
|
|
2977
|
+
var e = $p;
|
|
2978
|
+
if (this.y9_1 === 3) {
|
|
2979
|
+
throw e;
|
|
2980
|
+
} else {
|
|
2981
|
+
this.x9_1 = this.y9_1;
|
|
2982
|
+
this.aa_1 = e;
|
|
2983
|
+
}
|
|
2984
|
+
}
|
|
2985
|
+
while (true);
|
|
2986
|
+
};
|
|
2987
|
+
function $parsePartBodyImplCOROUTINE$(boundaryPrefixed, input, output, headers, limit, resultContinuation) {
|
|
2988
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
2989
|
+
this.s5v_1 = boundaryPrefixed;
|
|
2990
|
+
this.t5v_1 = input;
|
|
2991
|
+
this.u5v_1 = output;
|
|
2992
|
+
this.v5v_1 = headers;
|
|
2993
|
+
this.w5v_1 = limit;
|
|
2994
|
+
}
|
|
2995
|
+
protoOf($parsePartBodyImplCOROUTINE$).fa = function () {
|
|
2996
|
+
var suspendResult = this.z9_1;
|
|
2997
|
+
$sm: do
|
|
2998
|
+
try {
|
|
2999
|
+
var tmp = this.x9_1;
|
|
3000
|
+
switch (tmp) {
|
|
3001
|
+
case 0:
|
|
3002
|
+
this.y9_1 = 6;
|
|
3003
|
+
var tmp_0 = this;
|
|
3004
|
+
var tmp0_safe_receiver = this.v5v_1.cf('Content-Length');
|
|
3005
|
+
tmp_0.x5v_1 = tmp0_safe_receiver == null ? null : parseDecLong(tmp0_safe_receiver);
|
|
3006
|
+
if (this.x5v_1 == null) {
|
|
3007
|
+
this.x9_1 = 3;
|
|
3008
|
+
suspendResult = readUntil(this.t5v_1, this.s5v_1, this.u5v_1, this.w5v_1, true, this);
|
|
3009
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
3010
|
+
return suspendResult;
|
|
3011
|
+
}
|
|
3012
|
+
continue $sm;
|
|
3013
|
+
} else {
|
|
3014
|
+
if ((new Long(0, 0)).k3(this.w5v_1).oo(this.x5v_1)) {
|
|
3015
|
+
this.x9_1 = 1;
|
|
3016
|
+
suspendResult = copyTo(this.t5v_1, this.u5v_1, this.x5v_1, this);
|
|
3017
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
3018
|
+
return suspendResult;
|
|
3019
|
+
}
|
|
3020
|
+
continue $sm;
|
|
3021
|
+
} else {
|
|
3022
|
+
var tmp_1 = this;
|
|
3023
|
+
throwLimitExceeded(this.x5v_1, this.w5v_1);
|
|
3024
|
+
}
|
|
3025
|
+
}
|
|
3026
|
+
|
|
3027
|
+
break;
|
|
3028
|
+
case 1:
|
|
3029
|
+
this.z5v_1 = suspendResult;
|
|
3030
|
+
this.x9_1 = 2;
|
|
3031
|
+
suspendResult = skipIfFoundReadCount(this.t5v_1, this.s5v_1, this);
|
|
3032
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
3033
|
+
return suspendResult;
|
|
3034
|
+
}
|
|
3035
|
+
|
|
3036
|
+
continue $sm;
|
|
3037
|
+
case 2:
|
|
3038
|
+
this.a5w_1 = suspendResult;
|
|
3039
|
+
this.y5v_1 = this.z5v_1.b3(this.a5w_1);
|
|
3040
|
+
this.x9_1 = 4;
|
|
3041
|
+
continue $sm;
|
|
3042
|
+
case 3:
|
|
3043
|
+
this.y5v_1 = suspendResult;
|
|
3044
|
+
this.x9_1 = 4;
|
|
3045
|
+
continue $sm;
|
|
3046
|
+
case 4:
|
|
3047
|
+
this.b5w_1 = this.y5v_1;
|
|
3048
|
+
this.x9_1 = 5;
|
|
3049
|
+
suspendResult = this.u5v_1.c4i(this);
|
|
3050
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
3051
|
+
return suspendResult;
|
|
3052
|
+
}
|
|
3053
|
+
|
|
3054
|
+
continue $sm;
|
|
3055
|
+
case 5:
|
|
3056
|
+
return this.b5w_1;
|
|
3057
|
+
case 6:
|
|
3058
|
+
throw this.aa_1;
|
|
3059
|
+
}
|
|
3060
|
+
} catch ($p) {
|
|
3061
|
+
var e = $p;
|
|
3062
|
+
if (this.y9_1 === 6) {
|
|
3063
|
+
throw e;
|
|
3064
|
+
} else {
|
|
3065
|
+
this.x9_1 = this.y9_1;
|
|
3066
|
+
this.aa_1 = e;
|
|
3067
|
+
}
|
|
3068
|
+
}
|
|
3069
|
+
while (true);
|
|
3070
|
+
};
|
|
3071
|
+
function $skipIfFoundReadCountCOROUTINE$(_this__u8e3s4, prefix, resultContinuation) {
|
|
3072
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
3073
|
+
this.k5w_1 = _this__u8e3s4;
|
|
3074
|
+
this.l5w_1 = prefix;
|
|
3075
|
+
}
|
|
3076
|
+
protoOf($skipIfFoundReadCountCOROUTINE$).fa = function () {
|
|
3077
|
+
var suspendResult = this.z9_1;
|
|
3078
|
+
$sm: do
|
|
3079
|
+
try {
|
|
3080
|
+
var tmp = this.x9_1;
|
|
3081
|
+
switch (tmp) {
|
|
3082
|
+
case 0:
|
|
3083
|
+
this.y9_1 = 3;
|
|
3084
|
+
this.x9_1 = 1;
|
|
3085
|
+
suspendResult = skipIfFound(this.k5w_1, this.l5w_1, this);
|
|
3086
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
3087
|
+
return suspendResult;
|
|
3088
|
+
}
|
|
3089
|
+
|
|
3090
|
+
continue $sm;
|
|
3091
|
+
case 1:
|
|
3092
|
+
if (suspendResult) {
|
|
3093
|
+
var tmp_0 = this;
|
|
3094
|
+
tmp_0.m5w_1 = toLong(this.l5w_1.s());
|
|
3095
|
+
this.x9_1 = 2;
|
|
3096
|
+
continue $sm;
|
|
3097
|
+
} else {
|
|
3098
|
+
var tmp_1 = this;
|
|
3099
|
+
tmp_1.m5w_1 = new Long(0, 0);
|
|
3100
|
+
this.x9_1 = 2;
|
|
3101
|
+
continue $sm;
|
|
3102
|
+
}
|
|
3103
|
+
|
|
3104
|
+
case 2:
|
|
3105
|
+
return this.m5w_1;
|
|
3106
|
+
case 3:
|
|
3107
|
+
throw this.aa_1;
|
|
3108
|
+
}
|
|
3109
|
+
} catch ($p) {
|
|
3110
|
+
var e = $p;
|
|
3111
|
+
if (this.y9_1 === 3) {
|
|
3112
|
+
throw e;
|
|
3113
|
+
} else {
|
|
3114
|
+
this.x9_1 = this.y9_1;
|
|
3115
|
+
this.aa_1 = e;
|
|
3116
|
+
}
|
|
3117
|
+
}
|
|
3118
|
+
while (true);
|
|
3119
|
+
};
|
|
3120
|
+
var properties_initialized_Multipart_kt_wu0sh0;
|
|
3121
|
+
function _init_properties_Multipart_kt__ato98a() {
|
|
3122
|
+
if (!properties_initialized_Multipart_kt_wu0sh0) {
|
|
3123
|
+
properties_initialized_Multipart_kt_wu0sh0 = true;
|
|
3124
|
+
CrLf_0 = ByteString_init_$Create$(toByteArray('\r\n'));
|
|
3125
|
+
PrefixString = ByteString(new Int8Array([45, 45]));
|
|
3126
|
+
}
|
|
3127
|
+
}
|
|
3128
|
+
function Request(method, uri, version, headers, builder) {
|
|
3129
|
+
HttpMessage.call(this, headers, builder);
|
|
3130
|
+
this.h5y_1 = method;
|
|
3131
|
+
this.i5y_1 = uri;
|
|
3132
|
+
this.j5y_1 = version;
|
|
3133
|
+
}
|
|
3134
|
+
function HttpMessage(headers, builder) {
|
|
3135
|
+
this.k5y_1 = headers;
|
|
3136
|
+
this.l5y_1 = builder;
|
|
3137
|
+
}
|
|
3138
|
+
protoOf(HttpMessage).m1h = function () {
|
|
3139
|
+
this.l5y_1.m1h();
|
|
3140
|
+
this.k5y_1.m1h();
|
|
3141
|
+
};
|
|
3142
|
+
protoOf(HttpMessage).u4 = function () {
|
|
3143
|
+
this.m1h();
|
|
3144
|
+
};
|
|
3145
|
+
function build_0($this, resultList, from, maxLength, idx, length, charAt) {
|
|
3146
|
+
// Inline function 'kotlin.collections.groupBy' call
|
|
3147
|
+
// Inline function 'kotlin.collections.groupByTo' call
|
|
3148
|
+
var destination = LinkedHashMap_init_$Create$();
|
|
3149
|
+
var _iterator__ex2g4s = from.p();
|
|
3150
|
+
while (_iterator__ex2g4s.q()) {
|
|
3151
|
+
var element = _iterator__ex2g4s.r();
|
|
3152
|
+
var key = charAt(element, idx);
|
|
3153
|
+
// Inline function 'kotlin.collections.getOrPut' call
|
|
3154
|
+
var value = destination.j2(key);
|
|
3155
|
+
var tmp;
|
|
3156
|
+
if (value == null) {
|
|
3157
|
+
var answer = ArrayList_init_$Create$();
|
|
3158
|
+
destination.r2(key, answer);
|
|
3159
|
+
tmp = answer;
|
|
3160
|
+
} else {
|
|
3161
|
+
tmp = value;
|
|
3162
|
+
}
|
|
3163
|
+
var list = tmp;
|
|
3164
|
+
list.h(element);
|
|
3165
|
+
}
|
|
3166
|
+
// Inline function 'kotlin.collections.forEach' call
|
|
3167
|
+
// Inline function 'kotlin.collections.iterator' call
|
|
3168
|
+
var _iterator__ex2g4s_0 = destination.z().p();
|
|
3169
|
+
while (_iterator__ex2g4s_0.q()) {
|
|
3170
|
+
var element_0 = _iterator__ex2g4s_0.r();
|
|
3171
|
+
// Inline function 'kotlin.collections.component1' call
|
|
3172
|
+
var ch = element_0.a1().t1_1;
|
|
3173
|
+
// Inline function 'kotlin.collections.component2' call
|
|
3174
|
+
var list_0 = element_0.b1();
|
|
3175
|
+
var nextIdx = idx + 1 | 0;
|
|
3176
|
+
var children = ArrayList_init_$Create$();
|
|
3177
|
+
var tmp_0 = Companion_instance_0;
|
|
3178
|
+
// Inline function 'kotlin.collections.filter' call
|
|
3179
|
+
// Inline function 'kotlin.collections.filterTo' call
|
|
3180
|
+
var destination_0 = ArrayList_init_$Create$();
|
|
3181
|
+
var _iterator__ex2g4s_1 = list_0.p();
|
|
3182
|
+
while (_iterator__ex2g4s_1.q()) {
|
|
3183
|
+
var element_1 = _iterator__ex2g4s_1.r();
|
|
3184
|
+
if (length(element_1) > nextIdx) {
|
|
3185
|
+
destination_0.h(element_1);
|
|
3186
|
+
}
|
|
3187
|
+
}
|
|
3188
|
+
build_0(tmp_0, children, destination_0, maxLength, nextIdx, length, charAt);
|
|
3189
|
+
children.g6();
|
|
3190
|
+
// Inline function 'kotlin.collections.filter' call
|
|
3191
|
+
// Inline function 'kotlin.collections.filterTo' call
|
|
3192
|
+
var destination_1 = ArrayList_init_$Create$();
|
|
3193
|
+
var _iterator__ex2g4s_2 = list_0.p();
|
|
3194
|
+
while (_iterator__ex2g4s_2.q()) {
|
|
3195
|
+
var element_2 = _iterator__ex2g4s_2.r();
|
|
3196
|
+
if (length(element_2) === nextIdx) {
|
|
3197
|
+
destination_1.h(element_2);
|
|
3198
|
+
}
|
|
3199
|
+
}
|
|
3200
|
+
resultList.h(new Node(ch, destination_1, children));
|
|
3201
|
+
}
|
|
3202
|
+
}
|
|
3203
|
+
function AsciiCharTree$Companion$build$lambda(it) {
|
|
3204
|
+
return charSequenceLength(it);
|
|
3205
|
+
}
|
|
3206
|
+
function AsciiCharTree$Companion$build$lambda_0(s, idx) {
|
|
3207
|
+
return new Char(charSequenceGet(s, idx));
|
|
3208
|
+
}
|
|
3209
|
+
function Node(ch, exact, children) {
|
|
3210
|
+
this.m5y_1 = ch;
|
|
3211
|
+
this.n5y_1 = exact;
|
|
3212
|
+
this.o5y_1 = children;
|
|
3213
|
+
var tmp = this;
|
|
3214
|
+
var tmp_0 = 0;
|
|
3215
|
+
// Inline function 'kotlin.arrayOfNulls' call
|
|
3216
|
+
var tmp_1 = Array(256);
|
|
3217
|
+
while (tmp_0 < 256) {
|
|
3218
|
+
var tmp_2 = tmp_0;
|
|
3219
|
+
var tmp0 = this.o5y_1;
|
|
3220
|
+
var tmp$ret$3;
|
|
3221
|
+
$l$block_0: {
|
|
3222
|
+
// Inline function 'kotlin.collections.singleOrNull' call
|
|
3223
|
+
var single = null;
|
|
3224
|
+
var found = false;
|
|
3225
|
+
var _iterator__ex2g4s = tmp0.p();
|
|
3226
|
+
while (_iterator__ex2g4s.q()) {
|
|
3227
|
+
var element = _iterator__ex2g4s.r();
|
|
3228
|
+
// Inline function 'kotlin.code' call
|
|
3229
|
+
var this_0 = element.m5y_1;
|
|
3230
|
+
if (Char__toInt_impl_vasixd(this_0) === tmp_2) {
|
|
3231
|
+
if (found) {
|
|
3232
|
+
tmp$ret$3 = null;
|
|
3233
|
+
break $l$block_0;
|
|
3234
|
+
}
|
|
3235
|
+
single = element;
|
|
3236
|
+
found = true;
|
|
3237
|
+
}
|
|
3238
|
+
}
|
|
3239
|
+
if (!found) {
|
|
3240
|
+
tmp$ret$3 = null;
|
|
3241
|
+
break $l$block_0;
|
|
3242
|
+
}
|
|
3243
|
+
tmp$ret$3 = single;
|
|
3244
|
+
}
|
|
3245
|
+
tmp_1[tmp_2] = tmp$ret$3;
|
|
3246
|
+
tmp_0 = tmp_0 + 1 | 0;
|
|
3247
|
+
}
|
|
3248
|
+
tmp.p5y_1 = tmp_1;
|
|
3249
|
+
}
|
|
3250
|
+
function Companion_0() {
|
|
3251
|
+
}
|
|
3252
|
+
protoOf(Companion_0).x5u = function (from) {
|
|
3253
|
+
var tmp = AsciiCharTree$Companion$build$lambda;
|
|
3254
|
+
return this.c5r(from, tmp, AsciiCharTree$Companion$build$lambda_0);
|
|
3255
|
+
};
|
|
3256
|
+
protoOf(Companion_0).c5r = function (from, length, charAt) {
|
|
3257
|
+
var tmp$ret$0;
|
|
3258
|
+
$l$block_0: {
|
|
3259
|
+
// Inline function 'kotlin.collections.maxByOrNull' call
|
|
3260
|
+
var iterator = from.p();
|
|
3261
|
+
if (!iterator.q()) {
|
|
3262
|
+
tmp$ret$0 = null;
|
|
3263
|
+
break $l$block_0;
|
|
3264
|
+
}
|
|
3265
|
+
var maxElem = iterator.r();
|
|
3266
|
+
if (!iterator.q()) {
|
|
3267
|
+
tmp$ret$0 = maxElem;
|
|
3268
|
+
break $l$block_0;
|
|
3269
|
+
}
|
|
3270
|
+
var maxValue = length(maxElem);
|
|
3271
|
+
do {
|
|
3272
|
+
var e = iterator.r();
|
|
3273
|
+
var v = length(e);
|
|
3274
|
+
if (compareTo(maxValue, v) < 0) {
|
|
3275
|
+
maxElem = e;
|
|
3276
|
+
maxValue = v;
|
|
3277
|
+
}
|
|
3278
|
+
}
|
|
3279
|
+
while (iterator.q());
|
|
3280
|
+
tmp$ret$0 = maxElem;
|
|
3281
|
+
}
|
|
3282
|
+
var tmp0_safe_receiver = tmp$ret$0;
|
|
3283
|
+
var tmp;
|
|
3284
|
+
if (tmp0_safe_receiver == null) {
|
|
3285
|
+
tmp = null;
|
|
3286
|
+
} else {
|
|
3287
|
+
// Inline function 'kotlin.let' call
|
|
3288
|
+
tmp = length(tmp0_safe_receiver);
|
|
3289
|
+
}
|
|
3290
|
+
var tmp1_elvis_lhs = tmp;
|
|
3291
|
+
var tmp_0;
|
|
3292
|
+
if (tmp1_elvis_lhs == null) {
|
|
3293
|
+
throw NoSuchElementException_init_$Create$('Unable to build char tree from an empty list');
|
|
3294
|
+
} else {
|
|
3295
|
+
tmp_0 = tmp1_elvis_lhs;
|
|
3296
|
+
}
|
|
3297
|
+
var maxLen = tmp_0;
|
|
3298
|
+
var tmp$ret$2;
|
|
3299
|
+
$l$block_2: {
|
|
3300
|
+
// Inline function 'kotlin.collections.any' call
|
|
3301
|
+
var tmp_1;
|
|
3302
|
+
if (isInterface(from, Collection)) {
|
|
3303
|
+
tmp_1 = from.m();
|
|
3304
|
+
} else {
|
|
3305
|
+
tmp_1 = false;
|
|
3306
|
+
}
|
|
3307
|
+
if (tmp_1) {
|
|
3308
|
+
tmp$ret$2 = false;
|
|
3309
|
+
break $l$block_2;
|
|
3310
|
+
}
|
|
3311
|
+
var _iterator__ex2g4s = from.p();
|
|
3312
|
+
while (_iterator__ex2g4s.q()) {
|
|
3313
|
+
var element = _iterator__ex2g4s.r();
|
|
3314
|
+
if (length(element) === 0) {
|
|
3315
|
+
tmp$ret$2 = true;
|
|
3316
|
+
break $l$block_2;
|
|
3317
|
+
}
|
|
3318
|
+
}
|
|
3319
|
+
tmp$ret$2 = false;
|
|
3320
|
+
}
|
|
3321
|
+
if (tmp$ret$2)
|
|
3322
|
+
throw IllegalArgumentException_init_$Create$('There should be no empty entries');
|
|
3323
|
+
var root = ArrayList_init_$Create$();
|
|
3324
|
+
build_0(this, root, from, maxLen, 0, length, charAt);
|
|
3325
|
+
root.g6();
|
|
3326
|
+
return new AsciiCharTree(new Node(_Char___init__impl__6a9atx(0), emptyList(), root));
|
|
3327
|
+
};
|
|
3328
|
+
var Companion_instance_0;
|
|
3329
|
+
function Companion_getInstance_4() {
|
|
3330
|
+
return Companion_instance_0;
|
|
3331
|
+
}
|
|
3332
|
+
function AsciiCharTree(root) {
|
|
3333
|
+
this.w5q_1 = root;
|
|
3334
|
+
}
|
|
3335
|
+
protoOf(AsciiCharTree).x5q = function (sequence, fromIdx, end, lowerCase, stopPredicate) {
|
|
3336
|
+
// Inline function 'kotlin.text.isEmpty' call
|
|
3337
|
+
if (charSequenceLength(sequence) === 0)
|
|
3338
|
+
throw IllegalArgumentException_init_$Create$("Couldn't search in char tree for empty string");
|
|
3339
|
+
var node = this.w5q_1;
|
|
3340
|
+
var inductionVariable = fromIdx;
|
|
3341
|
+
if (inductionVariable < end)
|
|
3342
|
+
$l$loop: do {
|
|
3343
|
+
var index = inductionVariable;
|
|
3344
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
3345
|
+
var current = charSequenceGet(sequence, index);
|
|
3346
|
+
// Inline function 'kotlin.code' call
|
|
3347
|
+
var currentCode = Char__toInt_impl_vasixd(current);
|
|
3348
|
+
if (stopPredicate(new Char(current), currentCode))
|
|
3349
|
+
break $l$loop;
|
|
3350
|
+
var tmp0_elvis_lhs = node.p5y_1[currentCode];
|
|
3351
|
+
var tmp;
|
|
3352
|
+
if (tmp0_elvis_lhs == null) {
|
|
3353
|
+
var tmp_0;
|
|
3354
|
+
if (lowerCase) {
|
|
3355
|
+
var tmp_1 = node.p5y_1;
|
|
3356
|
+
// Inline function 'kotlin.text.lowercaseChar' call
|
|
3357
|
+
// Inline function 'kotlin.text.lowercase' call
|
|
3358
|
+
// Inline function 'kotlin.js.asDynamic' call
|
|
3359
|
+
// Inline function 'kotlin.js.unsafeCast' call
|
|
3360
|
+
var tmp$ret$4 = toString_1(current).toLowerCase();
|
|
3361
|
+
// Inline function 'kotlin.code' call
|
|
3362
|
+
var this_0 = charCodeAt(tmp$ret$4, 0);
|
|
3363
|
+
tmp_0 = tmp_1[Char__toInt_impl_vasixd(this_0)];
|
|
3364
|
+
} else {
|
|
3365
|
+
tmp_0 = null;
|
|
3366
|
+
}
|
|
3367
|
+
tmp = tmp_0;
|
|
3368
|
+
} else {
|
|
3369
|
+
tmp = tmp0_elvis_lhs;
|
|
3370
|
+
}
|
|
3371
|
+
var tmp1_elvis_lhs = tmp;
|
|
3372
|
+
var tmp_2;
|
|
3373
|
+
if (tmp1_elvis_lhs == null) {
|
|
3374
|
+
return emptyList();
|
|
3375
|
+
} else {
|
|
3376
|
+
tmp_2 = tmp1_elvis_lhs;
|
|
3377
|
+
}
|
|
3378
|
+
var nextNode = tmp_2;
|
|
3379
|
+
node = nextNode;
|
|
3380
|
+
}
|
|
3381
|
+
while (inductionVariable < end);
|
|
3382
|
+
return node.n5y_1;
|
|
3383
|
+
};
|
|
3384
|
+
protoOf(AsciiCharTree).e5r = function (sequence, fromIdx, end, lowerCase, stopPredicate, $super) {
|
|
3385
|
+
fromIdx = fromIdx === VOID ? 0 : fromIdx;
|
|
3386
|
+
end = end === VOID ? charSequenceLength(sequence) : end;
|
|
3387
|
+
lowerCase = lowerCase === VOID ? false : lowerCase;
|
|
3388
|
+
return $super === VOID ? this.x5q(sequence, fromIdx, end, lowerCase, stopPredicate) : $super.x5q.call(this, sequence, fromIdx, end, lowerCase, stopPredicate);
|
|
3389
|
+
};
|
|
3390
|
+
function getImpl($this, index) {
|
|
3391
|
+
return bufferForIndex($this, index)[index % ensureNotNull($this.h5t_1).length | 0];
|
|
3392
|
+
}
|
|
3393
|
+
function copy($this, startIndex, endIndex) {
|
|
3394
|
+
if (startIndex === endIndex)
|
|
3395
|
+
return '';
|
|
3396
|
+
var builder = StringBuilder_init_$Create$(endIndex - startIndex | 0);
|
|
3397
|
+
var buffer;
|
|
3398
|
+
var base = startIndex - (startIndex % 2048 | 0) | 0;
|
|
3399
|
+
while (base < endIndex) {
|
|
3400
|
+
buffer = bufferForIndex($this, base);
|
|
3401
|
+
// Inline function 'kotlin.comparisons.maxOf' call
|
|
3402
|
+
var b = startIndex - base | 0;
|
|
3403
|
+
var innerStartIndex = Math.max(0, b);
|
|
3404
|
+
// Inline function 'kotlin.comparisons.minOf' call
|
|
3405
|
+
var a = endIndex - base | 0;
|
|
3406
|
+
var innerEndIndex = Math.min(a, 2048);
|
|
3407
|
+
var inductionVariable = innerStartIndex;
|
|
3408
|
+
if (inductionVariable < innerEndIndex)
|
|
3409
|
+
do {
|
|
3410
|
+
var innerIndex = inductionVariable;
|
|
3411
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
3412
|
+
builder.a9(buffer[innerIndex]);
|
|
3413
|
+
}
|
|
3414
|
+
while (inductionVariable < innerEndIndex);
|
|
3415
|
+
base = base + 2048 | 0;
|
|
3416
|
+
}
|
|
3417
|
+
return builder;
|
|
3418
|
+
}
|
|
3419
|
+
function SubSequenceImpl($outer, start, end) {
|
|
3420
|
+
this.t5y_1 = $outer;
|
|
3421
|
+
this.q5y_1 = start;
|
|
3422
|
+
this.r5y_1 = end;
|
|
3423
|
+
this.s5y_1 = null;
|
|
3424
|
+
}
|
|
3425
|
+
protoOf(SubSequenceImpl).a = function () {
|
|
3426
|
+
return this.r5y_1 - this.q5y_1 | 0;
|
|
3427
|
+
};
|
|
3428
|
+
protoOf(SubSequenceImpl).b = function (index) {
|
|
3429
|
+
var withOffset = index + this.q5y_1 | 0;
|
|
3430
|
+
// Inline function 'kotlin.require' call
|
|
3431
|
+
if (!(index >= 0)) {
|
|
3432
|
+
var message = 'index is negative: ' + index;
|
|
3433
|
+
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
3434
|
+
}
|
|
3435
|
+
// Inline function 'kotlin.require' call
|
|
3436
|
+
if (!(withOffset < this.r5y_1)) {
|
|
3437
|
+
var message_0 = 'index (' + index + ') should be less than length (' + this.a() + ')';
|
|
3438
|
+
throw IllegalArgumentException_init_$Create$(toString(message_0));
|
|
3439
|
+
}
|
|
3440
|
+
return getImpl(this.t5y_1, withOffset);
|
|
3441
|
+
};
|
|
3442
|
+
protoOf(SubSequenceImpl).c = function (startIndex, endIndex) {
|
|
3443
|
+
// Inline function 'kotlin.require' call
|
|
3444
|
+
if (!(startIndex >= 0)) {
|
|
3445
|
+
var message = 'start is negative: ' + startIndex;
|
|
3446
|
+
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
3447
|
+
}
|
|
3448
|
+
// Inline function 'kotlin.require' call
|
|
3449
|
+
if (!(startIndex <= endIndex)) {
|
|
3450
|
+
var message_0 = 'start (' + startIndex + ') should be less or equal to end (' + endIndex + ')';
|
|
3451
|
+
throw IllegalArgumentException_init_$Create$(toString(message_0));
|
|
3452
|
+
}
|
|
3453
|
+
// Inline function 'kotlin.require' call
|
|
3454
|
+
if (!(endIndex <= (this.r5y_1 - this.q5y_1 | 0))) {
|
|
3455
|
+
var message_1 = 'end should be less than length (' + this.a() + ')';
|
|
3456
|
+
throw IllegalArgumentException_init_$Create$(toString(message_1));
|
|
3457
|
+
}
|
|
3458
|
+
if (startIndex === endIndex)
|
|
3459
|
+
return '';
|
|
3460
|
+
return new SubSequenceImpl(this.t5y_1, this.q5y_1 + startIndex | 0, this.q5y_1 + endIndex | 0);
|
|
3461
|
+
};
|
|
3462
|
+
protoOf(SubSequenceImpl).toString = function () {
|
|
3463
|
+
var tmp0_elvis_lhs = this.s5y_1;
|
|
3464
|
+
var tmp;
|
|
3465
|
+
if (tmp0_elvis_lhs == null) {
|
|
3466
|
+
// Inline function 'kotlin.also' call
|
|
3467
|
+
var this_0 = toString(copy(this.t5y_1, this.q5y_1, this.r5y_1));
|
|
3468
|
+
this.s5y_1 = this_0;
|
|
3469
|
+
tmp = this_0;
|
|
3470
|
+
} else {
|
|
3471
|
+
tmp = tmp0_elvis_lhs;
|
|
3472
|
+
}
|
|
3473
|
+
return tmp;
|
|
3474
|
+
};
|
|
3475
|
+
protoOf(SubSequenceImpl).equals = function (other) {
|
|
3476
|
+
if (!(!(other == null) ? isCharSequence(other) : false))
|
|
3477
|
+
return false;
|
|
3478
|
+
if (!(charSequenceLength(other) === this.a()))
|
|
3479
|
+
return false;
|
|
3480
|
+
return rangeEqualsImpl(this.t5y_1, this.q5y_1, other, 0, this.a());
|
|
3481
|
+
};
|
|
3482
|
+
protoOf(SubSequenceImpl).hashCode = function () {
|
|
3483
|
+
var tmp0_safe_receiver = this.s5y_1;
|
|
3484
|
+
var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : getStringHashCode(tmp0_safe_receiver);
|
|
3485
|
+
return tmp1_elvis_lhs == null ? hashCodeImpl(this.t5y_1, this.q5y_1, this.r5y_1) : tmp1_elvis_lhs;
|
|
3486
|
+
};
|
|
3487
|
+
function bufferForIndex($this, index) {
|
|
3488
|
+
var list = $this.g5t_1;
|
|
3489
|
+
if (list == null) {
|
|
3490
|
+
if (index >= 2048) {
|
|
3491
|
+
throwSingleBuffer($this, index);
|
|
3492
|
+
}
|
|
3493
|
+
var tmp0_elvis_lhs = $this.h5t_1;
|
|
3494
|
+
var tmp;
|
|
3495
|
+
if (tmp0_elvis_lhs == null) {
|
|
3496
|
+
throwSingleBuffer($this, index);
|
|
3497
|
+
} else {
|
|
3498
|
+
tmp = tmp0_elvis_lhs;
|
|
3499
|
+
}
|
|
3500
|
+
return tmp;
|
|
3501
|
+
}
|
|
3502
|
+
return list.u(index / ensureNotNull($this.h5t_1).length | 0);
|
|
3503
|
+
}
|
|
3504
|
+
function throwSingleBuffer($this, index) {
|
|
3505
|
+
if ($this.j5t_1)
|
|
3506
|
+
throw IllegalStateException_init_$Create$('Buffer is already released');
|
|
3507
|
+
throw IndexOutOfBoundsException_init_$Create$('' + index + ' is not in range [0; ' + currentPosition($this) + ')');
|
|
3508
|
+
}
|
|
3509
|
+
function nonFullBuffer($this) {
|
|
3510
|
+
return $this.k5t_1 === 0 ? appendNewArray($this) : ensureNotNull($this.h5t_1);
|
|
3511
|
+
}
|
|
3512
|
+
function appendNewArray($this) {
|
|
3513
|
+
var newBuffer = $this.f5t_1.w4w();
|
|
3514
|
+
var existing = $this.h5t_1;
|
|
3515
|
+
$this.h5t_1 = newBuffer;
|
|
3516
|
+
$this.k5t_1 = newBuffer.length;
|
|
3517
|
+
$this.j5t_1 = false;
|
|
3518
|
+
if (!(existing == null)) {
|
|
3519
|
+
var tmp0_elvis_lhs = $this.g5t_1;
|
|
3520
|
+
var tmp;
|
|
3521
|
+
if (tmp0_elvis_lhs == null) {
|
|
3522
|
+
// Inline function 'kotlin.also' call
|
|
3523
|
+
var this_0 = ArrayList_init_$Create$();
|
|
3524
|
+
$this.g5t_1 = this_0;
|
|
3525
|
+
this_0.h(existing);
|
|
3526
|
+
tmp = this_0;
|
|
3527
|
+
} else {
|
|
3528
|
+
tmp = tmp0_elvis_lhs;
|
|
3529
|
+
}
|
|
3530
|
+
var list = tmp;
|
|
3531
|
+
list.h(newBuffer);
|
|
3532
|
+
}
|
|
3533
|
+
return newBuffer;
|
|
3534
|
+
}
|
|
3535
|
+
function rangeEqualsImpl($this, start, other, otherStart, length) {
|
|
3536
|
+
var inductionVariable = 0;
|
|
3537
|
+
if (inductionVariable < length)
|
|
3538
|
+
do {
|
|
3539
|
+
var i = inductionVariable;
|
|
3540
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
3541
|
+
if (!(getImpl($this, start + i | 0) === charSequenceGet(other, otherStart + i | 0)))
|
|
3542
|
+
return false;
|
|
3543
|
+
}
|
|
3544
|
+
while (inductionVariable < length);
|
|
3545
|
+
return true;
|
|
3546
|
+
}
|
|
3547
|
+
function hashCodeImpl($this, start, end) {
|
|
3548
|
+
var hc = 0;
|
|
3549
|
+
var inductionVariable = start;
|
|
3550
|
+
if (inductionVariable < end)
|
|
3551
|
+
do {
|
|
3552
|
+
var i = inductionVariable;
|
|
3553
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
3554
|
+
var tmp = imul(31, hc);
|
|
3555
|
+
// Inline function 'kotlin.code' call
|
|
3556
|
+
var this_0 = getImpl($this, i);
|
|
3557
|
+
hc = tmp + Char__toInt_impl_vasixd(this_0) | 0;
|
|
3558
|
+
}
|
|
3559
|
+
while (inductionVariable < end);
|
|
3560
|
+
return hc;
|
|
3561
|
+
}
|
|
3562
|
+
function currentPosition($this) {
|
|
3563
|
+
return ensureNotNull($this.h5t_1).length - $this.k5t_1 | 0;
|
|
3564
|
+
}
|
|
3565
|
+
function CharArrayBuilder(pool) {
|
|
3566
|
+
pool = pool === VOID ? get_CharArrayPool() : pool;
|
|
3567
|
+
this.f5t_1 = pool;
|
|
3568
|
+
this.g5t_1 = null;
|
|
3569
|
+
this.h5t_1 = null;
|
|
3570
|
+
this.i5t_1 = null;
|
|
3571
|
+
this.j5t_1 = false;
|
|
3572
|
+
this.k5t_1 = 0;
|
|
3573
|
+
this.l5t_1 = 0;
|
|
3574
|
+
}
|
|
3575
|
+
protoOf(CharArrayBuilder).a = function () {
|
|
3576
|
+
return this.l5t_1;
|
|
3577
|
+
};
|
|
3578
|
+
protoOf(CharArrayBuilder).b = function (index) {
|
|
3579
|
+
// Inline function 'kotlin.require' call
|
|
3580
|
+
if (!(index >= 0)) {
|
|
3581
|
+
var message = 'index is negative: ' + index;
|
|
3582
|
+
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
3583
|
+
}
|
|
3584
|
+
// Inline function 'kotlin.require' call
|
|
3585
|
+
if (!(index < this.l5t_1)) {
|
|
3586
|
+
var message_0 = 'index ' + index + ' is not in range [0, ' + this.l5t_1 + ')';
|
|
3587
|
+
throw IllegalArgumentException_init_$Create$(toString(message_0));
|
|
3588
|
+
}
|
|
3589
|
+
return getImpl(this, index);
|
|
3590
|
+
};
|
|
3591
|
+
protoOf(CharArrayBuilder).c = function (startIndex, endIndex) {
|
|
3592
|
+
// Inline function 'kotlin.require' call
|
|
3593
|
+
if (!(startIndex <= endIndex)) {
|
|
3594
|
+
var message = 'startIndex (' + startIndex + ') should be less or equal to endIndex (' + endIndex + ')';
|
|
3595
|
+
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
3596
|
+
}
|
|
3597
|
+
// Inline function 'kotlin.require' call
|
|
3598
|
+
if (!(startIndex >= 0)) {
|
|
3599
|
+
var message_0 = 'startIndex is negative: ' + startIndex;
|
|
3600
|
+
throw IllegalArgumentException_init_$Create$(toString(message_0));
|
|
3601
|
+
}
|
|
3602
|
+
// Inline function 'kotlin.require' call
|
|
3603
|
+
if (!(endIndex <= this.l5t_1)) {
|
|
3604
|
+
var message_1 = 'endIndex (' + endIndex + ') is greater than length (' + this.l5t_1 + ')';
|
|
3605
|
+
throw IllegalArgumentException_init_$Create$(toString(message_1));
|
|
3606
|
+
}
|
|
3607
|
+
return new SubSequenceImpl(this, startIndex, endIndex);
|
|
3608
|
+
};
|
|
3609
|
+
protoOf(CharArrayBuilder).toString = function () {
|
|
3610
|
+
var tmp0_elvis_lhs = this.i5t_1;
|
|
3611
|
+
var tmp;
|
|
3612
|
+
if (tmp0_elvis_lhs == null) {
|
|
3613
|
+
// Inline function 'kotlin.also' call
|
|
3614
|
+
var this_0 = toString(copy(this, 0, this.l5t_1));
|
|
3615
|
+
this.i5t_1 = this_0;
|
|
3616
|
+
tmp = this_0;
|
|
3617
|
+
} else {
|
|
3618
|
+
tmp = tmp0_elvis_lhs;
|
|
3619
|
+
}
|
|
3620
|
+
return tmp;
|
|
3621
|
+
};
|
|
3622
|
+
protoOf(CharArrayBuilder).equals = function (other) {
|
|
3623
|
+
if (!(!(other == null) ? isCharSequence(other) : false))
|
|
3624
|
+
return false;
|
|
3625
|
+
if (!(this.l5t_1 === charSequenceLength(other)))
|
|
3626
|
+
return false;
|
|
3627
|
+
return rangeEqualsImpl(this, 0, other, 0, this.l5t_1);
|
|
3628
|
+
};
|
|
3629
|
+
protoOf(CharArrayBuilder).hashCode = function () {
|
|
3630
|
+
var tmp0_safe_receiver = this.i5t_1;
|
|
3631
|
+
var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : getStringHashCode(tmp0_safe_receiver);
|
|
3632
|
+
return tmp1_elvis_lhs == null ? hashCodeImpl(this, 0, this.l5t_1) : tmp1_elvis_lhs;
|
|
3633
|
+
};
|
|
3634
|
+
protoOf(CharArrayBuilder).a9 = function (value) {
|
|
3635
|
+
nonFullBuffer(this)[ensureNotNull(this.h5t_1).length - this.k5t_1 | 0] = value;
|
|
3636
|
+
this.i5t_1 = null;
|
|
3637
|
+
this.k5t_1 = this.k5t_1 - 1 | 0;
|
|
3638
|
+
this.l5t_1 = this.l5t_1 + 1 | 0;
|
|
3639
|
+
return this;
|
|
3640
|
+
};
|
|
3641
|
+
protoOf(CharArrayBuilder).pd = function (value, startIndex, endIndex) {
|
|
3642
|
+
if (value == null)
|
|
3643
|
+
return this;
|
|
3644
|
+
var current = startIndex;
|
|
3645
|
+
while (current < endIndex) {
|
|
3646
|
+
var buffer = nonFullBuffer(this);
|
|
3647
|
+
var offset = buffer.length - this.k5t_1 | 0;
|
|
3648
|
+
var tmp0 = endIndex - current | 0;
|
|
3649
|
+
// Inline function 'kotlin.math.min' call
|
|
3650
|
+
var b = this.k5t_1;
|
|
3651
|
+
var bytesToCopy = Math.min(tmp0, b);
|
|
3652
|
+
var inductionVariable = 0;
|
|
3653
|
+
if (inductionVariable < bytesToCopy)
|
|
3654
|
+
do {
|
|
3655
|
+
var i = inductionVariable;
|
|
3656
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
3657
|
+
buffer[offset + i | 0] = charSequenceGet(value, current + i | 0);
|
|
3658
|
+
}
|
|
3659
|
+
while (inductionVariable < bytesToCopy);
|
|
3660
|
+
current = current + bytesToCopy | 0;
|
|
3661
|
+
this.k5t_1 = this.k5t_1 - bytesToCopy | 0;
|
|
3662
|
+
}
|
|
3663
|
+
this.i5t_1 = null;
|
|
3664
|
+
this.l5t_1 = this.l5t_1 + (endIndex - startIndex | 0) | 0;
|
|
3665
|
+
return this;
|
|
3666
|
+
};
|
|
3667
|
+
protoOf(CharArrayBuilder).i = function (value) {
|
|
3668
|
+
if (value == null)
|
|
3669
|
+
return this;
|
|
3670
|
+
return this.pd(value, 0, charSequenceLength(value));
|
|
3671
|
+
};
|
|
3672
|
+
protoOf(CharArrayBuilder).m1h = function () {
|
|
3673
|
+
var list = this.g5t_1;
|
|
3674
|
+
if (!(list == null)) {
|
|
3675
|
+
this.h5t_1 = null;
|
|
3676
|
+
var inductionVariable = 0;
|
|
3677
|
+
var last = list.s();
|
|
3678
|
+
if (inductionVariable < last)
|
|
3679
|
+
do {
|
|
3680
|
+
var i = inductionVariable;
|
|
3681
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
3682
|
+
this.f5t_1.x4w(list.u(i));
|
|
3683
|
+
}
|
|
3684
|
+
while (inductionVariable < last);
|
|
3685
|
+
} else {
|
|
3686
|
+
var tmp0_safe_receiver = this.h5t_1;
|
|
3687
|
+
if (tmp0_safe_receiver == null)
|
|
3688
|
+
null;
|
|
3689
|
+
else {
|
|
3690
|
+
// Inline function 'kotlin.let' call
|
|
3691
|
+
this.f5t_1.x4w(tmp0_safe_receiver);
|
|
3692
|
+
}
|
|
3693
|
+
this.h5t_1 = null;
|
|
3694
|
+
}
|
|
3695
|
+
this.j5t_1 = true;
|
|
3696
|
+
this.g5t_1 = null;
|
|
3697
|
+
this.i5t_1 = null;
|
|
3698
|
+
this.l5t_1 = 0;
|
|
3699
|
+
this.k5t_1 = 0;
|
|
3700
|
+
};
|
|
3701
|
+
function get_CharArrayPool() {
|
|
3702
|
+
_init_properties_CharArrayPool_kt__u4nq0d();
|
|
3703
|
+
return CharArrayPool;
|
|
3704
|
+
}
|
|
3705
|
+
var CharArrayPool;
|
|
3706
|
+
function CharArrayPool$1() {
|
|
3707
|
+
NoPoolImpl.call(this);
|
|
3708
|
+
}
|
|
3709
|
+
protoOf(CharArrayPool$1).w4w = function () {
|
|
3710
|
+
return charArray(2048);
|
|
3711
|
+
};
|
|
3712
|
+
function CharArrayPool$2() {
|
|
3713
|
+
DefaultPool.call(this, 4096);
|
|
3714
|
+
}
|
|
3715
|
+
protoOf(CharArrayPool$2).p4w = function () {
|
|
3716
|
+
return charArray(2048);
|
|
3717
|
+
};
|
|
3718
|
+
var properties_initialized_CharArrayPool_kt_aq0u0f;
|
|
3719
|
+
function _init_properties_CharArrayPool_kt__u4nq0d() {
|
|
3720
|
+
if (!properties_initialized_CharArrayPool_kt_aq0u0f) {
|
|
3721
|
+
properties_initialized_CharArrayPool_kt_aq0u0f = true;
|
|
3722
|
+
var tmp;
|
|
3723
|
+
if (isPoolingDisabled()) {
|
|
3724
|
+
tmp = new CharArrayPool$1();
|
|
3725
|
+
} else {
|
|
3726
|
+
tmp = new CharArrayPool$2();
|
|
3727
|
+
}
|
|
3728
|
+
CharArrayPool = tmp;
|
|
3729
|
+
}
|
|
3730
|
+
}
|
|
3731
|
+
function get_DefaultHttpMethods() {
|
|
3732
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3733
|
+
return DefaultHttpMethods;
|
|
3734
|
+
}
|
|
3735
|
+
var DefaultHttpMethods;
|
|
3736
|
+
function get_HexTable() {
|
|
3737
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3738
|
+
return HexTable;
|
|
3739
|
+
}
|
|
3740
|
+
var HexTable;
|
|
3741
|
+
function get_HexLetterTable() {
|
|
3742
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3743
|
+
return HexLetterTable;
|
|
3744
|
+
}
|
|
3745
|
+
var HexLetterTable;
|
|
3746
|
+
function parseDecLong(_this__u8e3s4) {
|
|
3747
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3748
|
+
var length = charSequenceLength(_this__u8e3s4);
|
|
3749
|
+
if (length > 19) {
|
|
3750
|
+
numberFormatException(_this__u8e3s4);
|
|
3751
|
+
}
|
|
3752
|
+
if (length === 19)
|
|
3753
|
+
return parseDecLongWithCheck(_this__u8e3s4);
|
|
3754
|
+
var result = new Long(0, 0);
|
|
3755
|
+
var inductionVariable = 0;
|
|
3756
|
+
if (inductionVariable < length)
|
|
3757
|
+
do {
|
|
3758
|
+
var i = inductionVariable;
|
|
3759
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
3760
|
+
// Inline function 'kotlin.code' call
|
|
3761
|
+
var this_0 = charSequenceGet(_this__u8e3s4, i);
|
|
3762
|
+
var tmp$ret$0 = Char__toInt_impl_vasixd(this_0);
|
|
3763
|
+
var digit = toLong(tmp$ret$0).c3(new Long(48, 0));
|
|
3764
|
+
if (digit.j1(new Long(0, 0)) < 0 || digit.j1(new Long(9, 0)) > 0) {
|
|
3765
|
+
numberFormatException_0(_this__u8e3s4, i);
|
|
3766
|
+
}
|
|
3767
|
+
result = result.l3(3).b3(result.l3(1)).b3(digit);
|
|
3768
|
+
}
|
|
3769
|
+
while (inductionVariable < length);
|
|
3770
|
+
return result;
|
|
3771
|
+
}
|
|
3772
|
+
function hashCodeLowerCase(_this__u8e3s4, start, end) {
|
|
3773
|
+
start = start === VOID ? 0 : start;
|
|
3774
|
+
end = end === VOID ? charSequenceLength(_this__u8e3s4) : end;
|
|
3775
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3776
|
+
var hashCode = 0;
|
|
3777
|
+
var inductionVariable = start;
|
|
3778
|
+
if (inductionVariable < end)
|
|
3779
|
+
do {
|
|
3780
|
+
var pos = inductionVariable;
|
|
3781
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
3782
|
+
// Inline function 'kotlin.code' call
|
|
3783
|
+
var this_0 = charSequenceGet(_this__u8e3s4, pos);
|
|
3784
|
+
// Inline function 'io.ktor.http.cio.internals.toLowerCase' call
|
|
3785
|
+
var this_1 = Char__toInt_impl_vasixd(this_0);
|
|
3786
|
+
var tmp;
|
|
3787
|
+
// Inline function 'kotlin.code' call
|
|
3788
|
+
var this_2 = _Char___init__impl__6a9atx(65);
|
|
3789
|
+
var containsLower = Char__toInt_impl_vasixd(this_2);
|
|
3790
|
+
var tmp_0;
|
|
3791
|
+
// Inline function 'kotlin.code' call
|
|
3792
|
+
var this_3 = _Char___init__impl__6a9atx(90);
|
|
3793
|
+
if (this_1 <= Char__toInt_impl_vasixd(this_3)) {
|
|
3794
|
+
tmp_0 = containsLower <= this_1;
|
|
3795
|
+
} else {
|
|
3796
|
+
tmp_0 = false;
|
|
3797
|
+
}
|
|
3798
|
+
if (tmp_0) {
|
|
3799
|
+
// Inline function 'kotlin.code' call
|
|
3800
|
+
var this_4 = _Char___init__impl__6a9atx(97);
|
|
3801
|
+
var tmp_1 = Char__toInt_impl_vasixd(this_4);
|
|
3802
|
+
// Inline function 'kotlin.code' call
|
|
3803
|
+
var this_5 = _Char___init__impl__6a9atx(65);
|
|
3804
|
+
tmp = tmp_1 + (this_1 - Char__toInt_impl_vasixd(this_5) | 0) | 0;
|
|
3805
|
+
} else {
|
|
3806
|
+
tmp = this_1;
|
|
3807
|
+
}
|
|
3808
|
+
var v = tmp;
|
|
3809
|
+
hashCode = imul(31, hashCode) + v | 0;
|
|
3810
|
+
}
|
|
3811
|
+
while (inductionVariable < end);
|
|
3812
|
+
return hashCode;
|
|
3813
|
+
}
|
|
3814
|
+
function equalsLowerCase(_this__u8e3s4, start, end, other) {
|
|
3815
|
+
start = start === VOID ? 0 : start;
|
|
3816
|
+
end = end === VOID ? charSequenceLength(_this__u8e3s4) : end;
|
|
3817
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3818
|
+
if (!((end - start | 0) === charSequenceLength(other)))
|
|
3819
|
+
return false;
|
|
3820
|
+
var inductionVariable = start;
|
|
3821
|
+
if (inductionVariable < end)
|
|
3822
|
+
do {
|
|
3823
|
+
var pos = inductionVariable;
|
|
3824
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
3825
|
+
// Inline function 'kotlin.code' call
|
|
3826
|
+
var this_0 = charSequenceGet(_this__u8e3s4, pos);
|
|
3827
|
+
// Inline function 'io.ktor.http.cio.internals.toLowerCase' call
|
|
3828
|
+
var this_1 = Char__toInt_impl_vasixd(this_0);
|
|
3829
|
+
var tmp;
|
|
3830
|
+
// Inline function 'kotlin.code' call
|
|
3831
|
+
var this_2 = _Char___init__impl__6a9atx(65);
|
|
3832
|
+
var containsLower = Char__toInt_impl_vasixd(this_2);
|
|
3833
|
+
var tmp_0;
|
|
3834
|
+
// Inline function 'kotlin.code' call
|
|
3835
|
+
var this_3 = _Char___init__impl__6a9atx(90);
|
|
3836
|
+
if (this_1 <= Char__toInt_impl_vasixd(this_3)) {
|
|
3837
|
+
tmp_0 = containsLower <= this_1;
|
|
3838
|
+
} else {
|
|
3839
|
+
tmp_0 = false;
|
|
3840
|
+
}
|
|
3841
|
+
if (tmp_0) {
|
|
3842
|
+
// Inline function 'kotlin.code' call
|
|
3843
|
+
var this_4 = _Char___init__impl__6a9atx(97);
|
|
3844
|
+
var tmp_1 = Char__toInt_impl_vasixd(this_4);
|
|
3845
|
+
// Inline function 'kotlin.code' call
|
|
3846
|
+
var this_5 = _Char___init__impl__6a9atx(65);
|
|
3847
|
+
tmp = tmp_1 + (this_1 - Char__toInt_impl_vasixd(this_5) | 0) | 0;
|
|
3848
|
+
} else {
|
|
3849
|
+
tmp = this_1;
|
|
3850
|
+
}
|
|
3851
|
+
var tmp_2 = tmp;
|
|
3852
|
+
// Inline function 'kotlin.code' call
|
|
3853
|
+
var this_6 = charSequenceGet(other, pos - start | 0);
|
|
3854
|
+
// Inline function 'io.ktor.http.cio.internals.toLowerCase' call
|
|
3855
|
+
var this_7 = Char__toInt_impl_vasixd(this_6);
|
|
3856
|
+
var tmp_3;
|
|
3857
|
+
// Inline function 'kotlin.code' call
|
|
3858
|
+
var this_8 = _Char___init__impl__6a9atx(65);
|
|
3859
|
+
var containsLower_0 = Char__toInt_impl_vasixd(this_8);
|
|
3860
|
+
var tmp_4;
|
|
3861
|
+
// Inline function 'kotlin.code' call
|
|
3862
|
+
var this_9 = _Char___init__impl__6a9atx(90);
|
|
3863
|
+
if (this_7 <= Char__toInt_impl_vasixd(this_9)) {
|
|
3864
|
+
tmp_4 = containsLower_0 <= this_7;
|
|
3865
|
+
} else {
|
|
3866
|
+
tmp_4 = false;
|
|
3867
|
+
}
|
|
3868
|
+
if (tmp_4) {
|
|
3869
|
+
// Inline function 'kotlin.code' call
|
|
3870
|
+
var this_10 = _Char___init__impl__6a9atx(97);
|
|
3871
|
+
var tmp_5 = Char__toInt_impl_vasixd(this_10);
|
|
3872
|
+
// Inline function 'kotlin.code' call
|
|
3873
|
+
var this_11 = _Char___init__impl__6a9atx(65);
|
|
3874
|
+
tmp_3 = tmp_5 + (this_7 - Char__toInt_impl_vasixd(this_11) | 0) | 0;
|
|
3875
|
+
} else {
|
|
3876
|
+
tmp_3 = this_7;
|
|
3877
|
+
}
|
|
3878
|
+
if (!(tmp_2 === tmp_3))
|
|
3879
|
+
return false;
|
|
3880
|
+
}
|
|
3881
|
+
while (inductionVariable < end);
|
|
3882
|
+
return true;
|
|
3883
|
+
}
|
|
3884
|
+
function numberFormatException(cs) {
|
|
3885
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3886
|
+
throw NumberFormatException_init_$Create$('Invalid number ' + toString(cs) + ': too large for Long type');
|
|
3887
|
+
}
|
|
3888
|
+
function parseDecLongWithCheck(_this__u8e3s4) {
|
|
3889
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3890
|
+
var result = new Long(0, 0);
|
|
3891
|
+
var inductionVariable = 0;
|
|
3892
|
+
var last = charSequenceLength(_this__u8e3s4) - 1 | 0;
|
|
3893
|
+
if (inductionVariable <= last)
|
|
3894
|
+
do {
|
|
3895
|
+
var i = inductionVariable;
|
|
3896
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
3897
|
+
// Inline function 'kotlin.code' call
|
|
3898
|
+
var this_0 = charSequenceGet(_this__u8e3s4, i);
|
|
3899
|
+
var tmp$ret$0 = Char__toInt_impl_vasixd(this_0);
|
|
3900
|
+
var digit = toLong(tmp$ret$0).c3(new Long(48, 0));
|
|
3901
|
+
if (digit.j1(new Long(0, 0)) < 0 || digit.j1(new Long(9, 0)) > 0) {
|
|
3902
|
+
numberFormatException_0(_this__u8e3s4, i);
|
|
3903
|
+
}
|
|
3904
|
+
result = result.l3(3).b3(result.l3(1)).b3(digit);
|
|
3905
|
+
if (result.j1(new Long(0, 0)) < 0) {
|
|
3906
|
+
numberFormatException(_this__u8e3s4);
|
|
3907
|
+
}
|
|
3908
|
+
}
|
|
3909
|
+
while (inductionVariable <= last);
|
|
3910
|
+
return result;
|
|
3911
|
+
}
|
|
3912
|
+
function numberFormatException_0(cs, idx) {
|
|
3913
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3914
|
+
throw NumberFormatException_init_$Create$('Invalid number: ' + toString(cs) + ', wrong digit: ' + toString_1(charSequenceGet(cs, idx)) + ' at position ' + idx);
|
|
3915
|
+
}
|
|
3916
|
+
function parseHexLong(_this__u8e3s4) {
|
|
3917
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3918
|
+
var result = new Long(0, 0);
|
|
3919
|
+
var table = get_HexTable();
|
|
3920
|
+
var inductionVariable = 0;
|
|
3921
|
+
var last = charSequenceLength(_this__u8e3s4) - 1 | 0;
|
|
3922
|
+
if (inductionVariable <= last)
|
|
3923
|
+
do {
|
|
3924
|
+
var i = inductionVariable;
|
|
3925
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
3926
|
+
// Inline function 'kotlin.code' call
|
|
3927
|
+
var this_0 = charSequenceGet(_this__u8e3s4, i);
|
|
3928
|
+
var v = Char__toInt_impl_vasixd(this_0) & 65535;
|
|
3929
|
+
var digit = v < 255 ? table[v] : new Long(-1, -1);
|
|
3930
|
+
if (digit.equals(new Long(-1, -1))) {
|
|
3931
|
+
hexNumberFormatException(_this__u8e3s4, i);
|
|
3932
|
+
}
|
|
3933
|
+
result = result.l3(4).p3(digit);
|
|
3934
|
+
}
|
|
3935
|
+
while (inductionVariable <= last);
|
|
3936
|
+
return result;
|
|
3937
|
+
}
|
|
3938
|
+
function writeIntHex(_this__u8e3s4, value, $completion) {
|
|
3939
|
+
var tmp = new $writeIntHexCOROUTINE$(_this__u8e3s4, value, $completion);
|
|
3940
|
+
tmp.z9_1 = Unit_instance;
|
|
3941
|
+
tmp.aa_1 = null;
|
|
3942
|
+
return tmp.fa();
|
|
3943
|
+
}
|
|
3944
|
+
function hexNumberFormatException(s, idx) {
|
|
3945
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3946
|
+
throw NumberFormatException_init_$Create$('Invalid HEX number: ' + toString(s) + ', wrong digit: ' + toString_1(charSequenceGet(s, idx)));
|
|
3947
|
+
}
|
|
3948
|
+
function DefaultHttpMethods$lambda(it) {
|
|
3949
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3950
|
+
return it.t5d_1.length;
|
|
3951
|
+
}
|
|
3952
|
+
function DefaultHttpMethods$lambda_0(m, idx) {
|
|
3953
|
+
_init_properties_Chars_kt__d3i39x();
|
|
3954
|
+
return new Char(charCodeAt(m.t5d_1, idx));
|
|
3955
|
+
}
|
|
3956
|
+
function $writeIntHexCOROUTINE$(_this__u8e3s4, value, resultContinuation) {
|
|
3957
|
+
CoroutineImpl.call(this, resultContinuation);
|
|
3958
|
+
this.f5z_1 = _this__u8e3s4;
|
|
3959
|
+
this.g5z_1 = value;
|
|
3960
|
+
}
|
|
3961
|
+
protoOf($writeIntHexCOROUTINE$).fa = function () {
|
|
3962
|
+
var suspendResult = this.z9_1;
|
|
3963
|
+
$sm: do
|
|
3964
|
+
try {
|
|
3965
|
+
var tmp = this.x9_1;
|
|
3966
|
+
switch (tmp) {
|
|
3967
|
+
case 0:
|
|
3968
|
+
this.y9_1 = 8;
|
|
3969
|
+
if (!(this.g5z_1 > 0)) {
|
|
3970
|
+
var message = 'Does only work for positive numbers';
|
|
3971
|
+
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
3972
|
+
}
|
|
3973
|
+
|
|
3974
|
+
this.h5z_1 = this.g5z_1;
|
|
3975
|
+
this.i5z_1 = get_HexLetterTable();
|
|
3976
|
+
this.j5z_1 = 0;
|
|
3977
|
+
this.x9_1 = 1;
|
|
3978
|
+
continue $sm;
|
|
3979
|
+
case 1:
|
|
3980
|
+
var _unary__edvuaz = this.j5z_1;
|
|
3981
|
+
this.j5z_1 = _unary__edvuaz + 1 | 0;
|
|
3982
|
+
if (!(_unary__edvuaz < 8)) {
|
|
3983
|
+
this.x9_1 = 4;
|
|
3984
|
+
continue $sm;
|
|
3985
|
+
}
|
|
3986
|
+
|
|
3987
|
+
this.k5z_1 = this.h5z_1 >>> 28 | 0;
|
|
3988
|
+
this.h5z_1 = this.h5z_1 << 4;
|
|
3989
|
+
if (!(this.k5z_1 === 0)) {
|
|
3990
|
+
this.x9_1 = 3;
|
|
3991
|
+
suspendResult = writeByte(this.f5z_1, this.i5z_1[this.k5z_1], this);
|
|
3992
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
3993
|
+
return suspendResult;
|
|
3994
|
+
}
|
|
3995
|
+
continue $sm;
|
|
3996
|
+
} else {
|
|
3997
|
+
this.x9_1 = 2;
|
|
3998
|
+
continue $sm;
|
|
3999
|
+
}
|
|
4000
|
+
|
|
4001
|
+
case 2:
|
|
4002
|
+
this.x9_1 = 1;
|
|
4003
|
+
continue $sm;
|
|
4004
|
+
case 3:
|
|
4005
|
+
this.x9_1 = 4;
|
|
4006
|
+
continue $sm;
|
|
4007
|
+
case 4:
|
|
4008
|
+
this.x9_1 = 5;
|
|
4009
|
+
continue $sm;
|
|
4010
|
+
case 5:
|
|
4011
|
+
var _unary__edvuaz_0 = this.j5z_1;
|
|
4012
|
+
this.j5z_1 = _unary__edvuaz_0 + 1 | 0;
|
|
4013
|
+
if (!(_unary__edvuaz_0 < 8)) {
|
|
4014
|
+
this.x9_1 = 7;
|
|
4015
|
+
continue $sm;
|
|
4016
|
+
}
|
|
4017
|
+
|
|
4018
|
+
this.l5z_1 = this.h5z_1 >>> 28 | 0;
|
|
4019
|
+
this.h5z_1 = this.h5z_1 << 4;
|
|
4020
|
+
this.x9_1 = 6;
|
|
4021
|
+
suspendResult = writeByte(this.f5z_1, this.i5z_1[this.l5z_1], this);
|
|
4022
|
+
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
4023
|
+
return suspendResult;
|
|
4024
|
+
}
|
|
4025
|
+
|
|
4026
|
+
continue $sm;
|
|
4027
|
+
case 6:
|
|
4028
|
+
this.x9_1 = 5;
|
|
4029
|
+
continue $sm;
|
|
4030
|
+
case 7:
|
|
4031
|
+
return Unit_instance;
|
|
4032
|
+
case 8:
|
|
4033
|
+
throw this.aa_1;
|
|
4034
|
+
}
|
|
4035
|
+
} catch ($p) {
|
|
4036
|
+
var e = $p;
|
|
4037
|
+
if (this.y9_1 === 8) {
|
|
4038
|
+
throw e;
|
|
4039
|
+
} else {
|
|
4040
|
+
this.x9_1 = this.y9_1;
|
|
4041
|
+
this.aa_1 = e;
|
|
4042
|
+
}
|
|
4043
|
+
}
|
|
4044
|
+
while (true);
|
|
4045
|
+
};
|
|
4046
|
+
var properties_initialized_Chars_kt_phjfhp;
|
|
4047
|
+
function _init_properties_Chars_kt__d3i39x() {
|
|
4048
|
+
if (!properties_initialized_Chars_kt_phjfhp) {
|
|
4049
|
+
properties_initialized_Chars_kt_phjfhp = true;
|
|
4050
|
+
var tmp = Companion_instance_0;
|
|
4051
|
+
var tmp_0 = Companion_getInstance_0().s5d_1;
|
|
4052
|
+
var tmp_1 = DefaultHttpMethods$lambda;
|
|
4053
|
+
DefaultHttpMethods = tmp.c5r(tmp_0, tmp_1, DefaultHttpMethods$lambda_0);
|
|
4054
|
+
// Inline function 'kotlin.collections.map' call
|
|
4055
|
+
var this_0 = numberRangeToNumber(0, 255);
|
|
4056
|
+
// Inline function 'kotlin.collections.mapTo' call
|
|
4057
|
+
var destination = ArrayList_init_$Create$_0(collectionSizeOrDefault(this_0, 10));
|
|
4058
|
+
var inductionVariable = this_0.d1_1;
|
|
4059
|
+
var last = this_0.e1_1;
|
|
4060
|
+
if (inductionVariable <= last)
|
|
4061
|
+
do {
|
|
4062
|
+
var item = inductionVariable;
|
|
4063
|
+
inductionVariable = inductionVariable + 1 | 0;
|
|
4064
|
+
var v = item;
|
|
4065
|
+
var tmp_2;
|
|
4066
|
+
if (48 <= v ? v <= 57 : false) {
|
|
4067
|
+
tmp_2 = numberToLong(v).c3(new Long(48, 0));
|
|
4068
|
+
} else {
|
|
4069
|
+
var tmp_3;
|
|
4070
|
+
var tmp_4 = toLong(v);
|
|
4071
|
+
// Inline function 'kotlin.code' call
|
|
4072
|
+
var this_1 = _Char___init__impl__6a9atx(97);
|
|
4073
|
+
var tmp$ret$0 = Char__toInt_impl_vasixd(this_1);
|
|
4074
|
+
if (tmp_4.j1(toLong(tmp$ret$0)) >= 0) {
|
|
4075
|
+
var tmp_5 = toLong(v);
|
|
4076
|
+
// Inline function 'kotlin.code' call
|
|
4077
|
+
var this_2 = _Char___init__impl__6a9atx(102);
|
|
4078
|
+
var tmp$ret$1 = Char__toInt_impl_vasixd(this_2);
|
|
4079
|
+
tmp_3 = tmp_5.j1(toLong(tmp$ret$1)) <= 0;
|
|
4080
|
+
} else {
|
|
4081
|
+
tmp_3 = false;
|
|
4082
|
+
}
|
|
4083
|
+
if (tmp_3) {
|
|
4084
|
+
// Inline function 'kotlin.code' call
|
|
4085
|
+
var this_3 = _Char___init__impl__6a9atx(97);
|
|
4086
|
+
var tmp$ret$2 = Char__toInt_impl_vasixd(this_3);
|
|
4087
|
+
// Inline function 'kotlin.Long.plus' call
|
|
4088
|
+
tmp_2 = numberToLong(v).c3(toLong(tmp$ret$2)).b3(toLong(10));
|
|
4089
|
+
} else {
|
|
4090
|
+
var tmp_6;
|
|
4091
|
+
var tmp_7 = toLong(v);
|
|
4092
|
+
// Inline function 'kotlin.code' call
|
|
4093
|
+
var this_4 = _Char___init__impl__6a9atx(65);
|
|
4094
|
+
var tmp$ret$4 = Char__toInt_impl_vasixd(this_4);
|
|
4095
|
+
if (tmp_7.j1(toLong(tmp$ret$4)) >= 0) {
|
|
4096
|
+
var tmp_8 = toLong(v);
|
|
4097
|
+
// Inline function 'kotlin.code' call
|
|
4098
|
+
var this_5 = _Char___init__impl__6a9atx(70);
|
|
4099
|
+
var tmp$ret$5 = Char__toInt_impl_vasixd(this_5);
|
|
4100
|
+
tmp_6 = tmp_8.j1(toLong(tmp$ret$5)) <= 0;
|
|
4101
|
+
} else {
|
|
4102
|
+
tmp_6 = false;
|
|
4103
|
+
}
|
|
4104
|
+
if (tmp_6) {
|
|
4105
|
+
// Inline function 'kotlin.code' call
|
|
4106
|
+
var this_6 = _Char___init__impl__6a9atx(65);
|
|
4107
|
+
var tmp$ret$6 = Char__toInt_impl_vasixd(this_6);
|
|
4108
|
+
// Inline function 'kotlin.Long.plus' call
|
|
4109
|
+
tmp_2 = numberToLong(v).c3(toLong(tmp$ret$6)).b3(toLong(10));
|
|
4110
|
+
} else {
|
|
4111
|
+
tmp_2 = new Long(-1, -1);
|
|
4112
|
+
}
|
|
4113
|
+
}
|
|
4114
|
+
}
|
|
4115
|
+
var tmp$ret$8 = tmp_2;
|
|
4116
|
+
destination.h(tmp$ret$8);
|
|
4117
|
+
}
|
|
4118
|
+
while (!(item === last));
|
|
4119
|
+
HexTable = toLongArray(destination);
|
|
4120
|
+
// Inline function 'kotlin.collections.map' call
|
|
4121
|
+
var this_7 = numberRangeToNumber(0, 15);
|
|
4122
|
+
// Inline function 'kotlin.collections.mapTo' call
|
|
4123
|
+
var destination_0 = ArrayList_init_$Create$_0(collectionSizeOrDefault(this_7, 10));
|
|
4124
|
+
var inductionVariable_0 = this_7.d1_1;
|
|
4125
|
+
var last_0 = this_7.e1_1;
|
|
4126
|
+
if (inductionVariable_0 <= last_0)
|
|
4127
|
+
do {
|
|
4128
|
+
var item_0 = inductionVariable_0;
|
|
4129
|
+
inductionVariable_0 = inductionVariable_0 + 1 | 0;
|
|
4130
|
+
var it = item_0;
|
|
4131
|
+
var tmp_9;
|
|
4132
|
+
if (it < 10) {
|
|
4133
|
+
tmp_9 = toByte(48 + it | 0);
|
|
4134
|
+
} else {
|
|
4135
|
+
// Inline function 'kotlin.code' call
|
|
4136
|
+
var this_8 = Char__minus_impl_a2frrh(Char__plus_impl_qi7pgj(_Char___init__impl__6a9atx(97), it), 10);
|
|
4137
|
+
var tmp$ret$0_0 = Char__toInt_impl_vasixd(this_8);
|
|
4138
|
+
tmp_9 = toByte(tmp$ret$0_0);
|
|
4139
|
+
}
|
|
4140
|
+
var tmp$ret$1_0 = tmp_9;
|
|
4141
|
+
destination_0.h(tmp$ret$1_0);
|
|
4142
|
+
}
|
|
4143
|
+
while (!(item_0 === last_0));
|
|
4144
|
+
HexLetterTable = toByteArray_0(destination_0);
|
|
4145
|
+
}
|
|
4146
|
+
}
|
|
4147
|
+
function UnsupportedMediaTypeExceptionCIO(message) {
|
|
4148
|
+
IOException_init_$Init$(message, this);
|
|
4149
|
+
captureStack(this, UnsupportedMediaTypeExceptionCIO);
|
|
4150
|
+
}
|
|
4151
|
+
function MutableRange(start, end) {
|
|
4152
|
+
this.g5u_1 = start;
|
|
4153
|
+
this.h5u_1 = end;
|
|
4154
|
+
}
|
|
4155
|
+
protoOf(MutableRange).toString = function () {
|
|
4156
|
+
return 'MutableRange(start=' + this.g5u_1 + ', end=' + this.h5u_1 + ')';
|
|
4157
|
+
};
|
|
4158
|
+
function skipSpacesAndHorizontalTabs(text, start, end) {
|
|
4159
|
+
var index = start;
|
|
4160
|
+
$l$loop: while (index < end) {
|
|
4161
|
+
var ch = text.b(index);
|
|
4162
|
+
if (!isWhitespace(ch) && !(ch === _Char___init__impl__6a9atx(9)))
|
|
4163
|
+
break $l$loop;
|
|
4164
|
+
index = index + 1 | 0;
|
|
4165
|
+
}
|
|
4166
|
+
return index;
|
|
4167
|
+
}
|
|
4168
|
+
function skipSpaces(text, range) {
|
|
4169
|
+
var idx = range.g5u_1;
|
|
4170
|
+
var end = range.h5u_1;
|
|
4171
|
+
if (idx >= end || !isWhitespace(charSequenceGet(text, idx)))
|
|
4172
|
+
return Unit_instance;
|
|
4173
|
+
idx = idx + 1 | 0;
|
|
4174
|
+
$l$loop: while (idx < end && isWhitespace(charSequenceGet(text, idx))) {
|
|
4175
|
+
idx = idx + 1 | 0;
|
|
4176
|
+
}
|
|
4177
|
+
range.g5u_1 = idx;
|
|
4178
|
+
}
|
|
4179
|
+
function findSpaceOrEnd(text, range) {
|
|
4180
|
+
var idx = range.g5u_1;
|
|
4181
|
+
var end = range.h5u_1;
|
|
4182
|
+
if (idx >= end || isWhitespace(charSequenceGet(text, idx)))
|
|
4183
|
+
return idx;
|
|
4184
|
+
idx = idx + 1 | 0;
|
|
4185
|
+
while (idx < end) {
|
|
4186
|
+
if (isWhitespace(charSequenceGet(text, idx)))
|
|
4187
|
+
return idx;
|
|
4188
|
+
idx = idx + 1 | 0;
|
|
4189
|
+
}
|
|
4190
|
+
return idx;
|
|
4191
|
+
}
|
|
4192
|
+
function nextToken(text, range) {
|
|
4193
|
+
var spaceOrEnd = findSpaceOrEnd(text, range);
|
|
4194
|
+
var s = charSequenceSubSequence(text, range.g5u_1, spaceOrEnd);
|
|
4195
|
+
range.g5u_1 = spaceOrEnd;
|
|
4196
|
+
return s;
|
|
4197
|
+
}
|
|
4198
|
+
function discardBlocking(_this__u8e3s4) {
|
|
4199
|
+
cancel(_this__u8e3s4);
|
|
4200
|
+
}
|
|
4201
|
+
function RequestResponseBuilder() {
|
|
4202
|
+
this.m5z_1 = BytePacketBuilder();
|
|
4203
|
+
}
|
|
4204
|
+
protoOf(RequestResponseBuilder).n5z = function (version, status, statusText) {
|
|
4205
|
+
writeText(this.m5z_1, version);
|
|
4206
|
+
this.m5z_1.k3c(32);
|
|
4207
|
+
writeText(this.m5z_1, status.toString());
|
|
4208
|
+
this.m5z_1.k3c(32);
|
|
4209
|
+
writeText(this.m5z_1, statusText);
|
|
4210
|
+
this.m5z_1.k3c(13);
|
|
4211
|
+
this.m5z_1.k3c(10);
|
|
4212
|
+
};
|
|
4213
|
+
protoOf(RequestResponseBuilder).o5z = function (name, value) {
|
|
4214
|
+
append(this.m5z_1, name);
|
|
4215
|
+
append(this.m5z_1, ': ');
|
|
4216
|
+
append(this.m5z_1, value);
|
|
4217
|
+
this.m5z_1.k3c(13);
|
|
4218
|
+
this.m5z_1.k3c(10);
|
|
4219
|
+
};
|
|
4220
|
+
protoOf(RequestResponseBuilder).p5z = function () {
|
|
4221
|
+
this.m5z_1.k3c(13);
|
|
4222
|
+
this.m5z_1.k3c(10);
|
|
4223
|
+
};
|
|
4224
|
+
protoOf(RequestResponseBuilder).o3o = function () {
|
|
4225
|
+
return build(this.m5z_1);
|
|
4226
|
+
};
|
|
4227
|
+
protoOf(RequestResponseBuilder).m1h = function () {
|
|
4228
|
+
this.m5z_1.u4();
|
|
4229
|
+
};
|
|
4230
|
+
function isPoolingDisabled() {
|
|
4231
|
+
return false;
|
|
4232
|
+
}
|
|
4233
|
+
//region block: post-declaration
|
|
4234
|
+
protoOf(CIOHeaders).e4z = forEach;
|
|
4235
|
+
//endregion
|
|
4236
|
+
//region block: init
|
|
4237
|
+
Companion_instance_0 = new Companion_0();
|
|
4238
|
+
//endregion
|
|
4239
|
+
//region block: exports
|
|
4240
|
+
_.$_$ = _.$_$ || {};
|
|
4241
|
+
_.$_$.a = parseHttpBody;
|
|
4242
|
+
_.$_$.b = parseRequest;
|
|
4243
|
+
_.$_$.c = Companion_getInstance_3;
|
|
4244
|
+
_.$_$.d = parseDecLong;
|
|
4245
|
+
_.$_$.e = CIOHeaders;
|
|
4246
|
+
_.$_$.f = CIOMultipartDataBase;
|
|
4247
|
+
_.$_$.g = ParserException;
|
|
4248
|
+
_.$_$.h = RequestResponseBuilder;
|
|
4249
|
+
_.$_$.i = Request;
|
|
4250
|
+
_.$_$.j = encodeChunked;
|
|
4251
|
+
_.$_$.k = expectHttpBody;
|
|
4252
|
+
_.$_$.l = expectHttpUpgrade;
|
|
4253
|
+
//endregion
|
|
4254
|
+
return _;
|
|
4255
|
+
}));
|
|
4256
|
+
|
|
4257
|
+
//# sourceMappingURL=ktor-ktor-http-cio.js.map
|