@attocash/cli 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (400) hide show
  1. package/LICENSE +28 -0
  2. package/README.md +707 -0
  3. package/dist/application/app.d.ts +138 -0
  4. package/dist/application/app.js +654 -0
  5. package/dist/application/operations.d.ts +9 -0
  6. package/dist/application/operations.js +96 -0
  7. package/dist/cli/cli.d.ts +1 -0
  8. package/dist/cli/cli.js +460 -0
  9. package/dist/cli/help.d.ts +4 -0
  10. package/dist/cli/help.js +49 -0
  11. package/dist/cli/main.d.ts +2 -0
  12. package/dist/cli/main.js +13 -0
  13. package/dist/cli/onboarding.d.ts +14 -0
  14. package/dist/cli/onboarding.js +144 -0
  15. package/dist/cli/output.d.ts +2 -0
  16. package/dist/cli/output.js +231 -0
  17. package/dist/cli/terminal.d.ts +6 -0
  18. package/dist/cli/terminal.js +92 -0
  19. package/dist/cli/update-check.d.ts +1 -0
  20. package/dist/cli/update-check.js +12 -0
  21. package/dist/cli/updates.d.ts +2 -0
  22. package/dist/cli/updates.js +98 -0
  23. package/dist/core.d.ts +14 -0
  24. package/dist/core.js +14 -0
  25. package/dist/doctor/credential-probe.d.ts +7 -0
  26. package/dist/doctor/credential-probe.js +49 -0
  27. package/dist/doctor/doctor.d.ts +4 -0
  28. package/dist/doctor/doctor.js +213 -0
  29. package/dist/doctor/keyring.d.ts +7 -0
  30. package/dist/doctor/keyring.js +150 -0
  31. package/dist/doctor/profile.d.ts +19 -0
  32. package/dist/doctor/profile.js +73 -0
  33. package/dist/doctor/types.d.ts +40 -0
  34. package/dist/doctor/types.js +1 -0
  35. package/dist/domain/amount.d.ts +6 -0
  36. package/dist/domain/amount.js +27 -0
  37. package/dist/domain/errors.d.ts +10 -0
  38. package/dist/domain/errors.js +16 -0
  39. package/dist/labels/directory.d.ts +87 -0
  40. package/dist/labels/directory.js +140 -0
  41. package/dist/labels/personal.d.ts +17 -0
  42. package/dist/labels/personal.js +56 -0
  43. package/dist/labels/presentation.d.ts +154 -0
  44. package/dist/labels/presentation.js +90 -0
  45. package/dist/network/reader.d.ts +31 -0
  46. package/dist/network/reader.js +370 -0
  47. package/dist/network/retry.d.ts +7 -0
  48. package/dist/network/retry.js +53 -0
  49. package/dist/network/work.d.ts +3 -0
  50. package/dist/network/work.js +66 -0
  51. package/dist/pricing/market.d.ts +29 -0
  52. package/dist/pricing/market.js +150 -0
  53. package/dist/pricing/terms.d.ts +6 -0
  54. package/dist/pricing/terms.js +12 -0
  55. package/dist/spending/destination.d.ts +16 -0
  56. package/dist/spending/destination.js +42 -0
  57. package/dist/spending/journal.d.ts +28 -0
  58. package/dist/spending/journal.js +69 -0
  59. package/dist/spending/ledger.d.ts +118 -0
  60. package/dist/spending/ledger.js +444 -0
  61. package/dist/spending/payments.d.ts +67 -0
  62. package/dist/spending/payments.js +424 -0
  63. package/dist/spending/pool.d.ts +13 -0
  64. package/dist/spending/pool.js +38 -0
  65. package/dist/spending/reconcile.d.ts +18 -0
  66. package/dist/spending/reconcile.js +64 -0
  67. package/dist/storage/profiles.d.ts +13 -0
  68. package/dist/storage/profiles.js +86 -0
  69. package/dist/storage/secrets.d.ts +16 -0
  70. package/dist/storage/secrets.js +104 -0
  71. package/dist/storage/state.d.ts +32 -0
  72. package/dist/storage/state.js +255 -0
  73. package/dist/wallet/auto-receive.d.ts +57 -0
  74. package/dist/wallet/auto-receive.js +140 -0
  75. package/dist/wallet/defaults.d.ts +3 -0
  76. package/dist/wallet/defaults.js +26 -0
  77. package/dist/wallet/signing.d.ts +17 -0
  78. package/dist/wallet/signing.js +128 -0
  79. package/dist/wallet/types.d.ts +65 -0
  80. package/dist/wallet/types.js +1 -0
  81. package/dist/wallet/work.d.ts +29 -0
  82. package/dist/wallet/work.js +154 -0
  83. package/dist/watches/manager.d.ts +75 -0
  84. package/dist/watches/manager.js +197 -0
  85. package/node_modules/@attocash/commons-core/Kotlin-DateTime-library-kotlinx-datetime.mjs +6678 -0
  86. package/node_modules/@attocash/commons-core/Kotlin-DateTime-library-kotlinx-datetime.mjs.map +1 -0
  87. package/node_modules/@attocash/commons-core/LICENSE +28 -0
  88. package/node_modules/@attocash/commons-core/README.md +118 -0
  89. package/node_modules/@attocash/commons-core/commons-commons-core.d.mts +1036 -0
  90. package/node_modules/@attocash/commons-core/commons-commons-core.mjs +7701 -0
  91. package/node_modules/@attocash/commons-core/commons-commons-core.mjs.map +1 -0
  92. package/node_modules/@attocash/commons-core/kotlin-kotlin-stdlib.mjs +17681 -0
  93. package/node_modules/@attocash/commons-core/kotlin-kotlin-stdlib.mjs.map +1 -0
  94. package/node_modules/@attocash/commons-core/kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.mjs +4 -0
  95. package/node_modules/@attocash/commons-core/kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.mjs.map +1 -0
  96. package/node_modules/@attocash/commons-core/kotlinx-io-kotlinx-io-bytestring.mjs +209 -0
  97. package/node_modules/@attocash/commons-core/kotlinx-io-kotlinx-io-bytestring.mjs.map +1 -0
  98. package/node_modules/@attocash/commons-core/kotlinx-io-kotlinx-io-core.mjs +2284 -0
  99. package/node_modules/@attocash/commons-core/kotlinx-io-kotlinx-io-core.mjs.map +1 -0
  100. package/node_modules/@attocash/commons-core/kotlinx-serialization-kotlinx-serialization-core.mjs +6042 -0
  101. package/node_modules/@attocash/commons-core/kotlinx-serialization-kotlinx-serialization-core.mjs.map +1 -0
  102. package/node_modules/@attocash/commons-core/kotlinx-serialization-kotlinx-serialization-json.mjs +5294 -0
  103. package/node_modules/@attocash/commons-core/kotlinx-serialization-kotlinx-serialization-json.mjs.map +1 -0
  104. package/node_modules/@attocash/commons-core/package.json +27 -0
  105. package/node_modules/@attocash/commons-node/LICENSE +28 -0
  106. package/node_modules/@attocash/commons-node/README.md +92 -0
  107. package/node_modules/@attocash/commons-node/commons-commons-node.d.mts +255 -0
  108. package/node_modules/@attocash/commons-node/commons-commons-node.mjs +2977 -0
  109. package/node_modules/@attocash/commons-node/commons-commons-node.mjs.map +1 -0
  110. package/node_modules/@attocash/commons-node/kotlin-logging.mjs +432 -0
  111. package/node_modules/@attocash/commons-node/kotlin-logging.mjs.map +1 -0
  112. package/node_modules/@attocash/commons-node/kotlinx-serialization-kotlinx-serialization-json.mjs +5294 -0
  113. package/node_modules/@attocash/commons-node/kotlinx-serialization-kotlinx-serialization-json.mjs.map +1 -0
  114. package/node_modules/@attocash/commons-node/package.json +29 -0
  115. package/node_modules/@attocash/commons-node-remote/LICENSE +28 -0
  116. package/node_modules/@attocash/commons-node-remote/README.md +61 -0
  117. package/node_modules/@attocash/commons-node-remote/commons-commons-node-remote.d.mts +122 -0
  118. package/node_modules/@attocash/commons-node-remote/commons-commons-node-remote.mjs +1810 -0
  119. package/node_modules/@attocash/commons-node-remote/commons-commons-node-remote.mjs.map +1 -0
  120. package/node_modules/@attocash/commons-node-remote/kotlin-logging.mjs +432 -0
  121. package/node_modules/@attocash/commons-node-remote/kotlin-logging.mjs.map +1 -0
  122. package/node_modules/@attocash/commons-node-remote/kotlinx-browser.mjs +8 -0
  123. package/node_modules/@attocash/commons-node-remote/kotlinx-browser.mjs.map +1 -0
  124. package/node_modules/@attocash/commons-node-remote/kotlinx-serialization-kotlinx-serialization-json-io.mjs +4 -0
  125. package/node_modules/@attocash/commons-node-remote/kotlinx-serialization-kotlinx-serialization-json-io.mjs.map +1 -0
  126. package/node_modules/@attocash/commons-node-remote/kotlinx-serialization-kotlinx-serialization-json.mjs +5294 -0
  127. package/node_modules/@attocash/commons-node-remote/kotlinx-serialization-kotlinx-serialization-json.mjs.map +1 -0
  128. package/node_modules/@attocash/commons-node-remote/package.json +31 -0
  129. package/node_modules/@attocash/commons-transport/LICENSE +28 -0
  130. package/node_modules/@attocash/commons-transport/README.md +5 -0
  131. package/node_modules/@attocash/commons-transport/commons-commons-transport.d.mts +64 -0
  132. package/node_modules/@attocash/commons-transport/commons-commons-transport.mjs +249 -0
  133. package/node_modules/@attocash/commons-transport/commons-commons-transport.mjs.map +1 -0
  134. package/node_modules/@attocash/commons-transport/kotlinx-atomicfu.mjs +263 -0
  135. package/node_modules/@attocash/commons-transport/kotlinx-atomicfu.mjs.map +1 -0
  136. package/node_modules/@attocash/commons-transport/kotlinx-browser.mjs +8 -0
  137. package/node_modules/@attocash/commons-transport/kotlinx-browser.mjs.map +1 -0
  138. package/node_modules/@attocash/commons-transport/kotlinx-coroutines-core.mjs +11604 -0
  139. package/node_modules/@attocash/commons-transport/kotlinx-coroutines-core.mjs.map +1 -0
  140. package/node_modules/@attocash/commons-transport/kotlinx-serialization-kotlinx-serialization-json-io.mjs +4 -0
  141. package/node_modules/@attocash/commons-transport/kotlinx-serialization-kotlinx-serialization-json-io.mjs.map +1 -0
  142. package/node_modules/@attocash/commons-transport/kotlinx-serialization-kotlinx-serialization-json.mjs +5294 -0
  143. package/node_modules/@attocash/commons-transport/kotlinx-serialization-kotlinx-serialization-json.mjs.map +1 -0
  144. package/node_modules/@attocash/commons-transport/ktor-ktor-client-content-negotiation.mjs +499 -0
  145. package/node_modules/@attocash/commons-transport/ktor-ktor-client-content-negotiation.mjs.map +1 -0
  146. package/node_modules/@attocash/commons-transport/ktor-ktor-client-core.mjs +6456 -0
  147. package/node_modules/@attocash/commons-transport/ktor-ktor-client-core.mjs.map +1 -0
  148. package/node_modules/@attocash/commons-transport/ktor-ktor-events.mjs +83 -0
  149. package/node_modules/@attocash/commons-transport/ktor-ktor-events.mjs.map +1 -0
  150. package/node_modules/@attocash/commons-transport/ktor-ktor-http-cio.mjs +1714 -0
  151. package/node_modules/@attocash/commons-transport/ktor-ktor-http-cio.mjs.map +1 -0
  152. package/node_modules/@attocash/commons-transport/ktor-ktor-http.mjs +3197 -0
  153. package/node_modules/@attocash/commons-transport/ktor-ktor-http.mjs.map +1 -0
  154. package/node_modules/@attocash/commons-transport/ktor-ktor-io.mjs +2290 -0
  155. package/node_modules/@attocash/commons-transport/ktor-ktor-io.mjs.map +1 -0
  156. package/node_modules/@attocash/commons-transport/ktor-ktor-serialization-kotlinx-json.mjs +46 -0
  157. package/node_modules/@attocash/commons-transport/ktor-ktor-serialization-kotlinx-json.mjs.map +1 -0
  158. package/node_modules/@attocash/commons-transport/ktor-ktor-serialization-kotlinx.mjs +482 -0
  159. package/node_modules/@attocash/commons-transport/ktor-ktor-serialization-kotlinx.mjs.map +1 -0
  160. package/node_modules/@attocash/commons-transport/ktor-ktor-serialization.mjs +165 -0
  161. package/node_modules/@attocash/commons-transport/ktor-ktor-serialization.mjs.map +1 -0
  162. package/node_modules/@attocash/commons-transport/ktor-ktor-sse.mjs +4 -0
  163. package/node_modules/@attocash/commons-transport/ktor-ktor-sse.mjs.map +1 -0
  164. package/node_modules/@attocash/commons-transport/ktor-ktor-utils.mjs +3222 -0
  165. package/node_modules/@attocash/commons-transport/ktor-ktor-utils.mjs.map +1 -0
  166. package/node_modules/@attocash/commons-transport/ktor-ktor-websocket-serialization.mjs +4 -0
  167. package/node_modules/@attocash/commons-transport/ktor-ktor-websocket-serialization.mjs.map +1 -0
  168. package/node_modules/@attocash/commons-transport/ktor-ktor-websockets.mjs +1485 -0
  169. package/node_modules/@attocash/commons-transport/ktor-ktor-websockets.mjs.map +1 -0
  170. package/node_modules/@attocash/commons-transport/package.json +29 -0
  171. package/node_modules/@attocash/commons-worker/LICENSE +28 -0
  172. package/node_modules/@attocash/commons-worker/README.md +48 -0
  173. package/node_modules/@attocash/commons-worker/commons-commons-worker.d.mts +73 -0
  174. package/node_modules/@attocash/commons-worker/commons-commons-worker.mjs +702 -0
  175. package/node_modules/@attocash/commons-worker/commons-commons-worker.mjs.map +1 -0
  176. package/node_modules/@attocash/commons-worker/kotlin-logging.mjs +432 -0
  177. package/node_modules/@attocash/commons-worker/kotlin-logging.mjs.map +1 -0
  178. package/node_modules/@attocash/commons-worker/kotlinx-serialization-kotlinx-serialization-json.mjs +5294 -0
  179. package/node_modules/@attocash/commons-worker/kotlinx-serialization-kotlinx-serialization-json.mjs.map +1 -0
  180. package/node_modules/@attocash/commons-worker/package.json +29 -0
  181. package/node_modules/@attocash/commons-worker-remote/LICENSE +28 -0
  182. package/node_modules/@attocash/commons-worker-remote/README.md +60 -0
  183. package/node_modules/@attocash/commons-worker-remote/commons-commons-worker-remote.d.mts +93 -0
  184. package/node_modules/@attocash/commons-worker-remote/commons-commons-worker-remote.mjs +289 -0
  185. package/node_modules/@attocash/commons-worker-remote/commons-commons-worker-remote.mjs.map +1 -0
  186. package/node_modules/@attocash/commons-worker-remote/kotlin-logging.mjs +432 -0
  187. package/node_modules/@attocash/commons-worker-remote/kotlin-logging.mjs.map +1 -0
  188. package/node_modules/@attocash/commons-worker-remote/kotlinx-browser.mjs +8 -0
  189. package/node_modules/@attocash/commons-worker-remote/kotlinx-browser.mjs.map +1 -0
  190. package/node_modules/@attocash/commons-worker-remote/kotlinx-serialization-kotlinx-serialization-json-io.mjs +4 -0
  191. package/node_modules/@attocash/commons-worker-remote/kotlinx-serialization-kotlinx-serialization-json-io.mjs.map +1 -0
  192. package/node_modules/@attocash/commons-worker-remote/kotlinx-serialization-kotlinx-serialization-json.mjs +5294 -0
  193. package/node_modules/@attocash/commons-worker-remote/kotlinx-serialization-kotlinx-serialization-json.mjs.map +1 -0
  194. package/node_modules/@attocash/commons-worker-remote/package.json +31 -0
  195. package/node_modules/@js-joda/core/CHANGELOG.md +363 -0
  196. package/node_modules/@js-joda/core/CheatSheet.md +947 -0
  197. package/node_modules/@js-joda/core/LICENSE +34 -0
  198. package/node_modules/@js-joda/core/README.md +155 -0
  199. package/node_modules/@js-joda/core/bower.json +21 -0
  200. package/node_modules/@js-joda/core/dist/js-joda.d.ts +2452 -0
  201. package/node_modules/@js-joda/core/dist/js-joda.esm.js +13564 -0
  202. package/node_modules/@js-joda/core/dist/js-joda.flow.js +949 -0
  203. package/node_modules/@js-joda/core/dist/js-joda.js +13630 -0
  204. package/node_modules/@js-joda/core/dist/js-joda.js.map +1 -0
  205. package/node_modules/@js-joda/core/dist/js-joda.min.js +5 -0
  206. package/node_modules/@js-joda/core/package.json +76 -0
  207. package/node_modules/@js-joda/core/src/Clock.js +330 -0
  208. package/node_modules/@js-joda/core/src/DayOfWeek.js +451 -0
  209. package/node_modules/@js-joda/core/src/Duration.js +1205 -0
  210. package/node_modules/@js-joda/core/src/Enum.js +30 -0
  211. package/node_modules/@js-joda/core/src/Instant.js +1012 -0
  212. package/node_modules/@js-joda/core/src/LocalDate.js +1703 -0
  213. package/node_modules/@js-joda/core/src/LocalDateTime.js +1686 -0
  214. package/node_modules/@js-joda/core/src/LocalTime.js +1415 -0
  215. package/node_modules/@js-joda/core/src/MathUtil.js +236 -0
  216. package/node_modules/@js-joda/core/src/Month.js +600 -0
  217. package/node_modules/@js-joda/core/src/MonthDay.js +730 -0
  218. package/node_modules/@js-joda/core/src/OffsetDateTime.js +757 -0
  219. package/node_modules/@js-joda/core/src/OffsetTime.js +621 -0
  220. package/node_modules/@js-joda/core/src/Period.js +933 -0
  221. package/node_modules/@js-joda/core/src/StringUtil.js +43 -0
  222. package/node_modules/@js-joda/core/src/Year.js +1015 -0
  223. package/node_modules/@js-joda/core/src/YearConstants.js +21 -0
  224. package/node_modules/@js-joda/core/src/YearMonth.js +1096 -0
  225. package/node_modules/@js-joda/core/src/ZoneId.js +236 -0
  226. package/node_modules/@js-joda/core/src/ZoneIdFactory.js +201 -0
  227. package/node_modules/@js-joda/core/src/ZoneOffset.js +486 -0
  228. package/node_modules/@js-joda/core/src/ZoneRegion.js +72 -0
  229. package/node_modules/@js-joda/core/src/ZonedDateTime.js +2007 -0
  230. package/node_modules/@js-joda/core/src/_init.js +68 -0
  231. package/node_modules/@js-joda/core/src/assert.js +33 -0
  232. package/node_modules/@js-joda/core/src/chrono/ChronoLocalDate.js +230 -0
  233. package/node_modules/@js-joda/core/src/chrono/ChronoLocalDateTime.js +130 -0
  234. package/node_modules/@js-joda/core/src/chrono/ChronoZonedDateTime.js +194 -0
  235. package/node_modules/@js-joda/core/src/chrono/IsoChronology.js +235 -0
  236. package/node_modules/@js-joda/core/src/convert.js +83 -0
  237. package/node_modules/@js-joda/core/src/errors.js +54 -0
  238. package/node_modules/@js-joda/core/src/format/DateTimeBuilder.js +535 -0
  239. package/node_modules/@js-joda/core/src/format/DateTimeFormatter.js +728 -0
  240. package/node_modules/@js-joda/core/src/format/DateTimeFormatterBuilder.js +1545 -0
  241. package/node_modules/@js-joda/core/src/format/DateTimeParseContext.js +297 -0
  242. package/node_modules/@js-joda/core/src/format/DateTimePrintContext.js +138 -0
  243. package/node_modules/@js-joda/core/src/format/DecimalStyle.js +113 -0
  244. package/node_modules/@js-joda/core/src/format/EnumMap.js +70 -0
  245. package/node_modules/@js-joda/core/src/format/ParsePosition.js +31 -0
  246. package/node_modules/@js-joda/core/src/format/ResolverStyle.js +93 -0
  247. package/node_modules/@js-joda/core/src/format/SignStyle.js +38 -0
  248. package/node_modules/@js-joda/core/src/format/StringBuilder.js +47 -0
  249. package/node_modules/@js-joda/core/src/format/TextStyle.js +114 -0
  250. package/node_modules/@js-joda/core/src/format/parser/CharLiteralPrinterParser.js +46 -0
  251. package/node_modules/@js-joda/core/src/format/parser/CompositePrinterParser.js +89 -0
  252. package/node_modules/@js-joda/core/src/format/parser/FractionPrinterParser.js +162 -0
  253. package/node_modules/@js-joda/core/src/format/parser/NumberPrinterParser.js +367 -0
  254. package/node_modules/@js-joda/core/src/format/parser/OffsetIdPrinterParser.js +177 -0
  255. package/node_modules/@js-joda/core/src/format/parser/PadPrinterParserDecorator.js +81 -0
  256. package/node_modules/@js-joda/core/src/format/parser/SettingsParser.js +44 -0
  257. package/node_modules/@js-joda/core/src/format/parser/StringLiteralPrinterParser.js +39 -0
  258. package/node_modules/@js-joda/core/src/format/parser/ZoneIdPrinterParser.js +218 -0
  259. package/node_modules/@js-joda/core/src/js-joda.js +210 -0
  260. package/node_modules/@js-joda/core/src/license-preamble.js +3 -0
  261. package/node_modules/@js-joda/core/src/temporal/ChronoField.js +470 -0
  262. package/node_modules/@js-joda/core/src/temporal/ChronoUnit.js +310 -0
  263. package/node_modules/@js-joda/core/src/temporal/DefaultInterfaceTemporal.js +118 -0
  264. package/node_modules/@js-joda/core/src/temporal/IsoFields.js +859 -0
  265. package/node_modules/@js-joda/core/src/temporal/NativeJsTemporal.js +105 -0
  266. package/node_modules/@js-joda/core/src/temporal/Temporal.js +346 -0
  267. package/node_modules/@js-joda/core/src/temporal/TemporalAccessor.js +125 -0
  268. package/node_modules/@js-joda/core/src/temporal/TemporalAdjuster.js +92 -0
  269. package/node_modules/@js-joda/core/src/temporal/TemporalAdjusters.js +464 -0
  270. package/node_modules/@js-joda/core/src/temporal/TemporalAmount.js +166 -0
  271. package/node_modules/@js-joda/core/src/temporal/TemporalField.js +248 -0
  272. package/node_modules/@js-joda/core/src/temporal/TemporalQueries.js +223 -0
  273. package/node_modules/@js-joda/core/src/temporal/TemporalQueriesFactory.js +77 -0
  274. package/node_modules/@js-joda/core/src/temporal/TemporalQuery.js +107 -0
  275. package/node_modules/@js-joda/core/src/temporal/TemporalUnit.js +179 -0
  276. package/node_modules/@js-joda/core/src/temporal/ValueRange.js +257 -0
  277. package/node_modules/@js-joda/core/src/use.js +20 -0
  278. package/node_modules/@js-joda/core/src/zone/SystemDefaultZoneId.js +31 -0
  279. package/node_modules/@js-joda/core/src/zone/SystemDefaultZoneRules.js +162 -0
  280. package/node_modules/@js-joda/core/src/zone/ZoneOffsetTransition.js +289 -0
  281. package/node_modules/@js-joda/core/src/zone/ZoneRules.js +464 -0
  282. package/node_modules/@js-joda/core/src/zone/ZoneRulesProvider.js +36 -0
  283. package/node_modules/@noble/hashes/LICENSE +21 -0
  284. package/node_modules/@noble/hashes/README.md +563 -0
  285. package/node_modules/@noble/hashes/_blake.d.ts +21 -0
  286. package/node_modules/@noble/hashes/_blake.d.ts.map +1 -0
  287. package/node_modules/@noble/hashes/_blake.js +52 -0
  288. package/node_modules/@noble/hashes/_blake.js.map +1 -0
  289. package/node_modules/@noble/hashes/_md.d.ts +99 -0
  290. package/node_modules/@noble/hashes/_md.d.ts.map +1 -0
  291. package/node_modules/@noble/hashes/_md.js +202 -0
  292. package/node_modules/@noble/hashes/_md.js.map +1 -0
  293. package/node_modules/@noble/hashes/_u64.d.ts +63 -0
  294. package/node_modules/@noble/hashes/_u64.d.ts.map +1 -0
  295. package/node_modules/@noble/hashes/_u64.js +84 -0
  296. package/node_modules/@noble/hashes/_u64.js.map +1 -0
  297. package/node_modules/@noble/hashes/argon2.d.ts +112 -0
  298. package/node_modules/@noble/hashes/argon2.d.ts.map +1 -0
  299. package/node_modules/@noble/hashes/argon2.js +517 -0
  300. package/node_modules/@noble/hashes/argon2.js.map +1 -0
  301. package/node_modules/@noble/hashes/blake1.d.ts +156 -0
  302. package/node_modules/@noble/hashes/blake1.d.ts.map +1 -0
  303. package/node_modules/@noble/hashes/blake1.js +560 -0
  304. package/node_modules/@noble/hashes/blake1.js.map +1 -0
  305. package/node_modules/@noble/hashes/blake2.d.ts +184 -0
  306. package/node_modules/@noble/hashes/blake2.d.ts.map +1 -0
  307. package/node_modules/@noble/hashes/blake2.js +501 -0
  308. package/node_modules/@noble/hashes/blake2.js.map +1 -0
  309. package/node_modules/@noble/hashes/blake3.d.ts +68 -0
  310. package/node_modules/@noble/hashes/blake3.d.ts.map +1 -0
  311. package/node_modules/@noble/hashes/blake3.js +284 -0
  312. package/node_modules/@noble/hashes/blake3.js.map +1 -0
  313. package/node_modules/@noble/hashes/eskdf.d.ts +92 -0
  314. package/node_modules/@noble/hashes/eskdf.d.ts.map +1 -0
  315. package/node_modules/@noble/hashes/eskdf.js +218 -0
  316. package/node_modules/@noble/hashes/eskdf.js.map +1 -0
  317. package/node_modules/@noble/hashes/hkdf.d.ts +64 -0
  318. package/node_modules/@noble/hashes/hkdf.d.ts.map +1 -0
  319. package/node_modules/@noble/hashes/hkdf.js +120 -0
  320. package/node_modules/@noble/hashes/hkdf.js.map +1 -0
  321. package/node_modules/@noble/hashes/hmac.d.ts +47 -0
  322. package/node_modules/@noble/hashes/hmac.d.ts.map +1 -0
  323. package/node_modules/@noble/hashes/hmac.js +93 -0
  324. package/node_modules/@noble/hashes/hmac.js.map +1 -0
  325. package/node_modules/@noble/hashes/index.d.ts +2 -0
  326. package/node_modules/@noble/hashes/index.d.ts.map +1 -0
  327. package/node_modules/@noble/hashes/index.js +35 -0
  328. package/node_modules/@noble/hashes/index.js.map +1 -0
  329. package/node_modules/@noble/hashes/legacy.d.ts +102 -0
  330. package/node_modules/@noble/hashes/legacy.d.ts.map +1 -0
  331. package/node_modules/@noble/hashes/legacy.js +327 -0
  332. package/node_modules/@noble/hashes/legacy.js.map +1 -0
  333. package/node_modules/@noble/hashes/package.json +97 -0
  334. package/node_modules/@noble/hashes/pbkdf2.d.ts +56 -0
  335. package/node_modules/@noble/hashes/pbkdf2.d.ts.map +1 -0
  336. package/node_modules/@noble/hashes/pbkdf2.js +135 -0
  337. package/node_modules/@noble/hashes/pbkdf2.js.map +1 -0
  338. package/node_modules/@noble/hashes/scrypt.d.ts +65 -0
  339. package/node_modules/@noble/hashes/scrypt.d.ts.map +1 -0
  340. package/node_modules/@noble/hashes/scrypt.js +257 -0
  341. package/node_modules/@noble/hashes/scrypt.js.map +1 -0
  342. package/node_modules/@noble/hashes/sha2.d.ts +249 -0
  343. package/node_modules/@noble/hashes/sha2.d.ts.map +1 -0
  344. package/node_modules/@noble/hashes/sha2.js +458 -0
  345. package/node_modules/@noble/hashes/sha2.js.map +1 -0
  346. package/node_modules/@noble/hashes/sha3-addons.d.ts +461 -0
  347. package/node_modules/@noble/hashes/sha3-addons.d.ts.map +1 -0
  348. package/node_modules/@noble/hashes/sha3-addons.js +783 -0
  349. package/node_modules/@noble/hashes/sha3-addons.js.map +1 -0
  350. package/node_modules/@noble/hashes/sha3.d.ts +199 -0
  351. package/node_modules/@noble/hashes/sha3.d.ts.map +1 -0
  352. package/node_modules/@noble/hashes/sha3.js +431 -0
  353. package/node_modules/@noble/hashes/sha3.js.map +1 -0
  354. package/node_modules/@noble/hashes/src/_blake.ts +57 -0
  355. package/node_modules/@noble/hashes/src/_md.ts +222 -0
  356. package/node_modules/@noble/hashes/src/_u64.ts +117 -0
  357. package/node_modules/@noble/hashes/src/argon2.ts +667 -0
  358. package/node_modules/@noble/hashes/src/blake1.ts +614 -0
  359. package/node_modules/@noble/hashes/src/blake2.ts +582 -0
  360. package/node_modules/@noble/hashes/src/blake3.ts +317 -0
  361. package/node_modules/@noble/hashes/src/eskdf.ts +259 -0
  362. package/node_modules/@noble/hashes/src/hkdf.ts +133 -0
  363. package/node_modules/@noble/hashes/src/hmac.ts +126 -0
  364. package/node_modules/@noble/hashes/src/index.ts +33 -0
  365. package/node_modules/@noble/hashes/src/legacy.ts +339 -0
  366. package/node_modules/@noble/hashes/src/pbkdf2.ts +175 -0
  367. package/node_modules/@noble/hashes/src/scrypt.ts +315 -0
  368. package/node_modules/@noble/hashes/src/sha2.ts +530 -0
  369. package/node_modules/@noble/hashes/src/sha3-addons.ts +983 -0
  370. package/node_modules/@noble/hashes/src/sha3.ts +485 -0
  371. package/node_modules/@noble/hashes/src/utils.ts +848 -0
  372. package/node_modules/@noble/hashes/src/webcrypto.ts +239 -0
  373. package/node_modules/@noble/hashes/utils.d.ts +519 -0
  374. package/node_modules/@noble/hashes/utils.d.ts.map +1 -0
  375. package/node_modules/@noble/hashes/utils.js +578 -0
  376. package/node_modules/@noble/hashes/utils.js.map +1 -0
  377. package/node_modules/@noble/hashes/webcrypto.d.ts +120 -0
  378. package/node_modules/@noble/hashes/webcrypto.d.ts.map +1 -0
  379. package/node_modules/@noble/hashes/webcrypto.js +165 -0
  380. package/node_modules/@noble/hashes/webcrypto.js.map +1 -0
  381. package/node_modules/ws/LICENSE +20 -0
  382. package/node_modules/ws/README.md +548 -0
  383. package/node_modules/ws/browser.js +8 -0
  384. package/node_modules/ws/index.js +22 -0
  385. package/node_modules/ws/lib/buffer-util.js +131 -0
  386. package/node_modules/ws/lib/constants.js +19 -0
  387. package/node_modules/ws/lib/event-target.js +292 -0
  388. package/node_modules/ws/lib/extension.js +203 -0
  389. package/node_modules/ws/lib/limiter.js +55 -0
  390. package/node_modules/ws/lib/permessage-deflate.js +530 -0
  391. package/node_modules/ws/lib/receiver.js +743 -0
  392. package/node_modules/ws/lib/sender.js +607 -0
  393. package/node_modules/ws/lib/stream.js +161 -0
  394. package/node_modules/ws/lib/subprotocol.js +62 -0
  395. package/node_modules/ws/lib/validation.js +152 -0
  396. package/node_modules/ws/lib/websocket-server.js +562 -0
  397. package/node_modules/ws/lib/websocket.js +1407 -0
  398. package/node_modules/ws/package.json +74 -0
  399. package/node_modules/ws/wrapper.mjs +21 -0
  400. package/package.json +53 -0
