(function (root, factory) {
if (typeof define === 'function' && define.amd)
define(['exports', './kotlin-kotlin-stdlib-js-ir.js', './ktor-ktor-io-js-ir.js', './kotlinx.coroutines-kotlinx-coroutines-core-js-ir.js', './88b0986a7186d029-atomicfu-js-ir.js'], factory);
else if (typeof exports === 'object')
factory(module.exports, require('./kotlin-kotlin-stdlib-js-ir.js'), require('./ktor-ktor-io-js-ir.js'), require('./kotlinx.coroutines-kotlinx-coroutines-core-js-ir.js'), require('./88b0986a7186d029-atomicfu-js-ir.js'));
else {
if (typeof this['kotlin-kotlin-stdlib-js-ir'] === 'undefined') {
throw new Error("Error loading module 'ktor-ktor-utils-js-ir'. Its dependency 'kotlin-kotlin-stdlib-js-ir' was not found. Please, check whether 'kotlin-kotlin-stdlib-js-ir' is loaded prior to 'ktor-ktor-utils-js-ir'.");
}
if (typeof this['ktor-ktor-io-js-ir'] === 'undefined') {
throw new Error("Error loading module 'ktor-ktor-utils-js-ir'. Its dependency 'ktor-ktor-io-js-ir' was not found. Please, check whether 'ktor-ktor-io-js-ir' is loaded prior to 'ktor-ktor-utils-js-ir'.");
}
if (typeof this['kotlinx.coroutines-kotlinx-coroutines-core-js-ir'] === 'undefined') {
throw new Error("Error loading module 'ktor-ktor-utils-js-ir'. Its dependency 'kotlinx.coroutines-kotlinx-coroutines-core-js-ir' was not found. Please, check whether 'kotlinx.coroutines-kotlinx-coroutines-core-js-ir' is loaded prior to 'ktor-ktor-utils-js-ir'.");
}
if (typeof this['88b0986a7186d029-atomicfu-js-ir'] === 'undefined') {
throw new Error("Error loading module 'ktor-ktor-utils-js-ir'. Its dependency '88b0986a7186d029-atomicfu-js-ir' was not found. Please, check whether '88b0986a7186d029-atomicfu-js-ir' is loaded prior to 'ktor-ktor-utils-js-ir'.");
}
root['ktor-ktor-utils-js-ir'] = factory(typeof this['ktor-ktor-utils-js-ir'] === 'undefined' ? {} : this['ktor-ktor-utils-js-ir'], this['kotlin-kotlin-stdlib-js-ir'], this['ktor-ktor-io-js-ir'], this['kotlinx.coroutines-kotlinx-coroutines-core-js-ir'], this['88b0986a7186d029-atomicfu-js-ir']);
}
}(this, function (_, kotlin_kotlin, kotlin_io_ktor_ktor_io, kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core, kotlin_org_jetbrains_kotlinx_atomicfu) {
'use strict';
//region block: imports
var imul = Math.imul;
var charSequenceLength = kotlin_kotlin.$_$.nc;
var Unit_getInstance = kotlin_kotlin.$_$.k5;
var IllegalStateException_init_$Create$ = kotlin_kotlin.$_$.x2;
var getKClassFromExpression = kotlin_kotlin.$_$.c;
var THROW_CCE = kotlin_kotlin.$_$.di;
var getStringHashCode = kotlin_kotlin.$_$.wc;
var classMeta = kotlin_kotlin.$_$.pc;
var interfaceMeta = kotlin_kotlin.$_$.yc;
var charArray = kotlin_kotlin.$_$.lc;
var charSequenceGet = kotlin_kotlin.$_$.mc;
var concatToString = kotlin_kotlin.$_$.mf;
var _Char___init__impl__6a9atx = kotlin_kotlin.$_$.p3;
var numberToChar = kotlin_kotlin.$_$.sd;
var indexOf$default = kotlin_kotlin.$_$.w;
var CoroutineImpl = kotlin_kotlin.$_$.yb;
var Long = kotlin_kotlin.$_$.xh;
var get_COROUTINE_SUSPENDED = kotlin_kotlin.$_$.gb;
var readBytes$default = kotlin_io_ktor_ktor_io.$_$.g;
var LinkedHashMap_init_$Create$ = kotlin_kotlin.$_$.v1;
var isObject = kotlin_kotlin.$_$.ld;
var equals = kotlin_kotlin.$_$.rc;
var hashCode = kotlin_kotlin.$_$.xc;
var MutableMap = kotlin_kotlin.$_$.e6;
var ensureNotNull = kotlin_kotlin.$_$.ri;
var Entry = kotlin_kotlin.$_$.y5;
var isInterface = kotlin_kotlin.$_$.id;
var MutableEntry = kotlin_kotlin.$_$.d6;
var toString = kotlin_kotlin.$_$.y3;
var Char = kotlin_kotlin.$_$.nh;
var SupervisorJob = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.y1;
var AbstractCoroutineContextElement = kotlin_kotlin.$_$.kb;
var Key_getInstance = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.w;
var get = kotlin_kotlin.$_$.sb;
var fold = kotlin_kotlin.$_$.rb;
var minusKey = kotlin_kotlin.$_$.tb;
var plus = kotlin_kotlin.$_$.wb;
var CoroutineExceptionHandler = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.m1;
var BytePacketBuilder_init_$Create$ = kotlin_io_ktor_ktor_io.$_$.m;
var writeText$default = kotlin_io_ktor_ktor_io.$_$.j;
var readBytes = kotlin_io_ktor_ktor_io.$_$.d1;
var concatToString_0 = kotlin_kotlin.$_$.lf;
var MutableIterator = kotlin_kotlin.$_$.b6;
var collectionSizeOrDefault = kotlin_kotlin.$_$.p6;
var ArrayList_init_$Create$ = kotlin_kotlin.$_$.l1;
var Set = kotlin_kotlin.$_$.h6;
var toString_0 = kotlin_kotlin.$_$.ae;
var MutableSet = kotlin_kotlin.$_$.f6;
var firstOrNull = kotlin_kotlin.$_$.e8;
var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.m1;
var LinkedHashMap_init_$Create$_0 = kotlin_kotlin.$_$.u1;
var to = kotlin_kotlin.$_$.ij;
var addAll = kotlin_kotlin.$_$.j6;
var StringBuilder_init_$Create$ = kotlin_kotlin.$_$.g2;
var get_lastIndex = kotlin_kotlin.$_$.ag;
var Char__plus_impl_qi7pgj = kotlin_kotlin.$_$.u3;
var equals_0 = kotlin_kotlin.$_$.qf;
var IOException = kotlin_io_ktor_ktor_io.$_$.g1;
var emptyMap = kotlin_kotlin.$_$.x7;
var atomic$ref$1 = kotlin_org_jetbrains_kotlinx_atomicfu.$_$.c;
var objectMeta = kotlin_kotlin.$_$.wd;
var Comparable = kotlin_kotlin.$_$.oh;
var Enum = kotlin_kotlin.$_$.sh;
var isSuspendFunction = kotlin_kotlin.$_$.nd;
var MutableList = kotlin_kotlin.$_$.c6;
var ArrayList = kotlin_kotlin.$_$.n5;
var emptyList = kotlin_kotlin.$_$.w7;
var get_lastIndex_0 = kotlin_kotlin.$_$.w8;
var last = kotlin_kotlin.$_$.a9;
var mutableListOf = kotlin_kotlin.$_$.j9;
var CoroutineScope = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.p1;
var extendThrowable = kotlin_kotlin.$_$.sc;
var captureStack = kotlin_kotlin.$_$.jc;
var recoverStackTrace = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.f1;
var Companion_getInstance = kotlin_kotlin.$_$.f5;
var _Result___init__impl__xyqfz8 = kotlin_kotlin.$_$.z3;
var createFailure = kotlin_kotlin.$_$.qi;
var Result__exceptionOrNull_impl_p6xea9 = kotlin_kotlin.$_$.a4;
var _Result___get_isFailure__impl__jpiriv = kotlin_kotlin.$_$.b4;
var IntCompanionObject_getInstance = kotlin_kotlin.$_$.w4;
var Continuation = kotlin_kotlin.$_$.qb;
var fillArrayVal = kotlin_kotlin.$_$.tc;
var toList = kotlin_kotlin.$_$.na;
var KProperty0 = kotlin_kotlin.$_$.df;
var getPropertyCallableRef = kotlin_kotlin.$_$.vc;
var lazy = kotlin_kotlin.$_$.yi;
var isNaN_0 = kotlin_kotlin.$_$.wi;
var numberToLong = kotlin_kotlin.$_$.vd;
var IllegalStateException = kotlin_kotlin.$_$.wh;
var IllegalStateException_init_$Init$ = kotlin_kotlin.$_$.w2;
//endregion
//region block: pre-declaration
function get_0(key) {
var tmp0_elvis_lhs = this.o2v(key);
var tmp;
if (tmp0_elvis_lhs == null) {
throw IllegalStateException_init_$Create$('No instance for key ' + key);
} else {
tmp = tmp0_elvis_lhs;
}
return tmp;
}
$toByteArrayCOROUTINE$0.prototype = Object.create(CoroutineImpl.prototype);
$toByteArrayCOROUTINE$0.prototype.constructor = $toByteArrayCOROUTINE$0;
_no_name_provided__qut3iv.prototype = Object.create(AbstractCoroutineContextElement.prototype);
_no_name_provided__qut3iv.prototype.constructor = _no_name_provided__qut3iv;
function get_1(name) {
var tmp0_safe_receiver = this.b2x(name);
return tmp0_safe_receiver == null ? null : firstOrNull(tmp0_safe_receiver);
}
function forEach(body) {
var tmp0_forEach = this.d2x();
var tmp0_iterator = tmp0_forEach.j();
while (tmp0_iterator.k()) {
var element = tmp0_iterator.l();
// Inline function 'io.ktor.util.StringValues.forEach.<anonymous>' call
var tmp$ret$0;
// Inline function 'kotlin.collections.component1' call
tmp$ret$0 = element.k1();
var k = tmp$ret$0;
var tmp$ret$1;
// Inline function 'kotlin.collections.component2' call
tmp$ret$1 = element.l1();
var v = tmp$ret$1;
body(k, v);
}
return Unit_getInstance();
}
ChannelIOException.prototype = Object.create(IOException.prototype);
ChannelIOException.prototype.constructor = ChannelIOException;
WeekDay.prototype = Object.create(Enum.prototype);
WeekDay.prototype.constructor = WeekDay;
Month.prototype = Object.create(Enum.prototype);
Month.prototype.constructor = Month;
$proceedLoopCOROUTINE$1.prototype = Object.create(CoroutineImpl.prototype);
$proceedLoopCOROUTINE$1.prototype.constructor = $proceedLoopCOROUTINE$1;
DebugPipelineContext.prototype = Object.create(PipelineContext.prototype);
DebugPipelineContext.prototype.constructor = DebugPipelineContext;
InvalidPhaseException.prototype = Object.create(Error.prototype);
InvalidPhaseException.prototype.constructor = InvalidPhaseException;
After.prototype = Object.create(PipelinePhaseRelation.prototype);
After.prototype.constructor = After;
Before.prototype = Object.create(PipelinePhaseRelation.prototype);
Before.prototype.constructor = Before;
Last.prototype = Object.create(PipelinePhaseRelation.prototype);
Last.prototype.constructor = Last;
SuspendFunctionGun.prototype = Object.create(PipelineContext.prototype);
SuspendFunctionGun.prototype.constructor = SuspendFunctionGun;
InvalidTimestampException.prototype = Object.create(IllegalStateException.prototype);
InvalidTimestampException.prototype.constructor = InvalidTimestampException;
//endregion
function AttributeKey(name) {
this.m2v_1 = name;
var tmp$ret$0;
// Inline function 'kotlin.text.isEmpty' call
var tmp0_isEmpty = this.m2v_1;
tmp$ret$0 = charSequenceLength(tmp0_isEmpty) === 0;
if (tmp$ret$0) {
throw IllegalStateException_init_$Create$("Name can't be blank");
}
}
AttributeKey.prototype.toString = function () {
return 'AttributeKey: ' + this.m2v_1;
};
AttributeKey.prototype.equals = function (other) {
if (this === other)
return true;
if (other == null ? true : !getKClassFromExpression(this).equals(getKClassFromExpression(other)))
return false;
if (other instanceof AttributeKey)
other;
else
THROW_CCE();
if (!(this.m2v_1 === other.m2v_1))
return false;
return true;
};
AttributeKey.prototype.hashCode = function () {
return getStringHashCode(this.m2v_1);
};
AttributeKey.$metadata$ = classMeta('AttributeKey');
function Attributes() {
}
Attributes.$metadata$ = interfaceMeta('Attributes');
function putAll(_this__u8e3s4, other) {
// Inline function 'kotlin.collections.forEach' call
var tmp0_forEach = other.t2v();
var tmp0_iterator = tmp0_forEach.j();
while (tmp0_iterator.k()) {
var element = tmp0_iterator.l();
// Inline function 'io.ktor.util.putAll.<anonymous>' call
_this__u8e3s4.q2v(element instanceof AttributeKey ? element : THROW_CCE(), other.n2v(element));
}
}
var BASE64_INVERSE_ALPHABET;
function encodeBase64(_this__u8e3s4) {
init_properties_Base64_kt_tnw0ut();
var array = _this__u8e3s4;
var position = 0;
var writeOffset = 0;
var charArray_0 = charArray((imul(_this__u8e3s4.length, 8) / 6 | 0) + 3 | 0);
while ((position + 3 | 0) <= array.length) {
var first = array[position];
var second = array[position + 1 | 0];
var third = array[position + 2 | 0];
position = position + 3 | 0;
var chunk = (first & 255) << 16 | (second & 255) << 8 | third & 255;
var inductionVariable = 3;
if (0 <= inductionVariable)
do {
var index = inductionVariable;
inductionVariable = inductionVariable + -1 | 0;
var char = chunk >> imul(6, index) & 63;
var tmp1 = writeOffset;
writeOffset = tmp1 + 1 | 0;
var tmp$ret$0;
// Inline function 'io.ktor.util.toBase64' call
tmp$ret$0 = charSequenceGet(_get_BASE64_ALPHABET_$accessor$1rlrljx_834nh0(), char);
charArray_0[tmp1] = tmp$ret$0;
}
while (0 <= inductionVariable);
}
var remaining = array.length - position | 0;
if (remaining === 0)
return concatToString(charArray_0, 0, writeOffset);
var tmp;
if (remaining === 1) {
tmp = (array[position] & 255) << 16 | 0 | 0;
} else {
tmp = (array[position] & 255) << 16 | (array[position + 1 | 0] & 255) << 8 | 0;
}
var chunk_0 = tmp;
var padSize = imul(3 - remaining | 0, 8) / 6 | 0;
var inductionVariable_0 = 3;
if (padSize <= inductionVariable_0)
do {
var index_0 = inductionVariable_0;
inductionVariable_0 = inductionVariable_0 + -1 | 0;
var char_0 = chunk_0 >> imul(6, index_0) & 63;
var tmp3 = writeOffset;
writeOffset = tmp3 + 1 | 0;
var tmp$ret$1;
// Inline function 'io.ktor.util.toBase64' call
tmp$ret$1 = charSequenceGet(_get_BASE64_ALPHABET_$accessor$1rlrljx_834nh0(), char_0);
charArray_0[tmp3] = tmp$ret$1;
}
while (!(index_0 === padSize));
// Inline function 'kotlin.repeat' call
// Inline function 'kotlin.contracts.contract' call
var inductionVariable_1 = 0;
if (inductionVariable_1 < padSize)
do {
var index_1 = inductionVariable_1;
inductionVariable_1 = inductionVariable_1 + 1 | 0;
// Inline function 'io.ktor.util.encodeBase64.<anonymous>' call
var tmp0 = writeOffset;
writeOffset = tmp0 + 1 | 0;
charArray_0[tmp0] = _Char___init__impl__6a9atx(61);
}
while (inductionVariable_1 < padSize);
return concatToString(charArray_0, 0, writeOffset);
}
function toBase64(_this__u8e3s4) {
init_properties_Base64_kt_tnw0ut();
return charSequenceGet(_get_BASE64_ALPHABET_$accessor$1rlrljx_834nh0(), _this__u8e3s4);
}
function get_BASE64_PAD() {
return BASE64_PAD;
}
var BASE64_PAD;
function _get_BASE64_ALPHABET_$accessor$1rlrljx_834nh0() {
init_properties_Base64_kt_tnw0ut();
return 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';
}
var properties_initialized_Base64_kt_5g824v;
function init_properties_Base64_kt_tnw0ut() {
if (properties_initialized_Base64_kt_5g824v) {
} else {
properties_initialized_Base64_kt_5g824v = true;
var tmp = 0;
var tmp_0 = 256;
var tmp_1 = new Int32Array(tmp_0);
while (tmp < tmp_0) {
var tmp_2 = tmp;
var tmp$ret$0;
// Inline function 'io.ktor.util.BASE64_INVERSE_ALPHABET.<anonymous>' call
var tmp_3 = _get_BASE64_ALPHABET_$accessor$1rlrljx_834nh0();
var tmp_4 = numberToChar(tmp_2);
tmp$ret$0 = indexOf$default(tmp_3, tmp_4, 0, false, 6, null);
tmp_1[tmp_2] = tmp$ret$0;
tmp = tmp + 1 | 0;
}
BASE64_INVERSE_ALPHABET = tmp_1;
}
}
function toByteArray(_this__u8e3s4, $cont) {
var tmp = new $toByteArrayCOROUTINE$0(_this__u8e3s4, $cont);
tmp.q7_1 = Unit_getInstance();
tmp.r7_1 = null;
return tmp.v7();
}
function $toByteArrayCOROUTINE$0(_this__u8e3s4, resultContinuation) {
CoroutineImpl.call(this, resultContinuation);
this.c2w_1 = _this__u8e3s4;
}
$toByteArrayCOROUTINE$0.prototype.v7 = function () {
var suspendResult = this.q7_1;
$sm: do
try {
var tmp = this.o7_1;
switch (tmp) {
case 0:
this.p7_1 = 2;
this.o7_1 = 1;
suspendResult = this.c2w_1.h2m(new Long(0, 0), this, 1, null);
if (suspendResult === get_COROUTINE_SUSPENDED()) {
return suspendResult;
}
continue $sm;
case 1:
var ARGUMENT = suspendResult;
return readBytes$default(ARGUMENT, 0, 1, null);
case 2:
throw this.r7_1;
}
} catch ($p) {
if (this.p7_1 === 2) {
throw $p;
} else {
this.o7_1 = this.p7_1;
this.r7_1 = $p;
}
}
while (true);
};
$toByteArrayCOROUTINE$0.$metadata$ = classMeta('$toByteArrayCOROUTINE$0', undefined, undefined, undefined, undefined, CoroutineImpl.prototype);
function CaseInsensitiveMap$_get_keys_$lambda_ptzlqj($this$$receiver) {
return $this$$receiver.d2w_1;
}
function CaseInsensitiveMap$_get_keys_$lambda_ptzlqj_0($this$$receiver) {
return caseInsensitive($this$$receiver);
}
function CaseInsensitiveMap$_get_entries_$lambda_r32w19($this$$receiver) {
return new Entry_0($this$$receiver.k1().d2w_1, $this$$receiver.l1());
}
function CaseInsensitiveMap$_get_entries_$lambda_r32w19_0($this$$receiver) {
return new Entry_0(caseInsensitive($this$$receiver.k1()), $this$$receiver.l1());
}
function CaseInsensitiveMap() {
var tmp = this;
var tmp$ret$0;
// Inline function 'kotlin.collections.mutableMapOf' call
tmp$ret$0 = LinkedHashMap_init_$Create$();
tmp.f2w_1 = tmp$ret$0;
}
CaseInsensitiveMap.prototype.i = function () {
return this.f2w_1.i();
};
CaseInsensitiveMap.prototype.b19 = function (key) {
return this.f2w_1.r3(new CaseInsensitiveString(key));
};
CaseInsensitiveMap.prototype.r3 = function (key) {
if (!(!(key == null) ? typeof key === 'string' : false))
return false;
return this.b19((!(key == null) ? typeof key === 'string' : false) ? key : THROW_CCE());
};
CaseInsensitiveMap.prototype.c19 = function (key) {
return this.f2w_1.q(caseInsensitive(key));
};
CaseInsensitiveMap.prototype.q = function (key) {
if (!(!(key == null) ? typeof key === 'string' : false))
return null;
return this.c19((!(key == null) ? typeof key === 'string' : false) ? key : THROW_CCE());
};
CaseInsensitiveMap.prototype.p = function () {
return this.f2w_1.p();
};
CaseInsensitiveMap.prototype.x7 = function () {
this.f2w_1.x7();
};
CaseInsensitiveMap.prototype.g2w = function (key, value) {
return this.f2w_1.a(caseInsensitive(key), value);
};
CaseInsensitiveMap.prototype.a = function (key, value) {
var tmp = (!(key == null) ? typeof key === 'string' : false) ? key : THROW_CCE();
return this.g2w(tmp, isObject(value) ? value : THROW_CCE());
};
CaseInsensitiveMap.prototype.h2w = function (from) {
// Inline function 'kotlin.collections.forEach' call
var tmp$ret$0;
// Inline function 'kotlin.collections.iterator' call
tmp$ret$0 = from.j1().j();
var tmp0_iterator = tmp$ret$0;
while (tmp0_iterator.k()) {
var element = tmp0_iterator.l();
// Inline function 'io.ktor.util.CaseInsensitiveMap.putAll.<anonymous>' call
var tmp$ret$1;
// Inline function 'kotlin.collections.component1' call
tmp$ret$1 = element.k1();
var key = tmp$ret$1;
var tmp$ret$2;
// Inline function 'kotlin.collections.component2' call
tmp$ret$2 = element.l1();
var value = tmp$ret$2;
this.g2w(key, value);
}
};
CaseInsensitiveMap.prototype.u4 = function (from) {
return this.h2w(from);
};
CaseInsensitiveMap.prototype.i2w = function (key) {
return this.f2w_1.y4(caseInsensitive(key));
};
CaseInsensitiveMap.prototype.y4 = function (key) {
if (!(!(key == null) ? typeof key === 'string' : false))
return null;
return this.i2w((!(key == null) ? typeof key === 'string' : false) ? key : THROW_CCE());
};
CaseInsensitiveMap.prototype.v3 = function () {
var tmp = this.f2w_1.v3();
var tmp_0 = CaseInsensitiveMap$_get_keys_$lambda_ptzlqj;
return new DelegatingMutableSet(tmp, tmp_0, CaseInsensitiveMap$_get_keys_$lambda_ptzlqj_0);
};
CaseInsensitiveMap.prototype.j1 = function () {
var tmp = this.f2w_1.j1();
var tmp_0 = CaseInsensitiveMap$_get_entries_$lambda_r32w19;
return new DelegatingMutableSet(tmp, tmp_0, CaseInsensitiveMap$_get_entries_$lambda_r32w19_0);
};
CaseInsensitiveMap.prototype.lh = function () {
return this.f2w_1.lh();
};
CaseInsensitiveMap.prototype.equals = function (other) {
var tmp;
if (other == null) {
tmp = true;
} else {
tmp = !(other instanceof CaseInsensitiveMap);
}
if (tmp)
return false;
return equals(other.f2w_1, this.f2w_1);
};
CaseInsensitiveMap.prototype.hashCode = function () {
return hashCode(this.f2w_1);
};
CaseInsensitiveMap.$metadata$ = classMeta('CaseInsensitiveMap', [MutableMap]);
function Entry_0(key, value) {
this.j2w_1 = key;
this.k2w_1 = value;
}
Entry_0.prototype.k1 = function () {
return this.j2w_1;
};
Entry_0.prototype.l1 = function () {
return this.k2w_1;
};
Entry_0.prototype.l2w = function (newValue) {
this.k2w_1 = newValue;
return this.k2w_1;
};
Entry_0.prototype.zg = function (newValue) {
return this.l2w((newValue == null ? true : isObject(newValue)) ? newValue : THROW_CCE());
};
Entry_0.prototype.hashCode = function () {
return (527 + hashCode(ensureNotNull(this.j2w_1)) | 0) + hashCode(ensureNotNull(this.k2w_1)) | 0;
};
Entry_0.prototype.equals = function (other) {
var tmp;
if (other == null) {
tmp = true;
} else {
tmp = !(!(other == null) ? isInterface(other, Entry) : false);
}
if (tmp)
return false;
return equals(other.k1(), this.j2w_1) ? equals(other.l1(), this.k2w_1) : false;
};
Entry_0.prototype.toString = function () {
return '' + this.j2w_1 + '=' + this.k2w_1;
};
Entry_0.$metadata$ = classMeta('Entry', [MutableEntry]);
function toCharArray(_this__u8e3s4) {
var tmp = 0;
var tmp_0 = _this__u8e3s4.length;
var tmp_1 = charArray(tmp_0);
while (tmp < tmp_0) {
var tmp_2 = tmp;
var tmp$ret$0;
// Inline function 'io.ktor.util.toCharArray.<anonymous>' call
tmp$ret$0 = charSequenceGet(_this__u8e3s4, tmp_2);
tmp_1[tmp_2] = tmp$ret$0;
tmp = tmp + 1 | 0;
}
return tmp_1;
}
function isLowerCase(_this__u8e3s4) {
var tmp$ret$3;
// Inline function 'kotlin.text.lowercaseChar' call
var tmp$ret$2;
// Inline function 'kotlin.text.lowercase' call
var tmp$ret$1;
// Inline function 'kotlin.js.unsafeCast' call
var tmp$ret$0;
// Inline function 'kotlin.js.asDynamic' call
var tmp0_asDynamic = toString(_this__u8e3s4);
tmp$ret$0 = tmp0_asDynamic;
var tmp1_unsafeCast = tmp$ret$0.toLowerCase();
tmp$ret$1 = tmp1_unsafeCast;
tmp$ret$2 = tmp$ret$1;
tmp$ret$3 = charSequenceGet(tmp$ret$2, 0);
return equals(new Char(tmp$ret$3), new Char(_this__u8e3s4));
}
function caseInsensitiveMap() {
return new CaseInsensitiveMap();
}
function SilentSupervisor(parent) {
var tmp = SupervisorJob(parent);
var tmp$ret$0;
// Inline function 'kotlinx.coroutines.CoroutineExceptionHandler' call
tmp$ret$0 = new _no_name_provided__qut3iv();
return tmp.p8(tmp$ret$0);
}
function SilentSupervisor$default(parent, $mask0, $handler) {
if (!(($mask0 & 1) === 0))
parent = null;
return SilentSupervisor(parent);
}
function _no_name_provided__qut3iv() {
AbstractCoroutineContextElement.call(this, Key_getInstance());
}
_no_name_provided__qut3iv.prototype.r20 = function (context, exception) {
var tmp$ret$0;
// Inline function 'io.ktor.util.SilentSupervisor.<anonymous>' call
tmp$ret$0 = Unit_getInstance();
return tmp$ret$0;
};
_no_name_provided__qut3iv.$metadata$ = classMeta(undefined, [CoroutineExceptionHandler], undefined, undefined, undefined, AbstractCoroutineContextElement.prototype);
function get_digits() {
init_properties_Crypto_kt_rgu395();
return digits;
}
var digits;
function generateNonce(size) {
init_properties_Crypto_kt_rgu395();
var tmp$ret$0;
$l$block: {
// Inline function 'io.ktor.utils.io.core.buildPacket' call
// Inline function 'kotlin.contracts.contract' call
var builder = BytePacketBuilder_init_$Create$(null, 1, null);
try {
// Inline function 'io.ktor.util.generateNonce.<anonymous>' call
while (builder.i() < size) {
var tmp = generateNonce_0();
writeText$default(builder, tmp, 0, 0, null, 14, null);
}
tmp$ret$0 = builder.c4();
break $l$block;
} catch ($p) {
if ($p instanceof Error) {
builder.s17();
throw $p;
} else {
throw $p;
}
}
}
return readBytes(tmp$ret$0, size);
}
function get_NONCE_SIZE_IN_BYTES() {
return NONCE_SIZE_IN_BYTES;
}
var NONCE_SIZE_IN_BYTES;
function hex(bytes) {
init_properties_Crypto_kt_rgu395();
var result = charArray(imul(bytes.length, 2));
var resultIndex = 0;
var digits = get_digits();
var inductionVariable = 0;
var last = bytes.length;
if (inductionVariable < last)
do {
var index = inductionVariable;
inductionVariable = inductionVariable + 1 | 0;
var b = bytes[index] & 255;
var tmp1 = resultIndex;
resultIndex = tmp1 + 1 | 0;
result[tmp1] = digits[b >> 4];
var tmp2 = resultIndex;
resultIndex = tmp2 + 1 | 0;
result[tmp2] = digits[b & 15];
}
while (inductionVariable < last);
return concatToString_0(result);
}
var properties_initialized_Crypto_kt_8g5vqb;
function init_properties_Crypto_kt_rgu395() {
if (properties_initialized_Crypto_kt_8g5vqb) {
} else {
properties_initialized_Crypto_kt_8g5vqb = true;
digits = toCharArray('0123456789abcdef');
}
}
function DelegatingMutableSet$iterator$1(this$0) {
this.o2w_1 = this$0;
this.n2w_1 = this$0.p2w_1.j();
}
DelegatingMutableSet$iterator$1.prototype.k = function () {
return this.n2w_1.k();
};
DelegatingMutableSet$iterator$1.prototype.l = function () {
return this.o2w_1.q2w_1(this.n2w_1.l());
};
DelegatingMutableSet$iterator$1.prototype.b5 = function () {
return this.n2w_1.b5();
};
DelegatingMutableSet$iterator$1.$metadata$ = classMeta(undefined, [MutableIterator]);
function DelegatingMutableSet(delegate, convertTo, convert) {
this.p2w_1 = delegate;
this.q2w_1 = convertTo;
this.r2w_1 = convert;
this.s2w_1 = this.p2w_1.i();
}
DelegatingMutableSet.prototype.t2w = function (_this__u8e3s4) {
var tmp$ret$2;
// Inline function 'kotlin.collections.map' call
var tmp$ret$1;
// Inline function 'kotlin.collections.mapTo' call
var tmp0_mapTo = ArrayList_init_$Create$(collectionSizeOrDefault(_this__u8e3s4, 10));
var tmp0_iterator = _this__u8e3s4.j();
while (tmp0_iterator.k()) {
var item = tmp0_iterator.l();
var tmp$ret$0;
// Inline function 'io.ktor.util.DelegatingMutableSet.convert.<anonymous>' call
tmp$ret$0 = this.r2w_1(item);
tmp0_mapTo.c(tmp$ret$0);
}
tmp$ret$1 = tmp0_mapTo;
tmp$ret$2 = tmp$ret$1;
return tmp$ret$2;
};
DelegatingMutableSet.prototype.u2w = function (_this__u8e3s4) {
var tmp$ret$2;
// Inline function 'kotlin.collections.map' call
var tmp$ret$1;
// Inline function 'kotlin.collections.mapTo' call
var tmp0_mapTo = ArrayList_init_$Create$(collectionSizeOrDefault(_this__u8e3s4, 10));
var tmp0_iterator = _this__u8e3s4.j();
while (tmp0_iterator.k()) {
var item = tmp0_iterator.l();
var tmp$ret$0;
// Inline function 'io.ktor.util.DelegatingMutableSet.convertTo.<anonymous>' call
tmp$ret$0 = this.q2w_1(item);
tmp0_mapTo.c(tmp$ret$0);
}
tmp$ret$1 = tmp0_mapTo;
tmp$ret$2 = tmp$ret$1;
return tmp$ret$2;
};
DelegatingMutableSet.prototype.i = function () {
return this.s2w_1;
};
DelegatingMutableSet.prototype.v2w = function (element) {
return this.p2w_1.c(this.r2w_1(element));
};
DelegatingMutableSet.prototype.c = function (element) {
return this.v2w((element == null ? true : isObject(element)) ? element : THROW_CCE());
};
DelegatingMutableSet.prototype.w2w = function (elements) {
return this.p2w_1.o(this.t2w(elements));
};
DelegatingMutableSet.prototype.o = function (elements) {
return this.w2w(elements);
};
DelegatingMutableSet.prototype.x7 = function () {
this.p2w_1.x7();
};
DelegatingMutableSet.prototype.x2w = function (element) {
return this.p2w_1.c5(this.r2w_1(element));
};
DelegatingMutableSet.prototype.c5 = function (element) {
if (!(element == null ? true : isObject(element)))
return false;
return this.x2w((element == null ? true : isObject(element)) ? element : THROW_CCE());
};
DelegatingMutableSet.prototype.y2w = function (element) {
return this.p2w_1.r(this.r2w_1(element));
};
DelegatingMutableSet.prototype.r = function (element) {
if (!(element == null ? true : isObject(element)))
return false;
return this.y2w((element == null ? true : isObject(element)) ? element : THROW_CCE());
};
DelegatingMutableSet.prototype.z2w = function (elements) {
return this.p2w_1.l2(this.t2w(elements));
};
DelegatingMutableSet.prototype.l2 = function (elements) {
return this.z2w(elements);
};
DelegatingMutableSet.prototype.p = function () {
return this.p2w_1.p();
};
DelegatingMutableSet.prototype.j = function () {
return new DelegatingMutableSet$iterator$1(this);
};
DelegatingMutableSet.prototype.hashCode = function () {
return hashCode(this.p2w_1);
};
DelegatingMutableSet.prototype.equals = function (other) {
var tmp;
if (other == null) {
tmp = true;
} else {
tmp = !(!(other == null) ? isInterface(other, Set) : false);
}
if (tmp)
return false;
var elements = this.u2w(this.p2w_1);
var tmp_0;
if (other.l2(elements)) {
var tmp$ret$0;
// Inline function 'kotlin.collections.containsAll' call
var tmp0_containsAll = other;
tmp$ret$0 = elements.l2(tmp0_containsAll);
tmp_0 = tmp$ret$0;
} else {
tmp_0 = false;
}
return tmp_0;
};
DelegatingMutableSet.prototype.toString = function () {
return toString_0(this.u2w(this.p2w_1));
};
DelegatingMutableSet.$metadata$ = classMeta('DelegatingMutableSet', [MutableSet]);
function StringValues() {
}
StringValues.$metadata$ = interfaceMeta('StringValues');
function ensureListForKey($this, name) {
var tmp0_elvis_lhs = $this.g2x_1.q(name);
var tmp;
if (tmp0_elvis_lhs == null) {
var tmp$ret$1;
// Inline function 'kotlin.also' call
var tmp$ret$0;
// Inline function 'kotlin.collections.mutableListOf' call
tmp$ret$0 = ArrayList_init_$Create$_0();
var tmp0_also = tmp$ret$0;
// Inline function 'kotlin.contracts.contract' call
// Inline function 'io.ktor.util.StringValuesBuilderImpl.ensureListForKey.<anonymous>' call
$this.h2x(name);
// Inline function 'kotlin.collections.set' call
var tmp0_set = $this.g2x_1;
tmp0_set.a(name, tmp0_also);
tmp$ret$1 = tmp0_also;
tmp = tmp$ret$1;
} else {
tmp = tmp0_elvis_lhs;
}
return tmp;
}
function StringValuesBuilderImpl$appendAll$lambda(this$0) {
return function (name, values) {
this$0.i2x(name, values);
return Unit_getInstance();
};
}
function StringValuesBuilderImpl(caseInsensitiveName, size) {
this.f2x_1 = caseInsensitiveName;
this.g2x_1 = this.f2x_1 ? caseInsensitiveMap() : LinkedHashMap_init_$Create$_0(size);
}
StringValuesBuilderImpl.prototype.a2x = function () {
return this.f2x_1;
};
StringValuesBuilderImpl.prototype.lh = function () {
return this.g2x_1;
};
StringValuesBuilderImpl.prototype.b2x = function (name) {
return this.g2x_1.q(name);
};
StringValuesBuilderImpl.prototype.c2x = function () {
return this.g2x_1.v3();
};
StringValuesBuilderImpl.prototype.p = function () {
return this.g2x_1.p();
};
StringValuesBuilderImpl.prototype.d2x = function () {
return unmodifiable(this.g2x_1.j1());
};
StringValuesBuilderImpl.prototype.j2x = function (name, value) {
this.k2x(value);
var list = ensureListForKey(this, name);
list.x7();
list.c(value);
};
StringValuesBuilderImpl.prototype.c19 = function (name) {
var tmp0_safe_receiver = this.b2x(name);
return tmp0_safe_receiver == null ? null : firstOrNull(tmp0_safe_receiver);
};
StringValuesBuilderImpl.prototype.l2x = function (name, value) {
this.k2x(value);
ensureListForKey(this, name).c(value);
};
StringValuesBuilderImpl.prototype.m2x = function (stringValues) {
stringValues.e2x(StringValuesBuilderImpl$appendAll$lambda(this));
};
StringValuesBuilderImpl.prototype.i2x = function (name, values) {
var tmp$ret$0;
// Inline function 'kotlin.let' call
var tmp0_let = ensureListForKey(this, name);
// Inline function 'kotlin.contracts.contract' call
var tmp0_iterator = values.j();
while (tmp0_iterator.k()) {
var element = tmp0_iterator.l();
// Inline function 'io.ktor.util.StringValuesBuilderImpl.appendAll.<anonymous>.<anonymous>' call
this.k2x(element);
tmp0_let.c(element);
}
tmp$ret$0 = Unit_getInstance();
};
StringValuesBuilderImpl.prototype.n2x = function (name) {
this.g2x_1.y4(name);
};
StringValuesBuilderImpl.prototype.x7 = function () {
this.g2x_1.x7();
};
StringValuesBuilderImpl.prototype.h2x = function (name) {
};
StringValuesBuilderImpl.prototype.k2x = function (value) {
};
StringValuesBuilderImpl.$metadata$ = classMeta('StringValuesBuilderImpl', [StringValuesBuilder]);
function listForKey($this, name) {
return $this.p2x_1.q(name);
}
function StringValuesImpl(caseInsensitiveName, values) {
this.o2x_1 = caseInsensitiveName;
var tmp;
if (this.o2x_1) {
tmp = caseInsensitiveMap();
} else {
var tmp$ret$0;
// Inline function 'kotlin.collections.mutableMapOf' call
tmp$ret$0 = LinkedHashMap_init_$Create$();
tmp = tmp$ret$0;
}
var newMap = tmp;
// Inline function 'kotlin.collections.forEach' call
var tmp$ret$1;
// Inline function 'kotlin.collections.iterator' call
tmp$ret$1 = values.j1().j();
var tmp0_iterator = tmp$ret$1;
while (tmp0_iterator.k()) {
var element = tmp0_iterator.l();
// Inline function 'io.ktor.util.StringValuesImpl.<anonymous>' call
var tmp$ret$2;
// Inline function 'kotlin.collections.component1' call
tmp$ret$2 = element.k1();
var key = tmp$ret$2;
var tmp$ret$3;
// Inline function 'kotlin.collections.component2' call
tmp$ret$3 = element.l1();
var value = tmp$ret$3;
// Inline function 'kotlin.collections.set' call
var tmp$ret$6;
// Inline function 'kotlin.collections.List' call
var tmp0_List = value.i();
var tmp$ret$5;
// Inline function 'kotlin.collections.MutableList' call
var list = ArrayList_init_$Create$(tmp0_List);
// Inline function 'kotlin.repeat' call
// Inline function 'kotlin.contracts.contract' call
var inductionVariable = 0;
if (inductionVariable < tmp0_List)
do {
var index = inductionVariable;
inductionVariable = inductionVariable + 1 | 0;
// Inline function 'kotlin.collections.MutableList.<anonymous>' call
var tmp$ret$4;
// Inline function 'io.ktor.util.StringValuesImpl.<anonymous>.<anonymous>' call
tmp$ret$4 = value.m(index);
list.c(tmp$ret$4);
}
while (inductionVariable < tmp0_List);
tmp$ret$5 = list;
tmp$ret$6 = tmp$ret$5;
var tmp1_set = tmp$ret$6;
newMap.a(key, tmp1_set);
}
this.p2x_1 = newMap;
}
StringValuesImpl.prototype.a2x = function () {
return this.o2x_1;
};
StringValuesImpl.prototype.c19 = function (name) {
var tmp0_safe_receiver = listForKey(this, name);
return tmp0_safe_receiver == null ? null : firstOrNull(tmp0_safe_receiver);
};
StringValuesImpl.prototype.b2x = function (name) {
return listForKey(this, name);
};
StringValuesImpl.prototype.c2x = function () {
return unmodifiable(this.p2x_1.v3());
};
StringValuesImpl.prototype.p = function () {
return this.p2x_1.p();
};
StringValuesImpl.prototype.d2x = function () {
return unmodifiable(this.p2x_1.j1());
};
StringValuesImpl.prototype.e2x = function (body) {
var tmp$ret$0;
// Inline function 'kotlin.collections.iterator' call
var tmp0_iterator = this.p2x_1;
tmp$ret$0 = tmp0_iterator.j1().j();
var tmp0_iterator_0 = tmp$ret$0;
while (tmp0_iterator_0.k()) {
var tmp1_loop_parameter = tmp0_iterator_0.l();
var tmp$ret$1;
// Inline function 'kotlin.collections.component1' call
tmp$ret$1 = tmp1_loop_parameter.k1();
var key = tmp$ret$1;
var tmp$ret$2;
// Inline function 'kotlin.collections.component2' call
tmp$ret$2 = tmp1_loop_parameter.l1();
var value = tmp$ret$2;
body(key, value);
}
};
StringValuesImpl.prototype.toString = function () {
return 'StringValues(case=' + !this.o2x_1 + ') ' + this.d2x();
};
StringValuesImpl.prototype.equals = function (other) {
if (this === other)
return true;
if (!(!(other == null) ? isInterface(other, StringValues) : false))
return false;
if (!(this.o2x_1 === other.a2x()))
return false;
return entriesEquals(this.d2x(), other.d2x());
};
StringValuesImpl.prototype.hashCode = function () {
return entriesHashCode(this.d2x(), imul(31, this.o2x_1 | 0));
};
StringValuesImpl.$metadata$ = classMeta('StringValuesImpl', [StringValues]);
function StringValuesBuilder() {
}
StringValuesBuilder.$metadata$ = interfaceMeta('StringValuesBuilder');
function appendAll(_this__u8e3s4, builder) {
var tmp$ret$2;
// Inline function 'kotlin.apply' call
// Inline function 'kotlin.contracts.contract' call
// Inline function 'io.ktor.util.appendAll.<anonymous>' call
// Inline function 'kotlin.collections.forEach' call
var tmp0_forEach = builder.d2x();
var tmp0_iterator = tmp0_forEach.j();
while (tmp0_iterator.k()) {
var element = tmp0_iterator.l();
// Inline function 'io.ktor.util.appendAll.<anonymous>.<anonymous>' call
var tmp$ret$0;
// Inline function 'kotlin.collections.component1' call
tmp$ret$0 = element.k1();
var name = tmp$ret$0;
var tmp$ret$1;
// Inline function 'kotlin.collections.component2' call
tmp$ret$1 = element.l1();
var values = tmp$ret$1;
_this__u8e3s4.i2x(name, values);
}
tmp$ret$2 = _this__u8e3s4;
return tmp$ret$2;
}
function flattenEntries(_this__u8e3s4) {
var tmp$ret$5;
// Inline function 'kotlin.collections.flatMap' call
var tmp0_flatMap = _this__u8e3s4.d2x();
var tmp$ret$4;
// Inline function 'kotlin.collections.flatMapTo' call
var tmp0_flatMapTo = ArrayList_init_$Create$_0();
var tmp0_iterator = tmp0_flatMap.j();
while (tmp0_iterator.k()) {
var element = tmp0_iterator.l();
var tmp$ret$3;
// Inline function 'io.ktor.util.flattenEntries.<anonymous>' call
var tmp$ret$2;
// Inline function 'kotlin.collections.map' call
var tmp0_map = element.l1();
var tmp$ret$1;
// Inline function 'kotlin.collections.mapTo' call
var tmp0_mapTo = ArrayList_init_$Create$(collectionSizeOrDefault(tmp0_map, 10));
var tmp0_iterator_0 = tmp0_map.j();
while (tmp0_iterator_0.k()) {
var item = tmp0_iterator_0.l();
var tmp$ret$0;
// Inline function 'io.ktor.util.flattenEntries.<anonymous>.<anonymous>' call
tmp$ret$0 = to(element.k1(), item);
tmp0_mapTo.c(tmp$ret$0);
}
tmp$ret$1 = tmp0_mapTo;
tmp$ret$2 = tmp$ret$1;
tmp$ret$3 = tmp$ret$2;
var list = tmp$ret$3;
addAll(tmp0_flatMapTo, list);
}
tmp$ret$4 = tmp0_flatMapTo;
tmp$ret$5 = tmp$ret$4;
return tmp$ret$5;
}
function entriesEquals(a, b) {
return equals(a, b);
}
function entriesHashCode(entries, seed) {
return imul(seed, 31) + hashCode(entries) | 0;
}
function toLowerCasePreservingASCIIRules(_this__u8e3s4) {
var tmp$ret$1;
$l$block: {
// Inline function 'kotlin.text.indexOfFirst' call
var inductionVariable = 0;
var last = charSequenceLength(_this__u8e3s4) - 1 | 0;
if (inductionVariable <= last)
do {
var index = inductionVariable;
inductionVariable = inductionVariable + 1 | 0;
var tmp$ret$0;
// Inline function 'io.ktor.util.toLowerCasePreservingASCIIRules.<anonymous>' call
var tmp0__anonymous__q1qw7t = charSequenceGet(_this__u8e3s4, index);
tmp$ret$0 = !equals(new Char(toLowerCasePreservingASCII(tmp0__anonymous__q1qw7t)), new Char(tmp0__anonymous__q1qw7t));
if (tmp$ret$0) {
tmp$ret$1 = index;
break $l$block;
}
}
while (inductionVariable <= last);
tmp$ret$1 = -1;
}
var firstIndex = tmp$ret$1;
if (firstIndex === -1) {
return _this__u8e3s4;
}
var original = _this__u8e3s4;
var tmp$ret$3;
// Inline function 'kotlin.text.buildString' call
var tmp1_buildString = _this__u8e3s4.length;
// Inline function 'kotlin.contracts.contract' call
var tmp$ret$2;
// Inline function 'kotlin.apply' call
var tmp0_apply = StringBuilder_init_$Create$(tmp1_buildString);
// Inline function 'kotlin.contracts.contract' call
// Inline function 'io.ktor.util.toLowerCasePreservingASCIIRules.<anonymous>' call
tmp0_apply.xl(original, 0, firstIndex);
var inductionVariable_0 = firstIndex;
var last_0 = get_lastIndex(original);
if (inductionVariable_0 <= last_0)
do {
var index_0 = inductionVariable_0;
inductionVariable_0 = inductionVariable_0 + 1 | 0;
tmp0_apply.g2(toLowerCasePreservingASCII(charSequenceGet(original, index_0)));
}
while (!(index_0 === last_0));
tmp$ret$2 = tmp0_apply;
tmp$ret$3 = tmp$ret$2.toString();
return tmp$ret$3;
}
function toLowerCasePreservingASCII(ch) {
var tmp0_subject = ch;
var tmp;
if (_Char___init__impl__6a9atx(65) <= tmp0_subject ? tmp0_subject <= _Char___init__impl__6a9atx(90) : false) {
tmp = Char__plus_impl_qi7pgj(ch, 32);
} else if (_Char___init__impl__6a9atx(0) <= tmp0_subject ? tmp0_subject <= _Char___init__impl__6a9atx(127) : false) {
tmp = ch;
} else {
var tmp$ret$3;
// Inline function 'kotlin.text.lowercaseChar' call
var tmp$ret$2;
// Inline function 'kotlin.text.lowercase' call
var tmp$ret$1;
// Inline function 'kotlin.js.unsafeCast' call
var tmp$ret$0;
// Inline function 'kotlin.js.asDynamic' call
var tmp0_asDynamic = toString(ch);
tmp$ret$0 = tmp0_asDynamic;
var tmp1_unsafeCast = tmp$ret$0.toLowerCase();
tmp$ret$1 = tmp1_unsafeCast;
tmp$ret$2 = tmp$ret$1;
tmp$ret$3 = charSequenceGet(tmp$ret$2, 0);
tmp = tmp$ret$3;
}
return tmp;
}
function CaseInsensitiveString(content) {
this.d2w_1 = content;
var tmp = this;
var tmp$ret$1;
// Inline function 'kotlin.text.lowercase' call
var tmp0_lowercase = this.d2w_1;
var tmp$ret$0;
// Inline function 'kotlin.js.asDynamic' call
tmp$ret$0 = tmp0_lowercase;
tmp$ret$1 = tmp$ret$0.toLowerCase();
tmp.e2w_1 = getStringHashCode(tmp$ret$1);
}
CaseInsensitiveString.prototype.equals = function (other) {
var tmp0_safe_receiver = other instanceof CaseInsensitiveString ? other : null;
var tmp1_safe_receiver = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.d2w_1;
return (tmp1_safe_receiver == null ? null : equals_0(tmp1_safe_receiver, this.d2w_1, true)) === true;
};
CaseInsensitiveString.prototype.hashCode = function () {
return this.e2w_1;
};
CaseInsensitiveString.prototype.toString = function () {
return this.d2w_1;
};
CaseInsensitiveString.$metadata$ = classMeta('CaseInsensitiveString');
function caseInsensitive(_this__u8e3s4) {
return new CaseInsensitiveString(_this__u8e3s4);
}
function ChannelIOException() {
}
ChannelIOException.$metadata$ = classMeta('ChannelIOException', undefined, undefined, undefined, undefined, IOException.prototype);
function CopyOnWriteHashMap() {
this.q2x_1 = atomic$ref$1(emptyMap());
}
CopyOnWriteHashMap.prototype.q = function (key) {
return this.q2x_1.k1t_1.q(key);
};
CopyOnWriteHashMap.$metadata$ = classMeta('CopyOnWriteHashMap');
function Companion() {
Companion_instance = this;
this.r2x_1 = GMTDate_0(new Long(0, 0));
}
Companion.$metadata$ = objectMeta('Companion');
var Companion_instance;
function Companion_getInstance_0() {
if (Companion_instance == null)
new Companion();
return Companion_instance;
}
function GMTDate(seconds, minutes, hours, dayOfWeek, dayOfMonth, dayOfYear, month, year, timestamp) {
Companion_getInstance_0();
this.s2x_1 = seconds;
this.t2x_1 = minutes;
this.u2x_1 = hours;
this.v2x_1 = dayOfWeek;
this.w2x_1 = dayOfMonth;
this.x2x_1 = dayOfYear;
this.y2x_1 = month;
this.z2x_1 = year;
this.a2y_1 = timestamp;
}
GMTDate.prototype.b2y = function (other) {
return this.a2y_1.x1(other.a2y_1);
};
GMTDate.prototype.kc = function (other) {
return this.b2y(other instanceof GMTDate ? other : THROW_CCE());
};
GMTDate.prototype.toString = function () {
return 'GMTDate(seconds=' + this.s2x_1 + ', minutes=' + this.t2x_1 + ', hours=' + this.u2x_1 + ', dayOfWeek=' + this.v2x_1 + ', dayOfMonth=' + this.w2x_1 + ', dayOfYear=' + this.x2x_1 + ', month=' + this.y2x_1 + ', year=' + this.z2x_1 + ', timestamp=' + toString_0(this.a2y_1) + ')';
};
GMTDate.prototype.hashCode = function () {
var result = this.s2x_1;
result = imul(result, 31) + this.t2x_1 | 0;
result = imul(result, 31) + this.u2x_1 | 0;
result = imul(result, 31) + this.v2x_1.hashCode() | 0;
result = imul(result, 31) + this.w2x_1 | 0;
result = imul(result, 31) + this.x2x_1 | 0;
result = imul(result, 31) + this.y2x_1.hashCode() | 0;
result = imul(result, 31) + this.z2x_1 | 0;
result = imul(result, 31) + this.a2y_1.hashCode() | 0;
return result;
};
GMTDate.prototype.equals = function (other) {
if (this === other)
return true;
if (!(other instanceof GMTDate))
return false;
var tmp0_other_with_cast = other instanceof GMTDate ? other : THROW_CCE();
if (!(this.s2x_1 === tmp0_other_with_cast.s2x_1))
return false;
if (!(this.t2x_1 === tmp0_other_with_cast.t2x_1))
return false;
if (!(this.u2x_1 === tmp0_other_with_cast.u2x_1))
return false;
if (!this.v2x_1.equals(tmp0_other_with_cast.v2x_1))
return false;
if (!(this.w2x_1 === tmp0_other_with_cast.w2x_1))
return false;
if (!(this.x2x_1 === tmp0_other_with_cast.x2x_1))
return false;
if (!this.y2x_1.equals(tmp0_other_with_cast.y2x_1))
return false;
if (!(this.z2x_1 === tmp0_other_with_cast.z2x_1))
return false;
if (!this.a2y_1.equals(tmp0_other_with_cast.a2y_1))
return false;
return true;
};
GMTDate.$metadata$ = classMeta('GMTDate', [Comparable]);
var WeekDay_MONDAY_instance;
var WeekDay_TUESDAY_instance;
var WeekDay_WEDNESDAY_instance;
var WeekDay_THURSDAY_instance;
var WeekDay_FRIDAY_instance;
var WeekDay_SATURDAY_instance;
var WeekDay_SUNDAY_instance;
function Companion_0() {
Companion_instance_0 = this;
}
Companion_0.prototype.c2y = function (ordinal) {
return values()[ordinal];
};
Companion_0.$metadata$ = objectMeta('Companion');
var Companion_instance_0;
function Companion_getInstance_1() {
WeekDay_initEntries();
if (Companion_instance_0 == null)
new Companion_0();
return Companion_instance_0;
}
function values() {
return [WeekDay_MONDAY_getInstance(), WeekDay_TUESDAY_getInstance(), WeekDay_WEDNESDAY_getInstance(), WeekDay_THURSDAY_getInstance(), WeekDay_FRIDAY_getInstance(), WeekDay_SATURDAY_getInstance(), WeekDay_SUNDAY_getInstance()];
}
var WeekDay_entriesInitialized;
function WeekDay_initEntries() {
if (WeekDay_entriesInitialized)
return Unit_getInstance();
WeekDay_entriesInitialized = true;
WeekDay_MONDAY_instance = new WeekDay('MONDAY', 0, 'Mon');
WeekDay_TUESDAY_instance = new WeekDay('TUESDAY', 1, 'Tue');
WeekDay_WEDNESDAY_instance = new WeekDay('WEDNESDAY', 2, 'Wed');
WeekDay_THURSDAY_instance = new WeekDay('THURSDAY', 3, 'Thu');
WeekDay_FRIDAY_instance = new WeekDay('FRIDAY', 4, 'Fri');
WeekDay_SATURDAY_instance = new WeekDay('SATURDAY', 5, 'Sat');
WeekDay_SUNDAY_instance = new WeekDay('SUNDAY', 6, 'Sun');
Companion_getInstance_1();
}
function WeekDay(name, ordinal, value) {
Enum.call(this, name, ordinal);
this.f2y_1 = value;
}
WeekDay.$metadata$ = classMeta('WeekDay', undefined, undefined, undefined, undefined, Enum.prototype);
var Month_JANUARY_instance;
var Month_FEBRUARY_instance;
var Month_MARCH_instance;
var Month_APRIL_instance;
var Month_MAY_instance;
var Month_JUNE_instance;
var Month_JULY_instance;
var Month_AUGUST_instance;
var Month_SEPTEMBER_instance;
var Month_OCTOBER_instance;
var Month_NOVEMBER_instance;
var Month_DECEMBER_instance;
function Companion_1() {
Companion_instance_1 = this;
}
Companion_1.prototype.c2y = function (ordinal) {
return values_0()[ordinal];
};
Companion_1.$metadata$ = objectMeta('Companion');
var Companion_instance_1;
function Companion_getInstance_2() {
Month_initEntries();
if (Companion_instance_1 == null)
new Companion_1();
return Companion_instance_1;
}
function values_0() {
return [Month_JANUARY_getInstance(), Month_FEBRUARY_getInstance(), Month_MARCH_getInstance(), Month_APRIL_getInstance(), Month_MAY_getInstance(), Month_JUNE_getInstance(), Month_JULY_getInstance(), Month_AUGUST_getInstance(), Month_SEPTEMBER_getInstance(), Month_OCTOBER_getInstance(), Month_NOVEMBER_getInstance(), Month_DECEMBER_getInstance()];
}
var Month_entriesInitialized;
function Month_initEntries() {
if (Month_entriesInitialized)
return Unit_getInstance();
Month_entriesInitialized = true;
Month_JANUARY_instance = new Month('JANUARY', 0, 'Jan');
Month_FEBRUARY_instance = new Month('FEBRUARY', 1, 'Feb');
Month_MARCH_instance = new Month('MARCH', 2, 'Mar');
Month_APRIL_instance = new Month('APRIL', 3, 'Apr');
Month_MAY_instance = new Month('MAY', 4, 'May');
Month_JUNE_instance = new Month('JUNE', 5, 'Jun');
Month_JULY_instance = new Month('JULY', 6, 'Jul');
Month_AUGUST_instance = new Month('AUGUST', 7, 'Aug');
Month_SEPTEMBER_instance = new Month('SEPTEMBER', 8, 'Sep');
Month_OCTOBER_instance = new Month('OCTOBER', 9, 'Oct');
Month_NOVEMBER_instance = new Month('NOVEMBER', 10, 'Nov');
Month_DECEMBER_instance = new Month('DECEMBER', 11, 'Dec');
Companion_getInstance_2();
}
function Month(name, ordinal, value) {
Enum.call(this, name, ordinal);
this.i2y_1 = value;
}
Month.$metadata$ = classMeta('Month', undefined, undefined, undefined, undefined, Enum.prototype);
function WeekDay_MONDAY_getInstance() {
WeekDay_initEntries();
return WeekDay_MONDAY_instance;
}
function WeekDay_TUESDAY_getInstance() {
WeekDay_initEntries();
return WeekDay_TUESDAY_instance;
}
function WeekDay_WEDNESDAY_getInstance() {
WeekDay_initEntries();
return WeekDay_WEDNESDAY_instance;
}
function WeekDay_THURSDAY_getInstance() {
WeekDay_initEntries();
return WeekDay_THURSDAY_instance;
}
function WeekDay_FRIDAY_getInstance() {
WeekDay_initEntries();
return WeekDay_FRIDAY_instance;
}
function WeekDay_SATURDAY_getInstance() {
WeekDay_initEntries();
return WeekDay_SATURDAY_instance;
}
function WeekDay_SUNDAY_getInstance() {
WeekDay_initEntries();
return WeekDay_SUNDAY_instance;
}
function Month_JANUARY_getInstance() {
Month_initEntries();
return Month_JANUARY_instance;
}
function Month_FEBRUARY_getInstance() {
Month_initEntries();
return Month_FEBRUARY_instance;
}
function Month_MARCH_getInstance() {
Month_initEntries();
return Month_MARCH_instance;
}
function Month_APRIL_getInstance() {
Month_initEntries();
return Month_APRIL_instance;
}
function Month_MAY_getInstance() {
Month_initEntries();
return Month_MAY_instance;
}
function Month_JUNE_getInstance() {
Month_initEntries();
return Month_JUNE_instance;
}
function Month_JULY_getInstance() {
Month_initEntries();
return Month_JULY_instance;
}
function Month_AUGUST_getInstance() {
Month_initEntries();
return Month_AUGUST_instance;
}
function Month_SEPTEMBER_getInstance() {
Month_initEntries();
return Month_SEPTEMBER_instance;
}
function Month_OCTOBER_getInstance() {
Month_initEntries();
return Month_OCTOBER_instance;
}
function Month_NOVEMBER_getInstance() {
Month_initEntries();
return Month_NOVEMBER_instance;
}
function Month_DECEMBER_getInstance() {
Month_initEntries();
return Month_DECEMBER_instance;
}
function proceedLoop($this, $cont) {
var tmp = new $proceedLoopCOROUTINE$1($this, $cont);
tmp.q7_1 = Unit_getInstance();
tmp.r7_1 = null;
return tmp.v7();
}
function $proceedLoopCOROUTINE$1(_this__u8e3s4, resultContinuation) {
CoroutineImpl.call(this, resultContinuation);
this.r2y_1 = _this__u8e3s4;
}
$proceedLoopCOROUTINE$1.prototype.v7 = function () {
var suspendResult = this.q7_1;
$sm: do
try {
var tmp = this.o7_1;
switch (tmp) {
case 0:
this.p7_1 = 6;
this.o7_1 = 1;
continue $sm;
case 1:
this.s2y_1 = this.r2y_1.z2y_1;
if (this.s2y_1 === -1) {
this.o7_1 = 5;
continue $sm;
} else {
this.o7_1 = 2;
continue $sm;
}
break;
case 2:
this.t2y_1 = this.r2y_1.w2y_1;
if (this.s2y_1 >= this.t2y_1.i()) {
this.r2y_1.a2z();
this.o7_1 = 5;
continue $sm;
} else {
this.o7_1 = 3;
continue $sm;
}
break;
case 3:
this.u2y_1 = this.t2y_1.m(this.s2y_1);
this.r2y_1.z2y_1 = this.s2y_1 + 1 | 0;
this.o7_1 = 4;
var tmp_0 = this.u2y_1;
suspendResult = (isSuspendFunction(tmp_0, 2) ? tmp_0 : THROW_CCE())(this.r2y_1, this.r2y_1.y2y_1, this);
if (suspendResult === get_COROUTINE_SUSPENDED()) {
return suspendResult;
}
continue $sm;
case 4:
{
this.o7_1 = 1;
continue $sm;
}
this.o7_1 = 5;
continue $sm;
case 5:
return this.r2y_1.y2y_1;
case 6:
throw this.r7_1;
}
} catch ($p) {
if (this.p7_1 === 6) {
throw $p;
} else {
this.o7_1 = this.p7_1;
this.r7_1 = $p;
}
}
while (true);
};
$proceedLoopCOROUTINE$1.$metadata$ = classMeta('$proceedLoopCOROUTINE$1', undefined, undefined, undefined, undefined, CoroutineImpl.prototype);
function DebugPipelineContext(context, interceptors, subject, coroutineContext) {
PipelineContext.call(this, context);
this.w2y_1 = interceptors;
this.x2y_1 = coroutineContext;
this.y2y_1 = subject;
this.z2y_1 = 0;
}
DebugPipelineContext.prototype.b1u = function () {
return this.x2y_1;
};
DebugPipelineContext.prototype.a2z = function () {
this.z2y_1 = -1;
};
DebugPipelineContext.prototype.b2z = function (subject, $cont) {
this.y2y_1 = subject;
return this.c2z($cont);
};
DebugPipelineContext.prototype.c2z = function ($cont) {
var index = this.z2y_1;
if (index < 0)
return this.y2y_1;
if (index >= this.w2y_1.i()) {
this.a2z();
return this.y2y_1;
}
return proceedLoop(this, $cont);
};
DebugPipelineContext.prototype.d2z = function (initial, $cont) {
this.z2y_1 = 0;
this.y2y_1 = initial;
return this.c2z($cont);
};
DebugPipelineContext.$metadata$ = classMeta('DebugPipelineContext', undefined, undefined, undefined, undefined, PipelineContext.prototype);
function PhaseContent_init_$Init$(phase, relation, $this) {
var tmp = Companion_getInstance_3().e2z_1;
PhaseContent.call($this, phase, relation, isInterface(tmp, MutableList) ? tmp : THROW_CCE());
// Inline function 'kotlin.check' call
var tmp0_check = Companion_getInstance_3().e2z_1.p();
// Inline function 'kotlin.contracts.contract' call
if (!tmp0_check) {
var tmp$ret$0;
// Inline function 'io.ktor.util.pipeline.PhaseContent.<init>.<anonymous>' call
tmp$ret$0 = 'The shared empty array list has been modified';
var message = tmp$ret$0;
throw IllegalStateException_init_$Create$(toString_0(message));
}
return $this;
}
function PhaseContent_init_$Create$(phase, relation) {
return PhaseContent_init_$Init$(phase, relation, Object.create(PhaseContent.prototype));
}
function copyInterceptors($this) {
$this.h2z_1 = $this.j2z();
$this.i2z_1 = false;
}
function Companion_2() {
Companion_instance_2 = this;
var tmp = this;
var tmp$ret$0;
// Inline function 'kotlin.collections.mutableListOf' call
tmp$ret$0 = ArrayList_init_$Create$_0();
tmp.e2z_1 = tmp$ret$0;
}
Companion_2.$metadata$ = objectMeta('Companion');
var Companion_instance_2;
function Companion_getInstance_3() {
if (Companion_instance_2 == null)
new Companion_2();
return Companion_instance_2;
}
function PhaseContent(phase, relation, interceptors) {
Companion_getInstance_3();
this.f2z_1 = phase;
this.g2z_1 = relation;
this.h2z_1 = interceptors;
this.i2z_1 = true;
}
PhaseContent.prototype.q21 = function () {
return this.h2z_1.p();
};
PhaseContent.prototype.i = function () {
return this.h2z_1.i();
};
PhaseContent.prototype.k2z = function (interceptor) {
if (this.i2z_1) {
copyInterceptors(this);
}
this.h2z_1.c(interceptor);
};
PhaseContent.prototype.l2z = function (destination) {
var interceptors = this.h2z_1;
if (destination instanceof ArrayList) {
destination.mh(destination.i() + interceptors.i() | 0);
}
var inductionVariable = 0;
var last = interceptors.i();
if (inductionVariable < last)
do {
var index = inductionVariable;
inductionVariable = inductionVariable + 1 | 0;
destination.c(interceptors.m(index));
}
while (inductionVariable < last);
};
PhaseContent.prototype.m2z = function () {
this.i2z_1 = true;
return this.h2z_1;
};
PhaseContent.prototype.j2z = function () {
var tmp$ret$1;
// Inline function 'kotlin.apply' call
var tmp$ret$0;
// Inline function 'kotlin.collections.mutableListOf' call
tmp$ret$0 = ArrayList_init_$Create$_0();
var tmp0_apply = tmp$ret$0;
// Inline function 'kotlin.contracts.contract' call
// Inline function 'io.ktor.util.pipeline.PhaseContent.copiedInterceptors.<anonymous>' call
tmp0_apply.o(this.h2z_1);
tmp$ret$1 = tmp0_apply;
return tmp$ret$1;
};
PhaseContent.prototype.toString = function () {
return 'Phase `' + this.f2z_1.n2z_1 + '`, ' + this.i() + ' handlers';
};
PhaseContent.$metadata$ = classMeta('PhaseContent');
function _set_interceptors__wod97b($this, value) {
$this.s2z_1.k1t_1 = value;
}
function _get_interceptors__h4min7($this) {
return $this.s2z_1.k1t_1;
}
function createContext($this, context, subject, coroutineContext) {
return pipelineContextFor(context, sharedInterceptorsList($this), subject, coroutineContext, $this.v2z());
}
function findPhase($this, phase) {
var phasesList = $this.q2z_1;
var inductionVariable = 0;
var last = phasesList.i();
if (inductionVariable < last)
do {
var index = inductionVariable;
inductionVariable = inductionVariable + 1 | 0;
var current = phasesList.m(index);
if (current === phase) {
var content = PhaseContent_init_$Create$(phase, Last_getInstance());
phasesList.a5(index, content);
return content;
}
var tmp;
if (current instanceof PhaseContent) {
tmp = current.f2z_1 === phase;
} else {
tmp = false;
}
if (tmp) {
return current instanceof PhaseContent ? current : THROW_CCE();
}
}
while (inductionVariable < last);
return null;
}
function findPhaseIndex($this, phase) {
var phasesList = $this.q2z_1;
var inductionVariable = 0;
var last = phasesList.i();
if (inductionVariable < last)
do {
var index = inductionVariable;
inductionVariable = inductionVariable + 1 | 0;
var current = phasesList.m(index);
var tmp;
if (current === phase) {
tmp = true;
} else {
var tmp_0;
if (current instanceof PhaseContent) {
tmp_0 = current.f2z_1 === phase;
} else {
tmp_0 = false;
}
tmp = tmp_0;
}
if (tmp) {
return index;
}
}
while (inductionVariable < last);
return -1;
}
function hasPhase($this, phase) {
var phasesList = $this.q2z_1;
var inductionVariable = 0;
var last = phasesList.i();
if (inductionVariable < last)
do {
var index = inductionVariable;
inductionVariable = inductionVariable + 1 | 0;
var current = phasesList.m(index);
var tmp;
if (current === phase) {
tmp = true;
} else {
var tmp_0;
if (current instanceof PhaseContent) {
tmp_0 = current.f2z_1 === phase;
} else {
tmp_0 = false;
}
tmp = tmp_0;
}
if (tmp) {
return true;
}
}
while (inductionVariable < last);
return false;
}
function cacheInterceptors($this) {
var interceptorsQuantity = $this.r2z_1;
if (interceptorsQuantity === 0) {
notSharedInterceptorsList($this, emptyList());
return emptyList();
}
var phases = $this.q2z_1;
if (interceptorsQuantity === 1) {
var inductionVariable = 0;
var last = get_lastIndex_0(phases);
if (inductionVariable <= last)
$l$loop_0: do {
var phaseIndex = inductionVariable;
inductionVariable = inductionVariable + 1 | 0;
var tmp = phases.m(phaseIndex);
var tmp1_elvis_lhs = tmp instanceof PhaseContent ? tmp : null;
var tmp_0;
if (tmp1_elvis_lhs == null) {
continue $l$loop_0;
} else {
tmp_0 = tmp1_elvis_lhs;
}
var phaseContent = tmp_0;
if (phaseContent.q21())
continue $l$loop_0;
var interceptors = phaseContent.m2z();
setInterceptorsListFromPhase($this, phaseContent);
return interceptors;
}
while (!(phaseIndex === last));
}
var tmp$ret$0;
// Inline function 'kotlin.collections.mutableListOf' call
tmp$ret$0 = ArrayList_init_$Create$_0();
var destination = tmp$ret$0;
var inductionVariable_0 = 0;
var last_0 = get_lastIndex_0(phases);
if (inductionVariable_0 <= last_0)
$l$loop_1: do {
var phaseIndex_0 = inductionVariable_0;
inductionVariable_0 = inductionVariable_0 + 1 | 0;
var tmp_1 = phases.m(phaseIndex_0);
var tmp3_elvis_lhs = tmp_1 instanceof PhaseContent ? tmp_1 : null;
var tmp_2;
if (tmp3_elvis_lhs == null) {
continue $l$loop_1;
} else {
tmp_2 = tmp3_elvis_lhs;
}
var phase = tmp_2;
phase.l2z(destination);
}
while (!(phaseIndex_0 === last_0));
notSharedInterceptorsList($this, destination);
return destination;
}
function sharedInterceptorsList($this) {
if (_get_interceptors__h4min7($this) == null) {
cacheInterceptors($this);
}
$this.t2z_1 = true;
return ensureNotNull(_get_interceptors__h4min7($this));
}
function resetInterceptorsList($this) {
_set_interceptors__wod97b($this, null);
$this.t2z_1 = false;
$this.u2z_1 = null;
}
function notSharedInterceptorsList($this, list) {
_set_interceptors__wod97b($this, list);
$this.t2z_1 = false;
$this.u2z_1 = null;
}
function setInterceptorsListFromPhase($this, phaseContent) {
_set_interceptors__wod97b($this, phaseContent.m2z());
$this.t2z_1 = false;
$this.u2z_1 = phaseContent.f2z_1;
}
function tryAddToPhaseFastPath($this, phase, block) {
var currentInterceptors = _get_interceptors__h4min7($this);
if ($this.q2z_1.p() ? true : currentInterceptors == null) {
return false;
}
var tmp;
if ($this.t2z_1) {
tmp = true;
} else {
tmp = !(!(currentInterceptors == null) ? isInterface(currentInterceptors, MutableList) : false);
}
if (tmp) {
return false;
}
if (equals($this.u2z_1, phase)) {
currentInterceptors.c(block);
return true;
}
if (equals(phase, last($this.q2z_1)) ? true : findPhaseIndex($this, phase) === get_lastIndex_0($this.q2z_1)) {
ensureNotNull(findPhase($this, phase)).k2z(block);
currentInterceptors.c(block);
return true;
}
return false;
}
function Pipeline(phases) {
this.o2z_1 = Attributes_0(true);
this.p2z_1 = false;
this.q2z_1 = mutableListOf(phases.slice());
this.r2z_1 = 0;
this.s2z_1 = atomic$ref$1(null);
this.t2z_1 = false;
this.u2z_1 = null;
}
Pipeline.prototype.v2z = function () {
return this.p2z_1;
};
Pipeline.prototype.w2z = function (context, subject, $cont) {
var tmp$ret$0;
// Inline function 'kotlin.js.getCoroutineContext' call
tmp$ret$0 = $cont.p5();
return createContext(this, context, subject, tmp$ret$0).d2z(subject, $cont);
};
Pipeline.prototype.y2z = function (reference, phase) {
if (hasPhase(this, phase))
return Unit_getInstance();
var index = findPhaseIndex(this, reference);
if (index === -1) {
throw new InvalidPhaseException('Phase ' + reference + ' was not registered for this pipeline');
}
var lastRelatedPhaseIndex = index;
var inductionVariable = index + 1 | 0;
var last = get_lastIndex_0(this.q2z_1);
if (inductionVariable <= last)
$l$loop_0: do {
var i = inductionVariable;
inductionVariable = inductionVariable + 1 | 0;
var tmp = this.q2z_1.m(i);
var tmp1_safe_receiver = tmp instanceof PhaseContent ? tmp : null;
var tmp2_elvis_lhs = tmp1_safe_receiver == null ? null : tmp1_safe_receiver.g2z_1;
var tmp_0;
if (tmp2_elvis_lhs == null) {
break $l$loop_0;
} else {
tmp_0 = tmp2_elvis_lhs;
}
var relation = tmp_0;
var tmp3_safe_receiver = relation instanceof After ? relation : null;
var tmp4_elvis_lhs = tmp3_safe_receiver == null ? null : tmp3_safe_receiver.z2z_1;
var tmp_1;
if (tmp4_elvis_lhs == null) {
continue $l$loop_0;
} else {
tmp_1 = tmp4_elvis_lhs;
}
var relatedTo = tmp_1;
lastRelatedPhaseIndex = equals(relatedTo, reference) ? i : lastRelatedPhaseIndex;
}
while (!(i === last));
this.q2z_1.tg(lastRelatedPhaseIndex + 1 | 0, PhaseContent_init_$Create$(phase, new After(reference)));
};
Pipeline.prototype.a30 = function (reference, phase) {
if (hasPhase(this, phase))
return Unit_getInstance();
var index = findPhaseIndex(this, reference);
if (index === -1) {
throw new InvalidPhaseException('Phase ' + reference + ' was not registered for this pipeline');
}
this.q2z_1.tg(index, PhaseContent_init_$Create$(phase, new Before(reference)));
};
Pipeline.prototype.b30 = function (phase, block) {
var tmp0_elvis_lhs = findPhase(this, phase);
var tmp;
if (tmp0_elvis_lhs == null) {
throw new InvalidPhaseException('Phase ' + phase + ' was not registered for this pipeline');
} else {
tmp = tmp0_elvis_lhs;
}
var phaseContent = tmp;
if (typeof block === 'function')
block;
else
THROW_CCE();
if (tryAddToPhaseFastPath(this, phase, block)) {
var tmp1_this = this;
var tmp2 = tmp1_this.r2z_1;
tmp1_this.r2z_1 = tmp2 + 1 | 0;
return Unit_getInstance();
}
phaseContent.k2z(block);
var tmp3_this = this;
var tmp4 = tmp3_this.r2z_1;
tmp3_this.r2z_1 = tmp4 + 1 | 0;
resetInterceptorsList(this);
this.c30();
};
Pipeline.prototype.c30 = function () {
};
Pipeline.$metadata$ = classMeta('Pipeline');
function PipelineContext(context) {
this.x2z_1 = context;
}
PipelineContext.$metadata$ = classMeta('PipelineContext', [CoroutineScope]);
function pipelineContextFor(context, interceptors, subject, coroutineContext, debugMode) {
var tmp;
if (debugMode) {
tmp = new DebugPipelineContext(context, interceptors, subject, coroutineContext);
} else {
tmp = new SuspendFunctionGun(subject, context, interceptors);
}
return tmp;
}
function PipelinePhase(name) {
this.n2z_1 = name;
}
PipelinePhase.prototype.toString = function () {
return "Phase('" + this.n2z_1 + "')";
};
PipelinePhase.$metadata$ = classMeta('PipelinePhase');
function InvalidPhaseException(message) {
extendThrowable(this, message, void 1);
captureStack(this, InvalidPhaseException);
}
InvalidPhaseException.$metadata$ = classMeta('InvalidPhaseException', undefined, undefined, undefined, undefined, Error.prototype);
function After(relativeTo) {
PipelinePhaseRelation.call(this);
this.z2z_1 = relativeTo;
}
After.$metadata$ = classMeta('After', undefined, undefined, undefined, undefined, PipelinePhaseRelation.prototype);
function Before(relativeTo) {
PipelinePhaseRelation.call(this);
this.d30_1 = relativeTo;
}
Before.$metadata$ = classMeta('Before', undefined, undefined, undefined, undefined, PipelinePhaseRelation.prototype);
function Last() {
Last_instance = this;
PipelinePhaseRelation.call(this);
}
Last.$metadata$ = objectMeta('Last', undefined, undefined, undefined, undefined, PipelinePhaseRelation.prototype);
var Last_instance;
function Last_getInstance() {
if (Last_instance == null)
new Last();
return Last_instance;
}
function PipelinePhaseRelation() {
}
PipelinePhaseRelation.$metadata$ = classMeta('PipelinePhaseRelation');
function recoverStackTraceBridge(exception, continuation) {
var tmp;
try {
tmp = withCause(recoverStackTrace(exception, continuation), exception.cause);
} catch ($p) {
var tmp_0;
if ($p instanceof Error) {
tmp_0 = exception;
} else {
throw $p;
}
tmp = tmp_0;
}
return tmp;
}
function loop($this, direct) {
do {
var currentIndex = $this.k30_1;
if (currentIndex === $this.f30_1.i()) {
if (!direct) {
var tmp$ret$0;
// Inline function 'kotlin.Companion.success' call
var tmp0_success = Companion_getInstance();
var tmp1_success = $this.h30_1;
tmp$ret$0 = _Result___init__impl__xyqfz8(tmp1_success);
resumeRootWith($this, tmp$ret$0);
return false;
}
return true;
}
$this.k30_1 = currentIndex + 1 | 0;
var next = $this.f30_1.m(currentIndex);
try {
var result = next($this, $this.h30_1, $this.g30_1);
if (result === get_COROUTINE_SUSPENDED())
return false;
} catch ($p) {
if ($p instanceof Error) {
var tmp$ret$1;
// Inline function 'kotlin.Companion.failure' call
var tmp2_failure = Companion_getInstance();
tmp$ret$1 = _Result___init__impl__xyqfz8(createFailure($p));
resumeRootWith($this, tmp$ret$1);
return false;
} else {
throw $p;
}
}
}
while (true);
}
function resumeRootWith($this, result) {
if ($this.j30_1 < 0) {
// Inline function 'kotlin.error' call
throw IllegalStateException_init_$Create$('No more continuations to resume');
}
var next = ensureNotNull($this.i30_1[$this.j30_1]);
var tmp0_this = $this;
var tmp1 = tmp0_this.j30_1;
tmp0_this.j30_1 = tmp1 - 1 | 0;
$this.i30_1[tmp1] = null;
if (!_Result___get_isFailure__impl__jpiriv(result)) {
next.n5(result);
} else {
var exception = recoverStackTraceBridge(ensureNotNull(Result__exceptionOrNull_impl_p6xea9(result)), next);
var tmp$ret$1;
// Inline function 'kotlin.coroutines.resumeWithException' call
var tmp$ret$0;
// Inline function 'kotlin.Companion.failure' call
var tmp0_failure = Companion_getInstance();
tmp$ret$0 = _Result___init__impl__xyqfz8(createFailure(exception));
next.n5(tmp$ret$0);
tmp$ret$1 = Unit_getInstance();
}
}
function discardLastRootContinuation($this) {
if ($this.j30_1 < 0)
throw IllegalStateException_init_$Create$('No more continuations to resume');
var tmp0_this = $this;
var tmp1 = tmp0_this.j30_1;
tmp0_this.j30_1 = tmp1 - 1 | 0;
$this.i30_1[tmp1] = null;
}
function addContinuation($this, continuation) {
var tmp0_this = $this;
tmp0_this.j30_1 = tmp0_this.j30_1 + 1 | 0;
$this.i30_1[tmp0_this.j30_1] = continuation;
}
function SuspendFunctionGun$continuation$1(this$0) {
this.m30_1 = this$0;
this.l30_1 = IntCompanionObject_getInstance().n1_1;
}
SuspendFunctionGun$continuation$1.prototype.p5 = function () {
var tmp0_safe_receiver = this.m30_1.i30_1[this.m30_1.j30_1];
var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.p5();
var tmp;
if (tmp1_elvis_lhs == null) {
throw IllegalStateException_init_$Create$('Not started');
} else {
tmp = tmp1_elvis_lhs;
}
return tmp;
};
SuspendFunctionGun$continuation$1.prototype.o5 = function (result) {
if (_Result___get_isFailure__impl__jpiriv(result)) {
var tmp$ret$0;
// Inline function 'kotlin.Companion.failure' call
var tmp0_failure = Companion_getInstance();
var tmp1_failure = ensureNotNull(Result__exceptionOrNull_impl_p6xea9(result));
tmp$ret$0 = _Result___init__impl__xyqfz8(createFailure(tmp1_failure));
resumeRootWith(this.m30_1, tmp$ret$0);
return Unit_getInstance();
}
loop(this.m30_1, false);
};
SuspendFunctionGun$continuation$1.prototype.n5 = function (result) {
return this.o5(result);
};
SuspendFunctionGun$continuation$1.$metadata$ = classMeta(undefined, [Continuation, CoroutineStackFrame]);
function SuspendFunctionGun(initial, context, blocks) {
PipelineContext.call(this, context);
this.f30_1 = blocks;
var tmp = this;
tmp.g30_1 = new SuspendFunctionGun$continuation$1(this);
this.h30_1 = initial;
var tmp_0 = this;
var tmp$ret$0;
// Inline function 'kotlin.arrayOfNulls' call
var tmp0_arrayOfNulls = this.f30_1.i();
tmp$ret$0 = fillArrayVal(Array(tmp0_arrayOfNulls), null);
tmp_0.i30_1 = tmp$ret$0;
this.j30_1 = -1;
this.k30_1 = 0;
}
SuspendFunctionGun.prototype.b1u = function () {
return this.g30_1.p5();
};
SuspendFunctionGun.prototype.n30 = function () {
return this.h30_1;
};
SuspendFunctionGun.prototype.c2z = function ($cont) {
var tmp$ret$0;
$l$block_0: {
// Inline function 'io.ktor.util.pipeline.SuspendFunctionGun.proceed.<anonymous>' call
var tmp0__anonymous__q1qw7t = $cont;
if (this.k30_1 === this.f30_1.i()) {
tmp$ret$0 = this.h30_1;
break $l$block_0;
}
addContinuation(this, tmp0__anonymous__q1qw7t);
if (loop(this, true)) {
discardLastRootContinuation(this);
tmp$ret$0 = this.h30_1;
break $l$block_0;
}
tmp$ret$0 = get_COROUTINE_SUSPENDED();
}
return tmp$ret$0;
};
SuspendFunctionGun.prototype.b2z = function (subject, $cont) {
this.h30_1 = subject;
return this.c2z($cont);
};
SuspendFunctionGun.prototype.d2z = function (initial, $cont) {
this.k30_1 = 0;
if (this.k30_1 === this.f30_1.i())
return initial;
this.h30_1 = initial;
if (this.j30_1 >= 0)
throw IllegalStateException_init_$Create$('Already started');
return this.c2z($cont);
};
SuspendFunctionGun.$metadata$ = classMeta('SuspendFunctionGun', undefined, undefined, undefined, undefined, PipelineContext.prototype);
function TypeInfo(type, reifiedType, kotlinType) {
this.o30_1 = type;
this.p30_1 = reifiedType;
this.q30_1 = kotlinType;
}
TypeInfo.prototype.toString = function () {
return 'TypeInfo(type=' + this.o30_1 + ', reifiedType=' + this.p30_1 + ', kotlinType=' + this.q30_1 + ')';
};
TypeInfo.prototype.hashCode = function () {
var result = this.o30_1.hashCode();
result = imul(result, 31) + hashCode(this.p30_1) | 0;
result = imul(result, 31) + (this.q30_1 == null ? 0 : hashCode(this.q30_1)) | 0;
return result;
};
TypeInfo.prototype.equals = function (other) {
if (this === other)
return true;
if (!(other instanceof TypeInfo))
return false;
var tmp0_other_with_cast = other instanceof TypeInfo ? other : THROW_CCE();
if (!this.o30_1.equals(tmp0_other_with_cast.o30_1))
return false;
if (!equals(this.p30_1, tmp0_other_with_cast.p30_1))
return false;
if (!equals(this.q30_1, tmp0_other_with_cast.q30_1))
return false;
return true;
};
TypeInfo.$metadata$ = classMeta('TypeInfo');
function Attributes_0(concurrent) {
return new AttributesJs();
}
function AttributesJs() {
var tmp = this;
var tmp$ret$0;
// Inline function 'kotlin.collections.mutableMapOf' call
tmp$ret$0 = LinkedHashMap_init_$Create$();
tmp.r30_1 = tmp$ret$0;
}
AttributesJs.prototype.o2v = function (key) {
var tmp = this.r30_1.q(key);
return (tmp == null ? true : isObject(tmp)) ? tmp : THROW_CCE();
};
AttributesJs.prototype.p2v = function (key) {
return this.r30_1.r3(key);
};
AttributesJs.prototype.q2v = function (key, value) {
// Inline function 'kotlin.collections.set' call
var tmp0_set = this.r30_1;
tmp0_set.a(key, value);
};
AttributesJs.prototype.r2v = function (key) {
this.r30_1.y4(key);
};
AttributesJs.prototype.s2v = function (key, block) {
var tmp0_safe_receiver = this.r30_1.q(key);
if (tmp0_safe_receiver == null)
null;
else {
var tmp$ret$0;
// Inline function 'kotlin.let' call
// Inline function 'kotlin.contracts.contract' call
return isObject(tmp0_safe_receiver) ? tmp0_safe_receiver : THROW_CCE();
}
var tmp$ret$1;
// Inline function 'kotlin.also' call
var tmp0_also = block();
// Inline function 'kotlin.contracts.contract' call
// Inline function 'io.ktor.util.AttributesJs.computeIfAbsent.<anonymous>' call
// Inline function 'kotlin.collections.set' call
var tmp0_set = this.r30_1;
tmp0_set.a(key, tmp0_also);
tmp$ret$1 = tmp0_also;
return tmp$ret$1;
};
AttributesJs.prototype.t2v = function () {
return toList(this.r30_1.v3());
};
AttributesJs.$metadata$ = classMeta('AttributesJs', [Attributes]);
function unmodifiable(_this__u8e3s4) {
return _this__u8e3s4;
}
function get__crypto() {
init_properties_CryptoJs_kt_qn5kls();
var tmp$ret$0;
// Inline function 'kotlin.getValue' call
var tmp0_getValue = _crypto$factory();
tmp$ret$0 = _crypto$delegate.l1();
return tmp$ret$0;
}
var _crypto$delegate;
function generateNonce_0() {
init_properties_CryptoJs_kt_qn5kls();
var buffer = new Int8Array(get_NONCE_SIZE_IN_BYTES());
if (PlatformUtils_getInstance().t30_1) {
get__crypto().randomFillSync(buffer);
} else {
get__crypto().getRandomValues(buffer);
}
return hex(buffer);
}
function _crypto$delegate$lambda() {
init_properties_CryptoJs_kt_qn5kls();
var tmp;
if (PlatformUtils_getInstance().t30_1) {
tmp = eval('require')('crypto');
} else {
tmp = window ? window.crypto ? window.crypto : window.msCrypto : self.crypto;
}
return tmp;
}
function _crypto$factory() {
return getPropertyCallableRef('_crypto', 0, KProperty0, function () {
return get__crypto();
}, null);
}
var properties_initialized_CryptoJs_kt_linsrw;
function init_properties_CryptoJs_kt_qn5kls() {
if (properties_initialized_CryptoJs_kt_linsrw) {
} else {
properties_initialized_CryptoJs_kt_linsrw = true;
_crypto$delegate = lazy(_crypto$delegate$lambda);
}
}
function PlatformUtils() {
PlatformUtils_instance = this;
var tmp = this;
var tmp_0 = typeof window !== 'undefined' && typeof window.document !== 'undefined' || (typeof self !== 'undefined' && typeof self.location !== 'undefined');
tmp.s30_1 = (!(tmp_0 == null) ? typeof tmp_0 === 'boolean' : false) ? tmp_0 : THROW_CCE();
var tmp_1 = this;
var tmp_2 = typeof process !== 'undefined' && process.versions != null && process.versions.node != null;
tmp_1.t30_1 = (!(tmp_2 == null) ? typeof tmp_2 === 'boolean' : false) ? tmp_2 : THROW_CCE();
this.u30_1 = false;
this.v30_1 = false;
this.w30_1 = false;
this.x30_1 = true;
}
PlatformUtils.prototype.y30 = function () {
return this.s30_1;
};
PlatformUtils.$metadata$ = objectMeta('PlatformUtils');
var PlatformUtils_instance;
function PlatformUtils_getInstance() {
if (PlatformUtils_instance == null)
new PlatformUtils();
return PlatformUtils_instance;
}
function CoroutineStackFrame() {
}
CoroutineStackFrame.$metadata$ = interfaceMeta('CoroutineStackFrame');
function GMTDate_0(timestamp) {
var tmp0_safe_receiver = timestamp;
var tmp1_safe_receiver = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.cf();
var tmp;
if (tmp1_safe_receiver == null) {
tmp = null;
} else {
var tmp$ret$1;
// Inline function 'kotlin.let' call
// Inline function 'kotlin.contracts.contract' call
var tmp$ret$0;
// Inline function 'io.ktor.util.date.GMTDate.<anonymous>' call
tmp$ret$0 = new Date(tmp1_safe_receiver);
tmp$ret$1 = tmp$ret$0;
tmp = tmp$ret$1;
}
var tmp2_elvis_lhs = tmp;
var date = tmp2_elvis_lhs == null ? new Date() : tmp2_elvis_lhs;
if (isNaN_0(date.getTime()))
throw new InvalidTimestampException(ensureNotNull(timestamp));
var tmp$ret$2;
// Inline function 'kotlin.with' call
// Inline function 'kotlin.contracts.contract' call
var dayOfWeek = Companion_getInstance_1().c2y((date.getUTCDay() + 6 | 0) % 7 | 0);
var month = Companion_getInstance_2().c2y(date.getUTCMonth());
return new GMTDate(date.getUTCSeconds(), date.getUTCMinutes(), date.getUTCHours(), dayOfWeek, date.getUTCDate(), date.getUTCFullYear(), month, date.getUTCFullYear(), numberToLong(date.getTime()));
}
function GMTDate$default(timestamp, $mask0, $handler) {
if (!(($mask0 & 1) === 0))
timestamp = null;
return GMTDate_0(timestamp);
}
function InvalidTimestampException(timestamp) {
IllegalStateException_init_$Init$('Invalid date timestamp exception: ' + toString_0(timestamp), this);
captureStack(this, InvalidTimestampException);
}
InvalidTimestampException.$metadata$ = classMeta('InvalidTimestampException', undefined, undefined, undefined, undefined, IllegalStateException.prototype);
function getTimeMillis() {
return numberToLong((new Date()).getTime());
}
function withCause(_this__u8e3s4, cause) {
return _this__u8e3s4;
}
function instanceOf(_this__u8e3s4, type) {
return type.uj(_this__u8e3s4);
}
function Type() {
}
Type.$metadata$ = interfaceMeta('Type');
function typeInfoImpl(reifiedType, kClass, kType) {
return new TypeInfo(kClass, reifiedType, kType);
}
function JsType() {
JsType_instance = this;
}
JsType.$metadata$ = objectMeta('JsType', [Type]);
var JsType_instance;
function JsType_getInstance() {
if (JsType_instance == null)
new JsType();
return JsType_instance;
}
//region block: post-declaration
_no_name_provided__qut3iv.prototype.i8 = get;
_no_name_provided__qut3iv.prototype.o8 = fold;
_no_name_provided__qut3iv.prototype.n8 = minusKey;
_no_name_provided__qut3iv.prototype.p8 = plus;
AttributesJs.prototype.n2v = get_0;
//endregion
//region block: init
BASE64_PAD = _Char___init__impl__6a9atx(61);
NONCE_SIZE_IN_BYTES = 16;
//endregion
//region block: exports
_.$_$ = _.$_$ || {};
_.$_$.a = toByteArray;
_.$_$.b = GMTDate$default;
_.$_$.c = SilentSupervisor$default;
_.$_$.d = JsType_getInstance;
_.$_$.e = PlatformUtils_getInstance;
_.$_$.f = ChannelIOException;
_.$_$.g = CopyOnWriteHashMap;
_.$_$.h = getTimeMillis;
_.$_$.i = PipelineContext;
_.$_$.j = PipelinePhase;
_.$_$.k = Pipeline;
_.$_$.l = instanceOf;
_.$_$.m = typeInfoImpl;
_.$_$.n = AttributeKey;
_.$_$.o = Attributes_0;
_.$_$.p = forEach;
_.$_$.q = get_1;
_.$_$.r = StringValuesBuilderImpl;
_.$_$.s = StringValuesBuilder;
_.$_$.t = StringValuesImpl;
_.$_$.u = StringValues;
_.$_$.v = appendAll;
_.$_$.w = encodeBase64;
_.$_$.x = flattenEntries;
_.$_$.y = generateNonce;
_.$_$.z = hex;
_.$_$.a1 = isLowerCase;
_.$_$.b1 = putAll;
_.$_$.c1 = toCharArray;
_.$_$.d1 = toLowerCasePreservingASCIIRules;
//endregion
return _;
}));
//# sourceMappingURL=ktor-ktor-utils-js-ir.js.map