@@ -0,0 +1,1714 @@
1
+ import {
2
+ VOID3gxj6tk5isa35 as VOID,
3
+ initMetadataForClassbxx6q50dy2s7 as initMetadataForClass,
4
+ Unit_instance3vdlo4e4f5ggx as Unit_instance,
5
+ IllegalArgumentException2asla15b5jaob as IllegalArgumentException,
6
+ toString1pkumu07cwy4m as toString,
7
+ abs1kdzbjes1idip as abs,
8
+ StringBuildermazzzhj6kkai as StringBuilder,
9
+ constructCallableReference23y65rf941mch as constructCallableReference,
10
+ ArrayList3it5z8td81qkl as ArrayList,
11
+ sequence2vgswtrxvqoa7 as sequence,
12
+ fill2542d4m9l93pn as fill,
13
+ protoOf180f3jzyo7rfj as protoOf,
14
+ THROW_CCE2g6jy02ryeudk as THROW_CCE,
15
+ isIntArrayeijsubfngq38 as isIntArray,
16
+ IllegalStateExceptionkoljg5n0nrlr as IllegalStateException,
17
+ _Char___init__impl__6a9atx2yltdocdrxs4d as _Char___init__impl__6a9atx,
18
+ endsWith1a79dp5rc3sfv as endsWith,
19
+ charSequenceLength3278n89t01tmv as charSequenceLength,
20
+ charSequenceGet1vxk1y5n17t1z as charSequenceGet,
21
+ Char19o2r8palgjof as Char,
22
+ Char__compareTo_impl_ypi4mb1yxpplfe5vmm as Char__compareTo_impl_ypi4mb,
23
+ contains2el4s70rdq4ld as contains,
24
+ charSequenceSubSequence1iwpdba8s3jc7 as charSequenceSubSequence,
25
+ Char__toInt_impl_vasixd1ka89vowck9tn as Char__toInt_impl_vasixd,
26
+ captureStack1fzi4aczwc4hg as captureStack,
27
+ setOf45ia9pnfhe90 as setOf,
28
+ listOf1jh22dvmctj1r as listOf,
29
+ toString1h6jjoch8cjt8 as toString_0,
30
+ toByte4i43936u611k as toByte,
31
+ copyOfRange3alro60z4hhf8 as copyOfRange,
32
+ startsWith641pyr7vf687 as startsWith,
33
+ add2suhfggl4zvkk as add,
34
+ fromInt2ii0rejb1w62w as fromInt,
35
+ CancellationException3b36o9qz53rgr as CancellationException,
36
+ subtract2orl8z9upxd9l as subtract,
37
+ convertToInty04h231mmjoh as convertToInt,
38
+ LinkedHashMap1zhqxkxv3xnkl as LinkedHashMap,
39
+ compareTo3ankvs086tmwq as compareTo,
40
+ NoSuchElementException679xzhnp5bpj as NoSuchElementException,
41
+ Collection1k04j3hzsbod0 as Collection,
42
+ isInterface3d6p8outrmvmk as isInterface,
43
+ emptyList1g2z5xcrvp2zy as emptyList,
44
+ initMetadataForCompanion1wyw17z38v6ac as initMetadataForCompanion,
45
+ ensureNotNull1e947j3ixpazm as ensureNotNull,
46
+ isCharSequence1ju9jr1w86plq as isCharSequence,
47
+ getStringHashCode26igk1bx568vk as getStringHashCode,
48
+ CharSequence1ceii1xorfwh7 as CharSequence,
49
+ IndexOutOfBoundsException1qfr429iumro0 as IndexOutOfBoundsException,
50
+ charArray2ujmm1qusno00 as charArray,
51
+ shiftLeft3tsh2sstjchzn as shiftLeft,
52
+ NumberFormatException3bgsm2s9o4t55 as NumberFormatException,
53
+ toString336ienavfnzn0 as toString_1,
54
+ charCodeAt1yspne1d8erbm as charCodeAt,
55
+ numberRangeToNumber25vse2rgp6rs8 as numberRangeToNumber,
56
+ collectionSizeOrDefault36dulx8yinfqm as collectionSizeOrDefault,
57
+ numberToLong2pakxeg38estk as numberToLong,
58
+ toLongArray23ixicpzp5r3w as toLongArray,
59
+ Char__plus_impl_qi7pgj1h8009bm3fa2t as Char__plus_impl_qi7pgj,
60
+ Char__minus_impl_a2frrh3216wnsvv1j3k as Char__minus_impl_a2frrh,
61
+ toByteArray3caw0hip00os as toByteArray,
62
+ isWhitespace25occ8z1ed1s9 as isWhitespace,
63
+ } from '@attocash/commons-core/kotlin-kotlin-stdlib.mjs';
64
+ import {
65
+ MultiPartData57syw40llxls as MultiPartData,
66
+ MultiPart_getInstance1k6b6wx1k1sjr as MultiPart_getInstance,
67
+ Companion_getInstance1pptfj8vjmgsz as Companion_getInstance,
68
+ } from './ktor-ktor-http.mjs';
69
+ import {
70
+ DefaultPool2gb1fm4epwgu9 as DefaultPool,
71
+ readLineStrictTo30g42df56og5l as readLineStrictTo,
72
+ Companion_getInstance33j3lym6q7yx7 as Companion_getInstance_0,
73
+ LineEndingMode__plus_impl_ttpz2j3u2ebrlepd29o as LineEndingMode__plus_impl_ttpz2j,
74
+ readUntil13nwpwqdlw2vo as readUntil,
75
+ copyTo1e8cxw3cmqjst as copyTo,
76
+ skipIfFound2z2la3mzzpubl as skipIfFound,
77
+ counted3iniv3aql3f9n as counted,
78
+ writer1eia5its2a1fh as writer,
79
+ readRemaining1kbpbgdrq25q1 as readRemaining,
80
+ get_remaining1lapv95kcmm0y as get_remaining,
81
+ ByteChannel3cxdguezl3lu7 as ByteChannel,
82
+ close3semq7pafb42g as close,
83
+ readPacket25aqlhslm04t6 as readPacket,
84
+ toByteArray1i3ns5jnoqlv6 as toByteArray_0,
85
+ NoPoolImplgos9n8jphzjp as NoPoolImpl,
86
+ } from './ktor-ktor-io.mjs';
87
+ import {
88
+ ByteString10sanmoo66key as ByteString,
89
+ ByteString3c9fk8lsh3lvs as ByteString_0,
90
+ } from '@attocash/commons-core/kotlinx-io-kotlinx-io-bytestring.mjs';
91
+ import {
92
+ IOException1wyutdmfe71nu as IOException,
93
+ EOFExceptionh831u25jcq9n as EOFException,
94
+ } from '@attocash/commons-core/kotlinx-io-kotlinx-io-core.mjs';
95
+ import {
96
+ produce1iljho2c8bp6o as produce,
97
+ CompletableDeferred2lnqvsbvx74d3 as CompletableDeferred,
98
+ } from './kotlinx-coroutines-core.mjs';
99
+ //region block: imports
100
+ var imul = Math.imul;
101
+ //endregion
102
+ //region block: pre-declaration
103
+ class CIOMultipartDataBase {
104
+ constructor(coroutineContext, channel, contentType, contentLength, formFieldLimit) {
105
+ formFieldLimit = formFieldLimit === VOID ? 65536n : formFieldLimit;
106
+ this.p4m_1 = coroutineContext;
107
+ this.q4m_1 = null;
108
+ this.r4m_1 = parseMultipart(this, channel, contentType, contentLength, formFieldLimit);
109
+ }
110
+ o2r() {
111
+ return this.p4m_1;
112
+ }
113
+ }
114
+ class HttpHeadersMap {
115
+ constructor(builder) {
116
+ this.s4m_1 = builder;
117
+ this.t4m_1 = 0;
118
+ this.u4m_1 = 0;
119
+ this.v4m_1 = get_HeadersDataPool().d41();
120
+ }
121
+ p1i(name) {
122
+ if (this.t4m_1 === 0)
123
+ return null;
124
+ // Inline function 'kotlin.math.absoluteValue' call
125
+ var this_0 = hashCodeLowerCase(name);
126
+ var hash = abs(this_0);
127
+ var headerIndex = hash % this.u4m_1 | 0;
128
+ while (!(this.v4m_1.a4n(imul(headerIndex, 6) + 0 | 0) === -1)) {
129
+ if (headerHasName(this, name, imul(headerIndex, 6))) {
130
+ return this.c4n(imul(headerIndex, 6));
131
+ }
132
+ headerIndex = (headerIndex + 1 | 0) % this.u4m_1 | 0;
133
+ }
134
+ return null;
135
+ }
136
+ d4n() {
137
+ return this.v4m_1.z4m();
138
+ }
139
+ b4n(nameStartIndex, nameEndIndex, valueStartIndex, valueEndIndex) {
140
+ if (thresholdReached(this)) {
141
+ resize(this);
142
+ }
143
+ // Inline function 'kotlin.math.absoluteValue' call
144
+ var this_0 = hashCodeLowerCase(this.s4m_1, nameStartIndex, nameEndIndex);
145
+ var hash = abs(this_0);
146
+ var name = this.s4m_1.c(nameStartIndex, nameEndIndex);
147
+ var headerIndex = hash % this.u4m_1 | 0;
148
+ var sameNameHeaderIndex = -1;
149
+ while (!(this.v4m_1.a4n(imul(headerIndex, 6) + 0 | 0) === -1)) {
150
+ if (headerHasName(this, name, imul(headerIndex, 6))) {
151
+ sameNameHeaderIndex = headerIndex;
152
+ }
153
+ headerIndex = (headerIndex + 1 | 0) % this.u4m_1 | 0;
154
+ }
155
+ var headerOffset = imul(headerIndex, 6);
156
+ this.v4m_1.l4n(headerOffset + 0 | 0, hash);
157
+ this.v4m_1.l4n(headerOffset + 1 | 0, nameStartIndex);
158
+ this.v4m_1.l4n(headerOffset + 2 | 0, nameEndIndex);
159
+ this.v4m_1.l4n(headerOffset + 3 | 0, valueStartIndex);
160
+ this.v4m_1.l4n(headerOffset + 4 | 0, valueEndIndex);
161
+ this.v4m_1.l4n(headerOffset + 5 | 0, -1);
162
+ if (!(sameNameHeaderIndex === -1)) {
163
+ this.v4m_1.l4n(imul(sameNameHeaderIndex, 6) + 5 | 0, headerIndex);
164
+ }
165
+ this.t4m_1 = this.t4m_1 + 1 | 0;
166
+ }
167
+ m4n(headerOffset) {
168
+ var nameStartIndex = this.v4m_1.a4n(headerOffset + 1 | 0);
169
+ var nameEndIndex = this.v4m_1.a4n(headerOffset + 2 | 0);
170
+ return this.s4m_1.c(nameStartIndex, nameEndIndex);
171
+ }
172
+ c4n(headerOffset) {
173
+ var valueStartIndex = this.v4m_1.a4n(headerOffset + 3 | 0);
174
+ var valueEndIndex = this.v4m_1.a4n(headerOffset + 4 | 0);
175
+ return this.s4m_1.c(valueStartIndex, valueEndIndex);
176
+ }
177
+ i1g() {
178
+ this.t4m_1 = 0;
179
+ this.u4m_1 = 0;
180
+ get_HeadersDataPool().e41(this.v4m_1);
181
+ this.v4m_1 = get_HeadersDataPool().d41();
182
+ }
183
+ toString() {
184
+ // Inline function 'kotlin.text.buildString' call
185
+ // Inline function 'kotlin.apply' call
186
+ var this_0 = StringBuilder.h1();
187
+ dumpTo(this, '', this_0);
188
+ return this_0.toString();
189
+ }
190
+ }
191
+ class HeadersData {
192
+ constructor() {
193
+ var tmp = this;
194
+ // Inline function 'kotlin.collections.mutableListOf' call
195
+ tmp.w4m_1 = ArrayList.f2();
196
+ }
197
+ x4m() {
198
+ return this.w4m_1.p2();
199
+ }
200
+ y4m(subArraysCount) {
201
+ // Inline function 'kotlin.repeat' call
202
+ var inductionVariable = 0;
203
+ if (inductionVariable < subArraysCount)
204
+ do {
205
+ var index = inductionVariable;
206
+ inductionVariable = inductionVariable + 1 | 0;
207
+ this.w4m_1.e2(get_IntArrayPool().d41());
208
+ }
209
+ while (inductionVariable < subArraysCount);
210
+ }
211
+ a4n(index) {
212
+ return this.w4m_1.q2(index / 768 | 0)[index % 768 | 0];
213
+ }
214
+ l4n(index, value) {
215
+ this.w4m_1.q2(index / 768 | 0)[index % 768 | 0] = value;
216
+ }
217
+ z4m() {
218
+ return sequence(HeadersData$headersStarts$slambda(this));
219
+ }
220
+ i1g() {
221
+ var _iterator__ex2g4s = this.w4m_1.l1();
222
+ while (_iterator__ex2g4s.m1()) {
223
+ var array = _iterator__ex2g4s.n1();
224
+ get_IntArrayPool().e41(array);
225
+ }
226
+ this.w4m_1.j4();
227
+ }
228
+ }
229
+ class IntArrayPool$1 extends DefaultPool {
230
+ constructor() {
231
+ super(1000);
232
+ }
233
+ w40() {
234
+ var tmp = 0;
235
+ var tmp_0 = new Int32Array(768);
236
+ while (tmp < 768) {
237
+ tmp_0[tmp] = -1;
238
+ tmp = tmp + 1 | 0;
239
+ }
240
+ return tmp_0;
241
+ }
242
+ q4n(instance) {
243
+ fill(instance, -1);
244
+ return protoOf(DefaultPool).b41.call(this, instance);
245
+ }
246
+ b41(instance) {
247
+ return this.q4n(isIntArray(instance) ? instance : THROW_CCE());
248
+ }
249
+ }
250
+ class HeadersDataPool$1 extends DefaultPool {
251
+ constructor() {
252
+ super(1000);
253
+ }
254
+ w40() {
255
+ return new HeadersData();
256
+ }
257
+ u4n(instance) {
258
+ instance.i1g();
259
+ return protoOf(DefaultPool).b41.call(this, instance);
260
+ }
261
+ b41(instance) {
262
+ return this.u4n(instance instanceof HeadersData ? instance : THROW_CCE());
263
+ }
264
+ }
265
+ class ParserException extends IllegalStateException {
266
+ constructor(message) {
267
+ return new.target.b4o(message);
268
+ }
269
+ static b4o(message) {
270
+ var $this = this.o(message);
271
+ captureStack($this, $this.a4o_1);
272
+ return $this;
273
+ }
274
+ }
275
+ class MultipartEvent {}
276
+ class Preamble extends MultipartEvent {
277
+ constructor(body) {
278
+ super();
279
+ this.d4o_1 = body;
280
+ }
281
+ }
282
+ class MultipartPart extends MultipartEvent {
283
+ constructor(headers, body) {
284
+ super();
285
+ this.e4o_1 = headers;
286
+ this.f4o_1 = body;
287
+ }
288
+ }
289
+ class Epilogue extends MultipartEvent {
290
+ constructor(body) {
291
+ super();
292
+ this.g4o_1 = body;
293
+ }
294
+ }
295
+ class Node {
296
+ constructor(ch, exact, children) {
297
+ this.l4o_1 = ch;
298
+ this.m4o_1 = exact;
299
+ this.n4o_1 = children;
300
+ var tmp = this;
301
+ var tmp_0 = 0;
302
+ // Inline function 'kotlin.arrayOfNulls' call
303
+ var tmp_1 = Array(256);
304
+ while (tmp_0 < 256) {
305
+ var tmp_2 = tmp_0;
306
+ var tmp0 = this.n4o_1;
307
+ var tmp$ret$2;
308
+ $l$block_0: {
309
+ // Inline function 'kotlin.collections.singleOrNull' call
310
+ var single = null;
311
+ var found = false;
312
+ var _iterator__ex2g4s = tmp0.l1();
313
+ while (_iterator__ex2g4s.m1()) {
314
+ var element = _iterator__ex2g4s.n1();
315
+ // Inline function 'kotlin.code' call
316
+ var this_0 = element.l4o_1;
317
+ if (Char__toInt_impl_vasixd(this_0) === tmp_2) {
318
+ if (found) {
319
+ tmp$ret$2 = null;
320
+ break $l$block_0;
321
+ }
322
+ single = element;
323
+ found = true;
324
+ }
325
+ }
326
+ if (!found) {
327
+ tmp$ret$2 = null;
328
+ break $l$block_0;
329
+ }
330
+ tmp$ret$2 = single;
331
+ }
332
+ tmp_1[tmp_2] = tmp$ret$2;
333
+ tmp_0 = tmp_0 + 1 | 0;
334
+ }
335
+ tmp.o4o_1 = tmp_1;
336
+ }
337
+ }
338
+ class Companion {
339
+ c4o(from) {
340
+ var tmp = AsciiCharTree$Companion$build$lambda;
341
+ return this.p4o(from, tmp, AsciiCharTree$Companion$build$lambda_0);
342
+ }
343
+ p4o(from, length, charAt) {
344
+ var tmp$ret$0;
345
+ $l$block_0: {
346
+ // Inline function 'kotlin.collections.maxByOrNull' call
347
+ var iterator = from.l1();
348
+ if (!iterator.m1()) {
349
+ tmp$ret$0 = null;
350
+ break $l$block_0;
351
+ }
352
+ var maxElem = iterator.n1();
353
+ if (!iterator.m1()) {
354
+ tmp$ret$0 = maxElem;
355
+ break $l$block_0;
356
+ }
357
+ var maxValue = length(maxElem);
358
+ do {
359
+ var e = iterator.n1();
360
+ var v = length(e);
361
+ if (compareTo(maxValue, v) < 0) {
362
+ maxElem = e;
363
+ maxValue = v;
364
+ }
365
+ }
366
+ while (iterator.m1());
367
+ tmp$ret$0 = maxElem;
368
+ }
369
+ var tmp0_safe_receiver = tmp$ret$0;
370
+ var tmp;
371
+ if (tmp0_safe_receiver == null) {
372
+ tmp = null;
373
+ } else {
374
+ // Inline function 'kotlin.let' call
375
+ tmp = length(tmp0_safe_receiver);
376
+ }
377
+ var tmp1_elvis_lhs = tmp;
378
+ var tmp_0;
379
+ if (tmp1_elvis_lhs == null) {
380
+ throw NoSuchElementException.j2('Unable to build char tree from an empty list');
381
+ } else {
382
+ tmp_0 = tmp1_elvis_lhs;
383
+ }
384
+ var maxLen = tmp_0;
385
+ var tmp$ret$2;
386
+ $l$block_2: {
387
+ // Inline function 'kotlin.collections.any' call
388
+ var tmp_1;
389
+ if (isInterface(from, Collection)) {
390
+ tmp_1 = from.j1();
391
+ } else {
392
+ tmp_1 = false;
393
+ }
394
+ if (tmp_1) {
395
+ tmp$ret$2 = false;
396
+ break $l$block_2;
397
+ }
398
+ var _iterator__ex2g4s = from.l1();
399
+ while (_iterator__ex2g4s.m1()) {
400
+ var element = _iterator__ex2g4s.n1();
401
+ if (length(element) === 0) {
402
+ tmp$ret$2 = true;
403
+ break $l$block_2;
404
+ }
405
+ }
406
+ tmp$ret$2 = false;
407
+ }
408
+ if (tmp$ret$2)
409
+ throw IllegalArgumentException.n2('There should be no empty entries');
410
+ var root = ArrayList.f2();
411
+ build(this, root, from, maxLen, 0, length, charAt);
412
+ root.l8();
413
+ return new AsciiCharTree(new Node(_Char___init__impl__6a9atx(0), emptyList(), root));
414
+ }
415
+ }
416
+ class AsciiCharTree {
417
+ constructor(root) {
418
+ this.q4o_1 = root;
419
+ }
420
+ }
421
+ class SubSequenceImpl {
422
+ constructor($outer, start, end) {
423
+ this.u4o_1 = $outer;
424
+ this.r4o_1 = start;
425
+ this.s4o_1 = end;
426
+ this.t4o_1 = null;
427
+ }
428
+ a() {
429
+ return this.s4o_1 - this.r4o_1 | 0;
430
+ }
431
+ b(index) {
432
+ var withOffset = index + this.r4o_1 | 0;
433
+ // Inline function 'kotlin.require' call
434
+ if (!(index >= 0)) {
435
+ var message = 'index is negative: ' + index;
436
+ throw IllegalArgumentException.n2(toString(message));
437
+ }
438
+ // Inline function 'kotlin.require' call
439
+ if (!(withOffset < this.s4o_1)) {
440
+ var message_0 = 'index (' + index + ') should be less than length (' + this.a() + ')';
441
+ throw IllegalArgumentException.n2(toString(message_0));
442
+ }
443
+ return getImpl(this.u4o_1, withOffset);
444
+ }
445
+ c(startIndex, endIndex) {
446
+ // Inline function 'kotlin.require' call
447
+ if (!(startIndex >= 0)) {
448
+ var message = 'start is negative: ' + startIndex;
449
+ throw IllegalArgumentException.n2(toString(message));
450
+ }
451
+ // Inline function 'kotlin.require' call
452
+ if (!(startIndex <= endIndex)) {
453
+ var message_0 = 'start (' + startIndex + ') should be less or equal to end (' + endIndex + ')';
454
+ throw IllegalArgumentException.n2(toString(message_0));
455
+ }
456
+ // Inline function 'kotlin.require' call
457
+ if (!(endIndex <= (this.s4o_1 - this.r4o_1 | 0))) {
458
+ var message_1 = 'end should be less than length (' + this.a() + ')';
459
+ throw IllegalArgumentException.n2(toString(message_1));
460
+ }
461
+ if (startIndex === endIndex)
462
+ return '';
463
+ return new SubSequenceImpl(this.u4o_1, this.r4o_1 + startIndex | 0, this.r4o_1 + endIndex | 0);
464
+ }
465
+ toString() {
466
+ var tmp0_elvis_lhs = this.t4o_1;
467
+ var tmp;
468
+ if (tmp0_elvis_lhs == null) {
469
+ // Inline function 'kotlin.also' call
470
+ var this_0 = toString(copy(this.u4o_1, this.r4o_1, this.s4o_1));
471
+ this.t4o_1 = this_0;
472
+ tmp = this_0;
473
+ } else {
474
+ tmp = tmp0_elvis_lhs;
475
+ }
476
+ return tmp;
477
+ }
478
+ equals(other) {
479
+ if (!(!(other == null) ? isCharSequence(other) : false))
480
+ return false;
481
+ if (!(charSequenceLength(other) === this.a()))
482
+ return false;
483
+ return rangeEqualsImpl(this.u4o_1, this.r4o_1, other, 0, this.a());
484
+ }
485
+ hashCode() {
486
+ var tmp0_safe_receiver = this.t4o_1;
487
+ var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : getStringHashCode(tmp0_safe_receiver);
488
+ return tmp1_elvis_lhs == null ? hashCodeImpl(this.u4o_1, this.r4o_1, this.s4o_1) : tmp1_elvis_lhs;
489
+ }
490
+ }
491
+ class CharArrayBuilder {
492
+ constructor(pool) {
493
+ pool = pool === VOID ? get_CharArrayPool() : pool;
494
+ this.e4n_1 = pool;
495
+ this.f4n_1 = null;
496
+ this.g4n_1 = null;
497
+ this.h4n_1 = null;
498
+ this.i4n_1 = false;
499
+ this.j4n_1 = 0;
500
+ this.k4n_1 = 0;
501
+ }
502
+ a() {
503
+ return this.k4n_1;
504
+ }
505
+ b(index) {
506
+ // Inline function 'kotlin.require' call
507
+ if (!(index >= 0)) {
508
+ var message = 'index is negative: ' + index;
509
+ throw IllegalArgumentException.n2(toString(message));
510
+ }
511
+ // Inline function 'kotlin.require' call
512
+ if (!(index < this.k4n_1)) {
513
+ var message_0 = 'index ' + index + ' is not in range [0, ' + this.k4n_1 + ')';
514
+ throw IllegalArgumentException.n2(toString(message_0));
515
+ }
516
+ return getImpl(this, index);
517
+ }
518
+ c(startIndex, endIndex) {
519
+ // Inline function 'kotlin.require' call
520
+ if (!(startIndex <= endIndex)) {
521
+ var message = 'startIndex (' + startIndex + ') should be less or equal to endIndex (' + endIndex + ')';
522
+ throw IllegalArgumentException.n2(toString(message));
523
+ }
524
+ // Inline function 'kotlin.require' call
525
+ if (!(startIndex >= 0)) {
526
+ var message_0 = 'startIndex is negative: ' + startIndex;
527
+ throw IllegalArgumentException.n2(toString(message_0));
528
+ }
529
+ // Inline function 'kotlin.require' call
530
+ if (!(endIndex <= this.k4n_1)) {
531
+ var message_1 = 'endIndex (' + endIndex + ') is greater than length (' + this.k4n_1 + ')';
532
+ throw IllegalArgumentException.n2(toString(message_1));
533
+ }
534
+ return new SubSequenceImpl(this, startIndex, endIndex);
535
+ }
536
+ toString() {
537
+ var tmp0_elvis_lhs = this.h4n_1;
538
+ var tmp;
539
+ if (tmp0_elvis_lhs == null) {
540
+ // Inline function 'kotlin.also' call
541
+ var this_0 = toString(copy(this, 0, this.k4n_1));
542
+ this.h4n_1 = this_0;
543
+ tmp = this_0;
544
+ } else {
545
+ tmp = tmp0_elvis_lhs;
546
+ }
547
+ return tmp;
548
+ }
549
+ equals(other) {
550
+ if (!(!(other == null) ? isCharSequence(other) : false))
551
+ return false;
552
+ if (!(this.k4n_1 === charSequenceLength(other)))
553
+ return false;
554
+ return rangeEqualsImpl(this, 0, other, 0, this.k4n_1);
555
+ }
556
+ hashCode() {
557
+ var tmp0_safe_receiver = this.h4n_1;
558
+ var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : getStringHashCode(tmp0_safe_receiver);
559
+ return tmp1_elvis_lhs == null ? hashCodeImpl(this, 0, this.k4n_1) : tmp1_elvis_lhs;
560
+ }
561
+ k1(value) {
562
+ nonFullBuffer(this)[ensureNotNull(this.g4n_1).length - this.j4n_1 | 0] = value;
563
+ this.h4n_1 = null;
564
+ this.j4n_1 = this.j4n_1 - 1 | 0;
565
+ this.k4n_1 = this.k4n_1 + 1 | 0;
566
+ return this;
567
+ }
568
+ xg(value, startIndex, endIndex) {
569
+ if (value == null)
570
+ return this;
571
+ var current = startIndex;
572
+ while (current < endIndex) {
573
+ var buffer = nonFullBuffer(this);
574
+ var offset = buffer.length - this.j4n_1 | 0;
575
+ var tmp0 = endIndex - current | 0;
576
+ // Inline function 'kotlin.math.min' call
577
+ var b = this.j4n_1;
578
+ var bytesToCopy = Math.min(tmp0, b);
579
+ var inductionVariable = 0;
580
+ if (inductionVariable < bytesToCopy)
581
+ do {
582
+ var i = inductionVariable;
583
+ inductionVariable = inductionVariable + 1 | 0;
584
+ buffer[offset + i | 0] = charSequenceGet(value, current + i | 0);
585
+ }
586
+ while (inductionVariable < bytesToCopy);
587
+ current = current + bytesToCopy | 0;
588
+ this.j4n_1 = this.j4n_1 - bytesToCopy | 0;
589
+ }
590
+ this.h4n_1 = null;
591
+ this.k4n_1 = this.k4n_1 + (endIndex - startIndex | 0) | 0;
592
+ return this;
593
+ }
594
+ o2(value) {
595
+ if (value == null)
596
+ return this;
597
+ return this.xg(value, 0, charSequenceLength(value));
598
+ }
599
+ i1g() {
600
+ var list = this.f4n_1;
601
+ if (!(list == null)) {
602
+ this.g4n_1 = null;
603
+ var inductionVariable = 0;
604
+ var last = list.p2();
605
+ if (inductionVariable < last)
606
+ do {
607
+ var i = inductionVariable;
608
+ inductionVariable = inductionVariable + 1 | 0;
609
+ this.e4n_1.e41(list.q2(i));
610
+ }
611
+ while (inductionVariable < last);
612
+ } else {
613
+ var tmp0_safe_receiver = this.g4n_1;
614
+ if (tmp0_safe_receiver == null)
615
+ null;
616
+ else {
617
+ // Inline function 'kotlin.let' call
618
+ this.e4n_1.e41(tmp0_safe_receiver);
619
+ }
620
+ this.g4n_1 = null;
621
+ }
622
+ this.i4n_1 = true;
623
+ this.f4n_1 = null;
624
+ this.h4n_1 = null;
625
+ this.k4n_1 = 0;
626
+ this.j4n_1 = 0;
627
+ }
628
+ }
629
+ class CharArrayPool$1 extends NoPoolImpl {
630
+ d41() {
631
+ return charArray(2048);
632
+ }
633
+ }
634
+ class CharArrayPool$2 extends DefaultPool {
635
+ constructor() {
636
+ super(4096);
637
+ }
638
+ w40() {
639
+ return charArray(2048);
640
+ }
641
+ }
642
+ class UnsupportedMediaTypeExceptionCIO extends IOException {
643
+ constructor(message) {
644
+ return new.target.k4o(message);
645
+ }
646
+ static k4o(message) {
647
+ var $this = this.x1v(message);
648
+ captureStack($this, $this.j4o_1);
649
+ return $this;
650
+ }
651
+ }
652
+ class MutableRange {
653
+ constructor(start, end) {
654
+ this.v4n_1 = start;
655
+ this.w4n_1 = end;
656
+ }
657
+ toString() {
658
+ return 'MutableRange(start=' + this.v4n_1 + ', end=' + this.w4n_1 + ')';
659
+ }
660
+ }
661
+ //endregion
662
+ function get_IntArrayPool() {
663
+ _init_properties_HttpHeadersMap_kt__hwatby();
664
+ return IntArrayPool;
665
+ }
666
+ var IntArrayPool;
667
+ function get_HeadersDataPool() {
668
+ _init_properties_HttpHeadersMap_kt__hwatby();
669
+ return HeadersDataPool;
670
+ }
671
+ var HeadersDataPool;
672
+ function thresholdReached($this) {
673
+ return $this.t4m_1 >= $this.u4m_1 * 0.75;
674
+ }
675
+ function resize($this) {
676
+ var prevSize = $this.t4m_1;
677
+ var prevData = $this.v4m_1;
678
+ $this.t4m_1 = 0;
679
+ $this.u4m_1 = imul($this.u4m_1, 2) | 128;
680
+ var tmp = $this;
681
+ // Inline function 'kotlin.apply' call
682
+ var this_0 = get_HeadersDataPool().d41();
683
+ this_0.y4m(imul(prevData.x4m(), 2) | 1);
684
+ tmp.v4m_1 = this_0;
685
+ var _iterator__ex2g4s = prevData.z4m().l1();
686
+ while (_iterator__ex2g4s.m1()) {
687
+ var headerOffset = _iterator__ex2g4s.n1();
688
+ $this.b4n(prevData.a4n(headerOffset + 1 | 0), prevData.a4n(headerOffset + 2 | 0), prevData.a4n(headerOffset + 3 | 0), prevData.a4n(headerOffset + 4 | 0));
689
+ }
690
+ get_HeadersDataPool().e41(prevData);
691
+ // Inline function 'kotlin.require' call
692
+ // Inline function 'kotlin.require' call
693
+ if (!(prevSize === $this.t4m_1)) {
694
+ var message = 'Failed requirement.';
695
+ throw IllegalArgumentException.n2(toString(message));
696
+ }
697
+ }
698
+ function headerHasName($this, name, headerOffset) {
699
+ var nameStartIndex = $this.v4m_1.a4n(headerOffset + 1 | 0);
700
+ var nameEndIndex = $this.v4m_1.a4n(headerOffset + 2 | 0);
701
+ return equalsLowerCase($this.s4m_1, nameStartIndex, nameEndIndex, name);
702
+ }
703
+ function HeadersData$headersStarts$slambda(this$0) {
704
+ return constructCallableReference(function *($this$sequence, $completion) {
705
+ var joinedIndex = 0;
706
+ var _iterator__ex2g4s = this$0.w4m_1.l1();
707
+ while (_iterator__ex2g4s.m1()) {
708
+ var arr = _iterator__ex2g4s.n1();
709
+ var localIndex = 0;
710
+ while (localIndex < arr.length) {
711
+ if (!(this$0.a4n(joinedIndex + 0 | 0) === -1)) {
712
+ yield* $this$sequence.sk(joinedIndex, $completion);
713
+ }
714
+ localIndex = localIndex + 6 | 0;
715
+ joinedIndex = joinedIndex + 6 | 0;
716
+ }
717
+ }
718
+ return Unit_instance;
719
+ }, 1);
720
+ }
721
+ function dumpTo(_this__u8e3s4, indent, out) {
722
+ _init_properties_HttpHeadersMap_kt__hwatby();
723
+ var _iterator__ex2g4s = _this__u8e3s4.d4n().l1();
724
+ while (_iterator__ex2g4s.m1()) {
725
+ var offset = _iterator__ex2g4s.n1();
726
+ out.o2(indent);
727
+ out.o2(_this__u8e3s4.m4n(offset));
728
+ out.o2(' => ');
729
+ out.o2(_this__u8e3s4.c4n(offset));
730
+ out.o2('\n');
731
+ }
732
+ }
733
+ var properties_initialized_HttpHeadersMap_kt_kotj4w;
734
+ function _init_properties_HttpHeadersMap_kt__hwatby() {
735
+ if (!properties_initialized_HttpHeadersMap_kt_kotj4w) {
736
+ properties_initialized_HttpHeadersMap_kt_kotj4w = true;
737
+ IntArrayPool = new IntArrayPool$1();
738
+ HeadersDataPool = new HeadersDataPool$1();
739
+ }
740
+ }
741
+ function get_hostForbiddenSymbols() {
742
+ _init_properties_HttpParser_kt__gbdom1();
743
+ return hostForbiddenSymbols;
744
+ }
745
+ var hostForbiddenSymbols;
746
+ var httpLineEndings;
747
+ var versions;
748
+ function *parseHeaders(input, builder, range, $completion) {
749
+ range = range === VOID ? new MutableRange(0, 0) : range;
750
+ var headers = new HttpHeadersMap(builder);
751
+ try {
752
+ $l$loop: while (true) {
753
+ if ((yield* readLineStrictTo(input, builder, 8192n, VOID, $completion)) === -1n) {
754
+ headers.i1g();
755
+ return null;
756
+ }
757
+ range.w4n_1 = builder.k4n_1;
758
+ var rangeLength = range.w4n_1 - range.v4n_1 | 0;
759
+ if (rangeLength === 0)
760
+ break $l$loop;
761
+ if (rangeLength >= 8192) {
762
+ // Inline function 'kotlin.error' call
763
+ var message = 'Header line length limit exceeded';
764
+ throw IllegalStateException.o(toString(message));
765
+ }
766
+ var nameStart = range.v4n_1;
767
+ var nameEnd = parseHeaderName(builder, range);
768
+ var headerEnd = range.w4n_1;
769
+ parseHeaderValue(builder, range);
770
+ var valueStart = range.v4n_1;
771
+ var valueEnd = range.w4n_1;
772
+ range.v4n_1 = headerEnd;
773
+ headers.b4n(nameStart, nameEnd, valueStart, valueEnd);
774
+ }
775
+ var host = headers.p1i('Host');
776
+ if (!(host == null)) {
777
+ validateHostHeader(host);
778
+ }
779
+ return headers;
780
+ } catch ($p) {
781
+ if ($p instanceof Error) {
782
+ var t = $p;
783
+ headers.i1g();
784
+ throw t;
785
+ } else {
786
+ throw $p;
787
+ }
788
+ }
789
+ }
790
+ function parseHeaderName(text, range) {
791
+ _init_properties_HttpParser_kt__gbdom1();
792
+ var index = range.v4n_1;
793
+ var end = range.w4n_1;
794
+ while (index < end) {
795
+ var ch = text.b(index);
796
+ if (ch === _Char___init__impl__6a9atx(58) && !(index === range.v4n_1)) {
797
+ range.v4n_1 = index + 1 | 0;
798
+ return index;
799
+ }
800
+ if (isDelimiter(ch)) {
801
+ parseHeaderNameFailed(text, index, range.v4n_1, ch);
802
+ }
803
+ index = index + 1 | 0;
804
+ }
805
+ noColonFound(text, range);
806
+ }
807
+ function parseHeaderValue(text, range) {
808
+ _init_properties_HttpParser_kt__gbdom1();
809
+ var start = range.v4n_1;
810
+ var end = range.w4n_1;
811
+ var index = start;
812
+ index = skipSpacesAndHorizontalTabs(text, index, end);
813
+ if (index >= end) {
814
+ range.v4n_1 = end;
815
+ return Unit_instance;
816
+ }
817
+ var valueStart = index;
818
+ var valueLastIndex = index;
819
+ while (index < end) {
820
+ var ch = text.b(index);
821
+ if (ch !== _Char___init__impl__6a9atx(9) && ch !== _Char___init__impl__6a9atx(32))
822
+ if (ch === _Char___init__impl__6a9atx(13) || ch === _Char___init__impl__6a9atx(10)) {
823
+ characterIsNotAllowed(text, ch);
824
+ } else
825
+ valueLastIndex = index;
826
+ index = index + 1 | 0;
827
+ }
828
+ range.v4n_1 = valueStart;
829
+ range.w4n_1 = valueLastIndex + 1 | 0;
830
+ }
831
+ function validateHostHeader(host) {
832
+ _init_properties_HttpParser_kt__gbdom1();
833
+ if (endsWith(host, ':')) {
834
+ throw ParserException.b4o("Host header with ':' should contains port: " + toString(host));
835
+ }
836
+ var tmp$ret$0;
837
+ $l$block: {
838
+ // Inline function 'kotlin.text.any' call
839
+ var inductionVariable = 0;
840
+ while (inductionVariable < charSequenceLength(host)) {
841
+ var element = charSequenceGet(host, inductionVariable);
842
+ inductionVariable = inductionVariable + 1 | 0;
843
+ if (get_hostForbiddenSymbols().j3(new Char(element))) {
844
+ tmp$ret$0 = true;
845
+ break $l$block;
846
+ }
847
+ }
848
+ tmp$ret$0 = false;
849
+ }
850
+ if (tmp$ret$0) {
851
+ throw ParserException.b4o('Host cannot contain any of the following symbols: ' + toString(get_hostForbiddenSymbols()));
852
+ }
853
+ }
854
+ function isDelimiter(ch) {
855
+ _init_properties_HttpParser_kt__gbdom1();
856
+ return Char__compareTo_impl_ypi4mb(ch, _Char___init__impl__6a9atx(32)) <= 0 || contains('"(),/:;<=>?@[\\]{}', ch);
857
+ }
858
+ function parseHeaderNameFailed(text, index, start, ch) {
859
+ _init_properties_HttpParser_kt__gbdom1();
860
+ if (ch === _Char___init__impl__6a9atx(58)) {
861
+ throw ParserException.b4o('Empty header names are not allowed as per RFC7230.');
862
+ }
863
+ if (index === start) {
864
+ throw ParserException.b4o('Multiline headers via line folding is not supported since it is deprecated as per RFC7230.');
865
+ }
866
+ characterIsNotAllowed(text, ch);
867
+ }
868
+ function noColonFound(text, range) {
869
+ _init_properties_HttpParser_kt__gbdom1();
870
+ var tmp2 = range.v4n_1;
871
+ // Inline function 'kotlin.text.substring' call
872
+ var endIndex = range.w4n_1;
873
+ var tmp$ret$0 = toString(charSequenceSubSequence(text, tmp2, endIndex));
874
+ throw ParserException.b4o('No colon in HTTP header in ' + tmp$ret$0 + ' in builder: \n' + toString(text));
875
+ }
876
+ function characterIsNotAllowed(text, ch) {
877
+ _init_properties_HttpParser_kt__gbdom1();
878
+ // Inline function 'kotlin.code' call
879
+ var tmp$ret$0 = Char__toInt_impl_vasixd(ch);
880
+ throw ParserException.b4o('Character with code ' + (tmp$ret$0 & 255) + ' is not allowed in header names, \n' + toString(text));
881
+ }
882
+ var properties_initialized_HttpParser_kt_uedryv;
883
+ function _init_properties_HttpParser_kt__gbdom1() {
884
+ if (!properties_initialized_HttpParser_kt_uedryv) {
885
+ properties_initialized_HttpParser_kt_uedryv = true;
886
+ 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))]);
887
+ httpLineEndings = LineEndingMode__plus_impl_ttpz2j(Companion_getInstance_0().e40_1, Companion_getInstance_0().d40_1);
888
+ versions = Companion_instance.c4o(listOf(['HTTP/1.0', 'HTTP/1.1']));
889
+ }
890
+ }
891
+ function get_CrLf() {
892
+ _init_properties_Multipart_kt__ato98a();
893
+ return CrLf;
894
+ }
895
+ var CrLf;
896
+ function get_PrefixString() {
897
+ _init_properties_Multipart_kt__ato98a();
898
+ return PrefixString;
899
+ }
900
+ var PrefixString;
901
+ function parseMultipart(_this__u8e3s4, input, contentType, contentLength, maxPartSize) {
902
+ maxPartSize = maxPartSize === VOID ? 9223372036854775807n : maxPartSize;
903
+ _init_properties_Multipart_kt__ato98a();
904
+ if (!MultiPart_getInstance().h4a(contentType)) {
905
+ throw UnsupportedMediaTypeExceptionCIO.k4o('Failed to parse multipart: Content-Type should be multipart/* but it is ' + toString(contentType));
906
+ }
907
+ var boundaryByteBuffer = parseBoundaryInternal(contentType);
908
+ var boundaryBytes = ByteString.a1s(boundaryByteBuffer);
909
+ return parseMultipart_0(_this__u8e3s4, boundaryBytes, input, contentLength, maxPartSize);
910
+ }
911
+ function parseBoundaryInternal(contentType) {
912
+ _init_properties_Multipart_kt__ato98a();
913
+ var boundaryParameter = findBoundary(contentType);
914
+ if (boundaryParameter === -1) {
915
+ throw IOException.x1v("Failed to parse multipart: Content-Type's boundary parameter is missing");
916
+ }
917
+ var boundaryStart = boundaryParameter + 9 | 0;
918
+ var boundaryBytes = new Int8Array(74);
919
+ var position = {_v: 0};
920
+ parseBoundaryInternal$put(position, boundaryBytes, 13);
921
+ parseBoundaryInternal$put(position, boundaryBytes, 10);
922
+ parseBoundaryInternal$put(position, boundaryBytes, 45);
923
+ parseBoundaryInternal$put(position, boundaryBytes, 45);
924
+ var state = 0;
925
+ var inductionVariable = boundaryStart;
926
+ var last = charSequenceLength(contentType);
927
+ if (inductionVariable < last)
928
+ loop: do {
929
+ var i = inductionVariable;
930
+ inductionVariable = inductionVariable + 1 | 0;
931
+ var ch = charSequenceGet(contentType, i);
932
+ // Inline function 'kotlin.code' call
933
+ var v = Char__toInt_impl_vasixd(ch) & 65535;
934
+ if ((v & 65535) > 127) {
935
+ throw IOException.x1v('Failed to parse multipart: wrong boundary byte 0x' + toString_0(v, 16) + ' - should be 7bit character');
936
+ }
937
+ switch (state) {
938
+ case 0:
939
+ if (ch !== _Char___init__impl__6a9atx(32))
940
+ if (ch === _Char___init__impl__6a9atx(34)) {
941
+ state = 2;
942
+ } else if (ch === _Char___init__impl__6a9atx(59) || ch === _Char___init__impl__6a9atx(44)) {
943
+ break loop;
944
+ } else {
945
+ state = 1;
946
+ parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
947
+ }
948
+
949
+ break;
950
+ case 1:
951
+ if (ch === _Char___init__impl__6a9atx(32) || ch === _Char___init__impl__6a9atx(44) || ch === _Char___init__impl__6a9atx(59)) {
952
+ break loop;
953
+ } else {
954
+ parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
955
+ }
956
+
957
+ break;
958
+ case 2:
959
+ if (ch === _Char___init__impl__6a9atx(92)) {
960
+ state = 3;
961
+ } else if (ch === _Char___init__impl__6a9atx(34)) {
962
+ break loop;
963
+ } else {
964
+ parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
965
+ }
966
+
967
+ break;
968
+ case 3:
969
+ parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
970
+ state = 2;
971
+ break;
972
+ }
973
+ }
974
+ while (inductionVariable < last);
975
+ if (position._v === 4) {
976
+ throw IOException.x1v('Empty multipart boundary is not allowed');
977
+ }
978
+ return copyOfRange(boundaryBytes, 0, position._v);
979
+ }
980
+ function parseMultipart_0(_this__u8e3s4, boundaryPrefixed, input, totalLength, maxPartSize) {
981
+ _init_properties_Multipart_kt__ato98a();
982
+ return produce(_this__u8e3s4, VOID, VOID, parseMultipart$slambda(input, boundaryPrefixed, maxPartSize, totalLength));
983
+ }
984
+ function findBoundary(contentType) {
985
+ _init_properties_Multipart_kt__ato98a();
986
+ var state = 0;
987
+ var paramNameCount = 0;
988
+ var inductionVariable = 0;
989
+ var last = charSequenceLength(contentType) - 1 | 0;
990
+ if (inductionVariable <= last)
991
+ do {
992
+ var i = inductionVariable;
993
+ inductionVariable = inductionVariable + 1 | 0;
994
+ var ch = charSequenceGet(contentType, i);
995
+ switch (state) {
996
+ case 0:
997
+ if (ch === _Char___init__impl__6a9atx(59)) {
998
+ state = 1;
999
+ paramNameCount = 0;
1000
+ }
1001
+
1002
+ break;
1003
+ case 1:
1004
+ if (ch === _Char___init__impl__6a9atx(61)) {
1005
+ state = 2;
1006
+ } else if (ch === _Char___init__impl__6a9atx(59)) {
1007
+ paramNameCount = 0;
1008
+ } else if (ch === _Char___init__impl__6a9atx(44)) {
1009
+ state = 0;
1010
+ } else if (ch !== _Char___init__impl__6a9atx(32))
1011
+ if (paramNameCount === 0 && startsWith(contentType, 'boundary=', i, true)) {
1012
+ return i;
1013
+ } else {
1014
+ paramNameCount = paramNameCount + 1 | 0;
1015
+ }
1016
+
1017
+ break;
1018
+ case 2:
1019
+ if (ch === _Char___init__impl__6a9atx(34))
1020
+ state = 3;
1021
+ else if (ch === _Char___init__impl__6a9atx(44))
1022
+ state = 0;
1023
+ else if (ch === _Char___init__impl__6a9atx(59)) {
1024
+ state = 1;
1025
+ paramNameCount = 0;
1026
+ }
1027
+
1028
+ break;
1029
+ case 3:
1030
+ if (ch === _Char___init__impl__6a9atx(34)) {
1031
+ state = 1;
1032
+ paramNameCount = 0;
1033
+ } else if (ch === _Char___init__impl__6a9atx(92)) {
1034
+ state = 4;
1035
+ }
1036
+
1037
+ break;
1038
+ case 4:
1039
+ state = 3;
1040
+ break;
1041
+ }
1042
+ }
1043
+ while (inductionVariable <= last);
1044
+ return -1;
1045
+ }
1046
+ function *parsePreambleImpl(boundary, input, output, limit, $completion) {
1047
+ limit = limit === VOID ? 9223372036854775807n : limit;
1048
+ return yield* readUntil(input, boundary, output, limit, true, $completion);
1049
+ }
1050
+ function *parsePartHeadersImpl(input, $completion) {
1051
+ var builder = new CharArrayBuilder();
1052
+ try {
1053
+ var tmp0_elvis_lhs = yield* parseHeaders(input, builder, VOID, $completion);
1054
+ var tmp;
1055
+ if (tmp0_elvis_lhs == null) {
1056
+ throw EOFException.l1s('Failed to parse multipart headers: unexpected end of stream');
1057
+ } else {
1058
+ tmp = tmp0_elvis_lhs;
1059
+ }
1060
+ return tmp;
1061
+ } catch ($p) {
1062
+ if ($p instanceof Error) {
1063
+ var t = $p;
1064
+ builder.i1g();
1065
+ throw t;
1066
+ } else {
1067
+ throw $p;
1068
+ }
1069
+ }
1070
+ }
1071
+ function *parsePartBodyImpl(boundaryPrefixed, input, output, headers, limit, $completion) {
1072
+ var tmp0_safe_receiver = headers.p1i('Content-Length');
1073
+ var contentLength = tmp0_safe_receiver == null ? null : parseDecLong(tmp0_safe_receiver);
1074
+ var tmp;
1075
+ if (contentLength == null) {
1076
+ tmp = yield* readUntil(input, boundaryPrefixed, output, limit, true, $completion);
1077
+ } else {
1078
+ if (0n <= contentLength ? contentLength <= limit : false) {
1079
+ tmp = add(yield* copyTo(input, output, contentLength, $completion), yield* skipIfFoundReadCount(input, boundaryPrefixed, $completion));
1080
+ } else {
1081
+ throwLimitExceeded(contentLength, limit);
1082
+ }
1083
+ }
1084
+ var byteCount = tmp;
1085
+ yield* output.u3y($completion);
1086
+ return byteCount;
1087
+ }
1088
+ function *skipIfFoundReadCount(_this__u8e3s4, prefix, $completion) {
1089
+ var tmp;
1090
+ if (yield* skipIfFound(_this__u8e3s4, prefix, $completion)) {
1091
+ tmp = fromInt(prefix.p2());
1092
+ } else {
1093
+ tmp = 0n;
1094
+ }
1095
+ return tmp;
1096
+ }
1097
+ function throwLimitExceeded(actual, limit) {
1098
+ _init_properties_Multipart_kt__ato98a();
1099
+ throw IOException.x1v('Multipart content length exceeds limit ' + actual.toString() + ' > ' + limit.toString() + '; ' + "limit is defined using 'formFieldLimit' argument");
1100
+ }
1101
+ function parseBoundaryInternal$put(position, boundaryBytes, value) {
1102
+ if (position._v >= boundaryBytes.length) {
1103
+ throw IOException.x1v("Failed to parse multipart: boundary shouldn't be longer than 70 characters");
1104
+ }
1105
+ var _unary__edvuaz = position._v;
1106
+ position._v = _unary__edvuaz + 1 | 0;
1107
+ boundaryBytes[_unary__edvuaz] = value;
1108
+ }
1109
+ function parseMultipart$slambda$slambda($firstBoundary, $countedInput) {
1110
+ return constructCallableReference(function *($this$writer, $completion) {
1111
+ yield* /*#__NOINLINE__*/parsePreambleImpl($firstBoundary, $countedInput, $this$writer.t3z_1, 8193n, $completion);
1112
+ yield* $this$writer.t3z_1.w3y($completion);
1113
+ return Unit_instance;
1114
+ }, 1);
1115
+ }
1116
+ function parseMultipart$slambda($input, $boundaryPrefixed, $maxPartSize, $totalLength) {
1117
+ return constructCallableReference(function *($this$produce, $completion) {
1118
+ var countedInput = counted($input);
1119
+ var readBeforeParse = countedInput.b40();
1120
+ var firstBoundary = $boundaryPrefixed.b1s(get_PrefixString().p2());
1121
+ var preambleData = yield* readRemaining(writer($this$produce, VOID, VOID, parseMultipart$slambda$slambda(firstBoundary, countedInput)).j3z_1, $completion);
1122
+ var tmp;
1123
+ if (get_remaining(preambleData) > 0n) {
1124
+ tmp = yield* $this$produce.p36(new Preamble(preambleData), $completion);
1125
+ }
1126
+ $l$loop: while (!countedInput.m3y() && !(yield* skipIfFound(countedInput, get_PrefixString(), $completion))) {
1127
+ yield* skipIfFound(countedInput, get_CrLf(), $completion);
1128
+ if (yield* skipIfFound(countedInput, firstBoundary, $completion)) {
1129
+ continue $l$loop;
1130
+ }
1131
+ var body = new ByteChannel();
1132
+ var headers = CompletableDeferred();
1133
+ var part = new MultipartPart(headers, body);
1134
+ yield* $this$produce.p36(part, $completion);
1135
+ var headersMap = null;
1136
+ try {
1137
+ headersMap = yield* /*#__NOINLINE__*/parsePartHeadersImpl(countedInput, $completion);
1138
+ if (!headers.c2y(headersMap)) {
1139
+ headersMap.i1g();
1140
+ throw CancellationException.n('Multipart processing has been cancelled');
1141
+ }
1142
+ yield* /*#__NOINLINE__*/parsePartBodyImpl($boundaryPrefixed, countedInput, body, headersMap, $maxPartSize, $completion);
1143
+ body.q6();
1144
+ } catch ($p) {
1145
+ if ($p instanceof Error) {
1146
+ var cause = $p;
1147
+ if (headers.d2y(cause)) {
1148
+ var tmp0_safe_receiver = headersMap;
1149
+ if (tmp0_safe_receiver == null)
1150
+ null;
1151
+ else {
1152
+ tmp0_safe_receiver.i1g();
1153
+ }
1154
+ }
1155
+ close(body, cause);
1156
+ throw cause;
1157
+ } else {
1158
+ throw $p;
1159
+ }
1160
+ }
1161
+ }
1162
+ yield* skipIfFound(countedInput, get_CrLf(), $completion);
1163
+ yield* skipIfFound(countedInput, get_CrLf(), $completion);
1164
+ var tmp_0;
1165
+ if (!($totalLength == null)) {
1166
+ var consumedExceptEpilogue = subtract(countedInput.b40(), readBeforeParse);
1167
+ var size = subtract($totalLength, consumedExceptEpilogue);
1168
+ if (size > 2147483647n)
1169
+ throw IOException.x1v('Failed to parse multipart: prologue is too long');
1170
+ var tmp_1;
1171
+ if (size > 0n) {
1172
+ tmp_1 = yield* $this$produce.p36(new Epilogue(yield* readPacket(countedInput, convertToInt(size), $completion)), $completion);
1173
+ }
1174
+ tmp_0 = tmp_1;
1175
+ } else {
1176
+ var epilogueContent = yield* readRemaining(countedInput, $completion);
1177
+ var tmp_2;
1178
+ if (!epilogueContent.n1s()) {
1179
+ tmp_2 = yield* $this$produce.p36(new Epilogue(epilogueContent), $completion);
1180
+ }
1181
+ tmp_0 = tmp_2;
1182
+ }
1183
+ return Unit_instance;
1184
+ }, 1);
1185
+ }
1186
+ var properties_initialized_Multipart_kt_wu0sh0;
1187
+ function _init_properties_Multipart_kt__ato98a() {
1188
+ if (!properties_initialized_Multipart_kt_wu0sh0) {
1189
+ properties_initialized_Multipart_kt_wu0sh0 = true;
1190
+ CrLf = ByteString.a1s(toByteArray_0('\r\n'));
1191
+ PrefixString = ByteString_0(new Int8Array([45, 45]));
1192
+ }
1193
+ }
1194
+ function build($this, resultList, from, maxLength, idx, length, charAt) {
1195
+ // Inline function 'kotlin.collections.groupBy' call
1196
+ // Inline function 'kotlin.collections.groupByTo' call
1197
+ var destination = LinkedHashMap.o5();
1198
+ var _iterator__ex2g4s = from.l1();
1199
+ while (_iterator__ex2g4s.m1()) {
1200
+ var element = _iterator__ex2g4s.n1();
1201
+ var key = charAt(element, idx);
1202
+ // Inline function 'kotlin.collections.getOrPut' call
1203
+ var value = destination.o4(key);
1204
+ var tmp;
1205
+ if (value == null) {
1206
+ var answer = ArrayList.f2();
1207
+ destination.g4(key, answer);
1208
+ tmp = answer;
1209
+ } else {
1210
+ tmp = value;
1211
+ }
1212
+ var list = tmp;
1213
+ list.e2(element);
1214
+ }
1215
+ // Inline function 'kotlin.collections.forEach' call
1216
+ // Inline function 'kotlin.collections.iterator' call
1217
+ var _iterator__ex2g4s_0 = destination.z2().l1();
1218
+ while (_iterator__ex2g4s_0.m1()) {
1219
+ var element_0 = _iterator__ex2g4s_0.n1();
1220
+ // Inline function 'kotlin.collections.component1' call
1221
+ var ch = element_0.a3().s3_1;
1222
+ // Inline function 'kotlin.collections.component2' call
1223
+ var list_0 = element_0.b3();
1224
+ var nextIdx = idx + 1 | 0;
1225
+ var children = ArrayList.f2();
1226
+ var tmp_0 = Companion_instance;
1227
+ // Inline function 'kotlin.collections.filter' call
1228
+ // Inline function 'kotlin.collections.filterTo' call
1229
+ var destination_0 = ArrayList.f2();
1230
+ var _iterator__ex2g4s_1 = list_0.l1();
1231
+ while (_iterator__ex2g4s_1.m1()) {
1232
+ var element_1 = _iterator__ex2g4s_1.n1();
1233
+ if (length(element_1) > nextIdx) {
1234
+ destination_0.e2(element_1);
1235
+ }
1236
+ }
1237
+ build(tmp_0, children, destination_0, maxLength, nextIdx, length, charAt);
1238
+ children.l8();
1239
+ // Inline function 'kotlin.collections.filter' call
1240
+ // Inline function 'kotlin.collections.filterTo' call
1241
+ var destination_1 = ArrayList.f2();
1242
+ var _iterator__ex2g4s_2 = list_0.l1();
1243
+ while (_iterator__ex2g4s_2.m1()) {
1244
+ var element_2 = _iterator__ex2g4s_2.n1();
1245
+ if (length(element_2) === nextIdx) {
1246
+ destination_1.e2(element_2);
1247
+ }
1248
+ }
1249
+ resultList.e2(new Node(ch, destination_1, children));
1250
+ }
1251
+ }
1252
+ function AsciiCharTree$Companion$build$lambda(it) {
1253
+ return charSequenceLength(it);
1254
+ }
1255
+ function AsciiCharTree$Companion$build$lambda_0(s, idx) {
1256
+ return new Char(charSequenceGet(s, idx));
1257
+ }
1258
+ var Companion_instance;
1259
+ function Companion_getInstance_1() {
1260
+ return Companion_instance;
1261
+ }
1262
+ function getImpl($this, index) {
1263
+ return bufferForIndex($this, index)[index % ensureNotNull($this.g4n_1).length | 0];
1264
+ }
1265
+ function copy($this, startIndex, endIndex) {
1266
+ if (startIndex === endIndex)
1267
+ return '';
1268
+ var builder = StringBuilder.ec(endIndex - startIndex | 0);
1269
+ var buffer;
1270
+ var base = startIndex - (startIndex % 2048 | 0) | 0;
1271
+ while (base < endIndex) {
1272
+ buffer = bufferForIndex($this, base);
1273
+ // Inline function 'kotlin.comparisons.maxOf' call
1274
+ var b = startIndex - base | 0;
1275
+ var innerStartIndex = Math.max(0, b);
1276
+ // Inline function 'kotlin.comparisons.minOf' call
1277
+ var a = endIndex - base | 0;
1278
+ var innerEndIndex = Math.min(a, 2048);
1279
+ var inductionVariable = innerStartIndex;
1280
+ if (inductionVariable < innerEndIndex)
1281
+ do {
1282
+ var innerIndex = inductionVariable;
1283
+ inductionVariable = inductionVariable + 1 | 0;
1284
+ builder.k1(buffer[innerIndex]);
1285
+ }
1286
+ while (inductionVariable < innerEndIndex);
1287
+ base = base + 2048 | 0;
1288
+ }
1289
+ return builder;
1290
+ }
1291
+ function bufferForIndex($this, index) {
1292
+ var list = $this.f4n_1;
1293
+ if (list == null) {
1294
+ if (index >= 2048) {
1295
+ throwSingleBuffer($this, index);
1296
+ }
1297
+ var tmp0_elvis_lhs = $this.g4n_1;
1298
+ var tmp;
1299
+ if (tmp0_elvis_lhs == null) {
1300
+ throwSingleBuffer($this, index);
1301
+ } else {
1302
+ tmp = tmp0_elvis_lhs;
1303
+ }
1304
+ return tmp;
1305
+ }
1306
+ return list.q2(index / ensureNotNull($this.g4n_1).length | 0);
1307
+ }
1308
+ function throwSingleBuffer($this, index) {
1309
+ if ($this.i4n_1)
1310
+ throw IllegalStateException.o('Buffer is already released');
1311
+ throw IndexOutOfBoundsException.ie('' + index + ' is not in range [0; ' + currentPosition($this) + ')');
1312
+ }
1313
+ function nonFullBuffer($this) {
1314
+ return $this.j4n_1 === 0 ? appendNewArray($this) : ensureNotNull($this.g4n_1);
1315
+ }
1316
+ function appendNewArray($this) {
1317
+ var newBuffer = $this.e4n_1.d41();
1318
+ var existing = $this.g4n_1;
1319
+ $this.g4n_1 = newBuffer;
1320
+ $this.j4n_1 = newBuffer.length;
1321
+ $this.i4n_1 = false;
1322
+ if (!(existing == null)) {
1323
+ var tmp0_elvis_lhs = $this.f4n_1;
1324
+ var tmp;
1325
+ if (tmp0_elvis_lhs == null) {
1326
+ // Inline function 'kotlin.also' call
1327
+ var this_0 = ArrayList.f2();
1328
+ $this.f4n_1 = this_0;
1329
+ this_0.e2(existing);
1330
+ tmp = this_0;
1331
+ } else {
1332
+ tmp = tmp0_elvis_lhs;
1333
+ }
1334
+ var list = tmp;
1335
+ list.e2(newBuffer);
1336
+ }
1337
+ return newBuffer;
1338
+ }
1339
+ function rangeEqualsImpl($this, start, other, otherStart, length) {
1340
+ var inductionVariable = 0;
1341
+ if (inductionVariable < length)
1342
+ do {
1343
+ var i = inductionVariable;
1344
+ inductionVariable = inductionVariable + 1 | 0;
1345
+ if (!(getImpl($this, start + i | 0) === charSequenceGet(other, otherStart + i | 0)))
1346
+ return false;
1347
+ }
1348
+ while (inductionVariable < length);
1349
+ return true;
1350
+ }
1351
+ function hashCodeImpl($this, start, end) {
1352
+ var hc = 0;
1353
+ var inductionVariable = start;
1354
+ if (inductionVariable < end)
1355
+ do {
1356
+ var i = inductionVariable;
1357
+ inductionVariable = inductionVariable + 1 | 0;
1358
+ var tmp = imul(31, hc);
1359
+ // Inline function 'kotlin.code' call
1360
+ var this_0 = getImpl($this, i);
1361
+ hc = tmp + Char__toInt_impl_vasixd(this_0) | 0;
1362
+ }
1363
+ while (inductionVariable < end);
1364
+ return hc;
1365
+ }
1366
+ function currentPosition($this) {
1367
+ return ensureNotNull($this.g4n_1).length - $this.j4n_1 | 0;
1368
+ }
1369
+ function get_CharArrayPool() {
1370
+ _init_properties_CharArrayPool_kt__u4nq0d();
1371
+ return CharArrayPool;
1372
+ }
1373
+ var CharArrayPool;
1374
+ var properties_initialized_CharArrayPool_kt_aq0u0f;
1375
+ function _init_properties_CharArrayPool_kt__u4nq0d() {
1376
+ if (!properties_initialized_CharArrayPool_kt_aq0u0f) {
1377
+ properties_initialized_CharArrayPool_kt_aq0u0f = true;
1378
+ var tmp;
1379
+ if (isPoolingDisabled()) {
1380
+ tmp = new CharArrayPool$1();
1381
+ } else {
1382
+ tmp = new CharArrayPool$2();
1383
+ }
1384
+ CharArrayPool = tmp;
1385
+ }
1386
+ }
1387
+ var DefaultHttpMethods;
1388
+ var HexTable;
1389
+ var HexLetterTable;
1390
+ function hashCodeLowerCase(_this__u8e3s4, start, end) {
1391
+ start = start === VOID ? 0 : start;
1392
+ end = end === VOID ? charSequenceLength(_this__u8e3s4) : end;
1393
+ _init_properties_Chars_kt__d3i39x();
1394
+ var hashCode = 0;
1395
+ var inductionVariable = start;
1396
+ if (inductionVariable < end)
1397
+ do {
1398
+ var pos = inductionVariable;
1399
+ inductionVariable = inductionVariable + 1 | 0;
1400
+ // Inline function 'kotlin.code' call
1401
+ var this_0 = charSequenceGet(_this__u8e3s4, pos);
1402
+ // Inline function 'io.ktor.http.cio.internals.toLowerCase' call
1403
+ var this_1 = Char__toInt_impl_vasixd(this_0);
1404
+ var tmp;
1405
+ // Inline function 'kotlin.code' call
1406
+ var this_2 = _Char___init__impl__6a9atx(65);
1407
+ var containsLower = Char__toInt_impl_vasixd(this_2);
1408
+ var tmp_0;
1409
+ // Inline function 'kotlin.code' call
1410
+ var this_3 = _Char___init__impl__6a9atx(90);
1411
+ if (this_1 <= Char__toInt_impl_vasixd(this_3)) {
1412
+ tmp_0 = containsLower <= this_1;
1413
+ } else {
1414
+ tmp_0 = false;
1415
+ }
1416
+ if (tmp_0) {
1417
+ // Inline function 'kotlin.code' call
1418
+ var this_4 = _Char___init__impl__6a9atx(97);
1419
+ var tmp_1 = Char__toInt_impl_vasixd(this_4);
1420
+ // Inline function 'kotlin.code' call
1421
+ var this_5 = _Char___init__impl__6a9atx(65);
1422
+ tmp = tmp_1 + (this_1 - Char__toInt_impl_vasixd(this_5) | 0) | 0;
1423
+ } else {
1424
+ tmp = this_1;
1425
+ }
1426
+ var v = tmp;
1427
+ hashCode = imul(31, hashCode) + v | 0;
1428
+ }
1429
+ while (inductionVariable < end);
1430
+ return hashCode;
1431
+ }
1432
+ function equalsLowerCase(_this__u8e3s4, start, end, other) {
1433
+ start = start === VOID ? 0 : start;
1434
+ end = end === VOID ? charSequenceLength(_this__u8e3s4) : end;
1435
+ _init_properties_Chars_kt__d3i39x();
1436
+ if (!((end - start | 0) === charSequenceLength(other)))
1437
+ return false;
1438
+ var inductionVariable = start;
1439
+ if (inductionVariable < end)
1440
+ do {
1441
+ var pos = inductionVariable;
1442
+ inductionVariable = inductionVariable + 1 | 0;
1443
+ // Inline function 'kotlin.code' call
1444
+ var this_0 = charSequenceGet(_this__u8e3s4, pos);
1445
+ // Inline function 'io.ktor.http.cio.internals.toLowerCase' call
1446
+ var this_1 = Char__toInt_impl_vasixd(this_0);
1447
+ var tmp;
1448
+ // Inline function 'kotlin.code' call
1449
+ var this_2 = _Char___init__impl__6a9atx(65);
1450
+ var containsLower = Char__toInt_impl_vasixd(this_2);
1451
+ var tmp_0;
1452
+ // Inline function 'kotlin.code' call
1453
+ var this_3 = _Char___init__impl__6a9atx(90);
1454
+ if (this_1 <= Char__toInt_impl_vasixd(this_3)) {
1455
+ tmp_0 = containsLower <= this_1;
1456
+ } else {
1457
+ tmp_0 = false;
1458
+ }
1459
+ if (tmp_0) {
1460
+ // Inline function 'kotlin.code' call
1461
+ var this_4 = _Char___init__impl__6a9atx(97);
1462
+ var tmp_1 = Char__toInt_impl_vasixd(this_4);
1463
+ // Inline function 'kotlin.code' call
1464
+ var this_5 = _Char___init__impl__6a9atx(65);
1465
+ tmp = tmp_1 + (this_1 - Char__toInt_impl_vasixd(this_5) | 0) | 0;
1466
+ } else {
1467
+ tmp = this_1;
1468
+ }
1469
+ var tmp_2 = tmp;
1470
+ // Inline function 'kotlin.code' call
1471
+ var this_6 = charSequenceGet(other, pos - start | 0);
1472
+ // Inline function 'io.ktor.http.cio.internals.toLowerCase' call
1473
+ var this_7 = Char__toInt_impl_vasixd(this_6);
1474
+ var tmp_3;
1475
+ // Inline function 'kotlin.code' call
1476
+ var this_8 = _Char___init__impl__6a9atx(65);
1477
+ var containsLower_0 = Char__toInt_impl_vasixd(this_8);
1478
+ var tmp_4;
1479
+ // Inline function 'kotlin.code' call
1480
+ var this_9 = _Char___init__impl__6a9atx(90);
1481
+ if (this_7 <= Char__toInt_impl_vasixd(this_9)) {
1482
+ tmp_4 = containsLower_0 <= this_7;
1483
+ } else {
1484
+ tmp_4 = false;
1485
+ }
1486
+ if (tmp_4) {
1487
+ // Inline function 'kotlin.code' call
1488
+ var this_10 = _Char___init__impl__6a9atx(97);
1489
+ var tmp_5 = Char__toInt_impl_vasixd(this_10);
1490
+ // Inline function 'kotlin.code' call
1491
+ var this_11 = _Char___init__impl__6a9atx(65);
1492
+ tmp_3 = tmp_5 + (this_7 - Char__toInt_impl_vasixd(this_11) | 0) | 0;
1493
+ } else {
1494
+ tmp_3 = this_7;
1495
+ }
1496
+ if (!(tmp_2 === tmp_3))
1497
+ return false;
1498
+ }
1499
+ while (inductionVariable < end);
1500
+ return true;
1501
+ }
1502
+ function parseDecLong(_this__u8e3s4) {
1503
+ _init_properties_Chars_kt__d3i39x();
1504
+ var length = charSequenceLength(_this__u8e3s4);
1505
+ if (length > 19) {
1506
+ numberFormatException(_this__u8e3s4);
1507
+ }
1508
+ if (length === 19)
1509
+ return parseDecLongWithCheck(_this__u8e3s4);
1510
+ var result = 0n;
1511
+ var inductionVariable = 0;
1512
+ if (inductionVariable < length)
1513
+ do {
1514
+ var i = inductionVariable;
1515
+ inductionVariable = inductionVariable + 1 | 0;
1516
+ // Inline function 'kotlin.code' call
1517
+ var this_0 = charSequenceGet(_this__u8e3s4, i);
1518
+ var tmp$ret$0 = Char__toInt_impl_vasixd(this_0);
1519
+ var digit = subtract(fromInt(tmp$ret$0), 48n);
1520
+ if (digit < 0n || digit > 9n) {
1521
+ numberFormatException_0(_this__u8e3s4, i);
1522
+ }
1523
+ result = add(add(shiftLeft(result, 3), shiftLeft(result, 1)), digit);
1524
+ }
1525
+ while (inductionVariable < length);
1526
+ return result;
1527
+ }
1528
+ function numberFormatException(cs) {
1529
+ _init_properties_Chars_kt__d3i39x();
1530
+ throw NumberFormatException.xe('Invalid number ' + toString(cs) + ': too large for Long type');
1531
+ }
1532
+ function parseDecLongWithCheck(_this__u8e3s4) {
1533
+ _init_properties_Chars_kt__d3i39x();
1534
+ var result = 0n;
1535
+ var inductionVariable = 0;
1536
+ var last = charSequenceLength(_this__u8e3s4) - 1 | 0;
1537
+ if (inductionVariable <= last)
1538
+ do {
1539
+ var i = inductionVariable;
1540
+ inductionVariable = inductionVariable + 1 | 0;
1541
+ // Inline function 'kotlin.code' call
1542
+ var this_0 = charSequenceGet(_this__u8e3s4, i);
1543
+ var tmp$ret$0 = Char__toInt_impl_vasixd(this_0);
1544
+ var digit = subtract(fromInt(tmp$ret$0), 48n);
1545
+ if (digit < 0n || digit > 9n) {
1546
+ numberFormatException_0(_this__u8e3s4, i);
1547
+ }
1548
+ result = add(add(shiftLeft(result, 3), shiftLeft(result, 1)), digit);
1549
+ if (result < 0n) {
1550
+ numberFormatException(_this__u8e3s4);
1551
+ }
1552
+ }
1553
+ while (inductionVariable <= last);
1554
+ return result;
1555
+ }
1556
+ function numberFormatException_0(cs, idx) {
1557
+ _init_properties_Chars_kt__d3i39x();
1558
+ throw NumberFormatException.xe('Invalid number: ' + toString(cs) + ', wrong digit: ' + toString_1(charSequenceGet(cs, idx)) + ' at position ' + idx);
1559
+ }
1560
+ function DefaultHttpMethods$lambda(it) {
1561
+ _init_properties_Chars_kt__d3i39x();
1562
+ return it.r4g_1.length;
1563
+ }
1564
+ function DefaultHttpMethods$lambda_0(m, idx) {
1565
+ _init_properties_Chars_kt__d3i39x();
1566
+ return new Char(charCodeAt(m.r4g_1, idx));
1567
+ }
1568
+ var properties_initialized_Chars_kt_phjfhp;
1569
+ function _init_properties_Chars_kt__d3i39x() {
1570
+ if (!properties_initialized_Chars_kt_phjfhp) {
1571
+ properties_initialized_Chars_kt_phjfhp = true;
1572
+ var tmp = Companion_instance;
1573
+ var tmp_0 = Companion_getInstance().q4g_1;
1574
+ var tmp_1 = DefaultHttpMethods$lambda;
1575
+ DefaultHttpMethods = tmp.p4o(tmp_0, tmp_1, DefaultHttpMethods$lambda_0);
1576
+ // Inline function 'kotlin.collections.map' call
1577
+ var this_0 = numberRangeToNumber(0, 255);
1578
+ // Inline function 'kotlin.collections.mapTo' call
1579
+ var destination = ArrayList.d2(collectionSizeOrDefault(this_0, 10));
1580
+ var inductionVariable = this_0.e3_1;
1581
+ var last = this_0.f3_1;
1582
+ if (inductionVariable <= last)
1583
+ do {
1584
+ var item = inductionVariable;
1585
+ inductionVariable = inductionVariable + 1 | 0;
1586
+ var v = item;
1587
+ var tmp_2;
1588
+ if (48 <= v ? v <= 57 : false) {
1589
+ tmp_2 = subtract(numberToLong(v), 48n);
1590
+ } else {
1591
+ var tmp_3;
1592
+ var tmp_4 = fromInt(v);
1593
+ // Inline function 'kotlin.code' call
1594
+ var this_1 = _Char___init__impl__6a9atx(97);
1595
+ var tmp$ret$3 = Char__toInt_impl_vasixd(this_1);
1596
+ if (tmp_4 >= fromInt(tmp$ret$3)) {
1597
+ var tmp_5 = fromInt(v);
1598
+ // Inline function 'kotlin.code' call
1599
+ var this_2 = _Char___init__impl__6a9atx(102);
1600
+ var tmp$ret$4 = Char__toInt_impl_vasixd(this_2);
1601
+ tmp_3 = tmp_5 <= fromInt(tmp$ret$4);
1602
+ } else {
1603
+ tmp_3 = false;
1604
+ }
1605
+ if (tmp_3) {
1606
+ // Inline function 'kotlin.code' call
1607
+ var this_3 = _Char___init__impl__6a9atx(97);
1608
+ var tmp$ret$5 = Char__toInt_impl_vasixd(this_3);
1609
+ // Inline function 'kotlin.Long.plus' call
1610
+ var this_4 = subtract(numberToLong(v), fromInt(tmp$ret$5));
1611
+ tmp_2 = add(this_4, fromInt(10));
1612
+ } else {
1613
+ var tmp_6;
1614
+ var tmp_7 = fromInt(v);
1615
+ // Inline function 'kotlin.code' call
1616
+ var this_5 = _Char___init__impl__6a9atx(65);
1617
+ var tmp$ret$7 = Char__toInt_impl_vasixd(this_5);
1618
+ if (tmp_7 >= fromInt(tmp$ret$7)) {
1619
+ var tmp_8 = fromInt(v);
1620
+ // Inline function 'kotlin.code' call
1621
+ var this_6 = _Char___init__impl__6a9atx(70);
1622
+ var tmp$ret$8 = Char__toInt_impl_vasixd(this_6);
1623
+ tmp_6 = tmp_8 <= fromInt(tmp$ret$8);
1624
+ } else {
1625
+ tmp_6 = false;
1626
+ }
1627
+ if (tmp_6) {
1628
+ // Inline function 'kotlin.code' call
1629
+ var this_7 = _Char___init__impl__6a9atx(65);
1630
+ var tmp$ret$9 = Char__toInt_impl_vasixd(this_7);
1631
+ // Inline function 'kotlin.Long.plus' call
1632
+ var this_8 = subtract(numberToLong(v), fromInt(tmp$ret$9));
1633
+ tmp_2 = add(this_8, fromInt(10));
1634
+ } else {
1635
+ tmp_2 = -1n;
1636
+ }
1637
+ }
1638
+ }
1639
+ var tmp$ret$2 = tmp_2;
1640
+ destination.e2(tmp$ret$2);
1641
+ }
1642
+ while (!(item === last));
1643
+ HexTable = toLongArray(destination);
1644
+ // Inline function 'kotlin.collections.map' call
1645
+ var this_9 = numberRangeToNumber(0, 15);
1646
+ // Inline function 'kotlin.collections.mapTo' call
1647
+ var destination_0 = ArrayList.d2(collectionSizeOrDefault(this_9, 10));
1648
+ var inductionVariable_0 = this_9.e3_1;
1649
+ var last_0 = this_9.f3_1;
1650
+ if (inductionVariable_0 <= last_0)
1651
+ do {
1652
+ var item_0 = inductionVariable_0;
1653
+ inductionVariable_0 = inductionVariable_0 + 1 | 0;
1654
+ var it = item_0;
1655
+ var tmp_9;
1656
+ if (it < 10) {
1657
+ tmp_9 = toByte(48 + it | 0);
1658
+ } else {
1659
+ // Inline function 'kotlin.code' call
1660
+ var this_10 = Char__minus_impl_a2frrh(Char__plus_impl_qi7pgj(_Char___init__impl__6a9atx(97), it), 10);
1661
+ var tmp$ret$3_0 = Char__toInt_impl_vasixd(this_10);
1662
+ tmp_9 = toByte(tmp$ret$3_0);
1663
+ }
1664
+ var tmp$ret$2_0 = tmp_9;
1665
+ destination_0.e2(tmp$ret$2_0);
1666
+ }
1667
+ while (!(item_0 === last_0));
1668
+ HexLetterTable = toByteArray(destination_0);
1669
+ }
1670
+ }
1671
+ function skipSpacesAndHorizontalTabs(text, start, end) {
1672
+ var index = start;
1673
+ $l$loop: while (index < end) {
1674
+ var ch = text.b(index);
1675
+ if (!isWhitespace(ch) && !(ch === _Char___init__impl__6a9atx(9)))
1676
+ break $l$loop;
1677
+ index = index + 1 | 0;
1678
+ }
1679
+ return index;
1680
+ }
1681
+ function isPoolingDisabled() {
1682
+ return false;
1683
+ }
1684
+ //region block: post-declaration
1685
+ initMetadataForClass(CIOMultipartDataBase, 'CIOMultipartDataBase', VOID, VOID, [MultiPartData], [0, 1]);
1686
+ initMetadataForClass(HttpHeadersMap, 'HttpHeadersMap');
1687
+ initMetadataForClass(HeadersData, 'HeadersData', HeadersData);
1688
+ initMetadataForClass(IntArrayPool$1);
1689
+ initMetadataForClass(HeadersDataPool$1);
1690
+ initMetadataForClass(ParserException, 'ParserException');
1691
+ initMetadataForClass(MultipartEvent, 'MultipartEvent', VOID, VOID, VOID, [0]);
1692
+ initMetadataForClass(Preamble, 'Preamble', VOID, VOID, VOID, [0]);
1693
+ initMetadataForClass(MultipartPart, 'MultipartPart', VOID, VOID, VOID, [0]);
1694
+ initMetadataForClass(Epilogue, 'Epilogue', VOID, VOID, VOID, [0]);
1695
+ initMetadataForClass(Node, 'Node');
1696
+ initMetadataForCompanion(Companion);
1697
+ initMetadataForClass(AsciiCharTree, 'AsciiCharTree');
1698
+ initMetadataForClass(SubSequenceImpl, 'SubSequenceImpl', VOID, VOID, [CharSequence]);
1699
+ initMetadataForClass(CharArrayBuilder, 'CharArrayBuilder', CharArrayBuilder, VOID, [CharSequence]);
1700
+ initMetadataForClass(CharArrayPool$1);
1701
+ initMetadataForClass(CharArrayPool$2);
1702
+ initMetadataForClass(UnsupportedMediaTypeExceptionCIO, 'UnsupportedMediaTypeExceptionCIO');
1703
+ initMetadataForClass(MutableRange, 'MutableRange');
1704
+ //endregion
1705
+ //region block: init
1706
+ Companion_instance = new Companion();
1707
+ //endregion
1708
+ //region block: exports
1709
+ export {
1710
+ CIOMultipartDataBase as CIOMultipartDataBase3o5u8w437tq5s,
1711
+ };
1712
+ //endregion
1713
+
1714
+ //# sourceMappingURL=ktor-ktor-http-cio.mjs.map