@solibo/home-api 1.1.9 → 1.1.10

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 (113) hide show
  1. package/Kotlin-DateTime-library-kotlinx-datetime.mjs +3601 -0
  2. package/Kotlin-DateTime-library-kotlinx-datetime.mjs.map +1 -0
  3. package/MultiplatformSettings-multiplatform-settings-no-arg.mjs +4 -0
  4. package/{MultiplatformSettings-multiplatform-settings.js.map → MultiplatformSettings-multiplatform-settings-no-arg.mjs.map} +1 -1
  5. package/MultiplatformSettings-multiplatform-settings.mjs +4 -0
  6. package/{kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.js.map → MultiplatformSettings-multiplatform-settings.mjs.map} +1 -1
  7. package/kotlin-kotlin-stdlib.mjs +17369 -0
  8. package/kotlin-kotlin-stdlib.mjs.map +1 -0
  9. package/kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.mjs +4 -0
  10. package/{kotlinx-serialization-kotlinx-serialization-json-io.js.map → kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.mjs.map} +1 -1
  11. package/kotlinx-atomicfu.mjs +250 -0
  12. package/kotlinx-atomicfu.mjs.map +1 -0
  13. package/kotlinx-browser.mjs +8 -0
  14. package/{kotlinx-browser.js.map → kotlinx-browser.mjs.map} +1 -1
  15. package/kotlinx-coroutines-core.mjs +8888 -0
  16. package/kotlinx-coroutines-core.mjs.map +1 -0
  17. package/kotlinx-io-kotlinx-io-bytestring.mjs +202 -0
  18. package/kotlinx-io-kotlinx-io-bytestring.mjs.map +1 -0
  19. package/kotlinx-io-kotlinx-io-core.mjs +2020 -0
  20. package/kotlinx-io-kotlinx-io-core.mjs.map +1 -0
  21. package/kotlinx-serialization-kotlinx-serialization-core.mjs +6045 -0
  22. package/kotlinx-serialization-kotlinx-serialization-core.mjs.map +1 -0
  23. package/kotlinx-serialization-kotlinx-serialization-json-io.mjs +4 -0
  24. package/{MultiplatformSettings-multiplatform-settings-no-arg.js.map → kotlinx-serialization-kotlinx-serialization-json-io.mjs.map} +1 -1
  25. package/kotlinx-serialization-kotlinx-serialization-json.mjs +5061 -0
  26. package/kotlinx-serialization-kotlinx-serialization-json.mjs.map +1 -0
  27. package/ktor-ktor-client-auth.mjs +4 -0
  28. package/ktor-ktor-client-auth.mjs.map +1 -0
  29. package/ktor-ktor-client-content-negotiation.mjs +750 -0
  30. package/ktor-ktor-client-content-negotiation.mjs.map +1 -0
  31. package/ktor-ktor-client-core.mjs +9810 -0
  32. package/ktor-ktor-client-core.mjs.map +1 -0
  33. package/ktor-ktor-client-logging.mjs +4 -0
  34. package/ktor-ktor-client-logging.mjs.map +1 -0
  35. package/ktor-ktor-events.mjs +81 -0
  36. package/ktor-ktor-events.mjs.map +1 -0
  37. package/ktor-ktor-http-cio.mjs +2254 -0
  38. package/ktor-ktor-http-cio.mjs.map +1 -0
  39. package/ktor-ktor-http.mjs +3238 -0
  40. package/ktor-ktor-http.mjs.map +1 -0
  41. package/ktor-ktor-io.mjs +3536 -0
  42. package/ktor-ktor-io.mjs.map +1 -0
  43. package/ktor-ktor-serialization-kotlinx-json.mjs +46 -0
  44. package/{ktor-ktor-serialization-kotlinx-json.js.map → ktor-ktor-serialization-kotlinx-json.mjs.map} +1 -1
  45. package/ktor-ktor-serialization-kotlinx.mjs +843 -0
  46. package/ktor-ktor-serialization-kotlinx.mjs.map +1 -0
  47. package/ktor-ktor-serialization.mjs +364 -0
  48. package/ktor-ktor-serialization.mjs.map +1 -0
  49. package/ktor-ktor-sse.mjs +4 -0
  50. package/ktor-ktor-sse.mjs.map +1 -0
  51. package/ktor-ktor-utils.mjs +2620 -0
  52. package/ktor-ktor-utils.mjs.map +1 -0
  53. package/ktor-ktor-websocket-serialization.mjs +4 -0
  54. package/ktor-ktor-websocket-serialization.mjs.map +1 -0
  55. package/ktor-ktor-websockets.mjs +2535 -0
  56. package/ktor-ktor-websockets.mjs.map +1 -0
  57. package/package.json +2 -3
  58. package/solibo-sdk-sdk-home-api.d.mts +13419 -0
  59. package/solibo-sdk-sdk-home-api.mjs +199394 -0
  60. package/solibo-sdk-sdk-home-api.mjs.map +1 -0
  61. package/Kotlin-DateTime-library-kotlinx-datetime.js +0 -3614
  62. package/Kotlin-DateTime-library-kotlinx-datetime.js.map +0 -1
  63. package/MultiplatformSettings-multiplatform-settings-no-arg.js +0 -15
  64. package/MultiplatformSettings-multiplatform-settings.js +0 -15
  65. package/kotlin-kotlin-stdlib.js +0 -17392
  66. package/kotlin-kotlin-stdlib.js.map +0 -1
  67. package/kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.js +0 -15
  68. package/kotlinx-atomicfu.js +0 -262
  69. package/kotlinx-atomicfu.js.map +0 -1
  70. package/kotlinx-browser.js +0 -19
  71. package/kotlinx-coroutines-core.js +0 -8901
  72. package/kotlinx-coroutines-core.js.map +0 -1
  73. package/kotlinx-io-kotlinx-io-bytestring.js +0 -214
  74. package/kotlinx-io-kotlinx-io-bytestring.js.map +0 -1
  75. package/kotlinx-io-kotlinx-io-core.js +0 -2035
  76. package/kotlinx-io-kotlinx-io-core.js.map +0 -1
  77. package/kotlinx-serialization-kotlinx-serialization-core.js +0 -6057
  78. package/kotlinx-serialization-kotlinx-serialization-core.js.map +0 -1
  79. package/kotlinx-serialization-kotlinx-serialization-json-io.js +0 -15
  80. package/kotlinx-serialization-kotlinx-serialization-json.js +0 -5074
  81. package/kotlinx-serialization-kotlinx-serialization-json.js.map +0 -1
  82. package/ktor-ktor-client-auth.js +0 -15
  83. package/ktor-ktor-client-auth.js.map +0 -1
  84. package/ktor-ktor-client-content-negotiation.js +0 -767
  85. package/ktor-ktor-client-content-negotiation.js.map +0 -1
  86. package/ktor-ktor-client-core.js +0 -9839
  87. package/ktor-ktor-client-core.js.map +0 -1
  88. package/ktor-ktor-client-logging.js +0 -15
  89. package/ktor-ktor-client-logging.js.map +0 -1
  90. package/ktor-ktor-events.js +0 -94
  91. package/ktor-ktor-events.js.map +0 -1
  92. package/ktor-ktor-http-cio.js +0 -2271
  93. package/ktor-ktor-http-cio.js.map +0 -1
  94. package/ktor-ktor-http.js +0 -3253
  95. package/ktor-ktor-http.js.map +0 -1
  96. package/ktor-ktor-io.js +0 -3556
  97. package/ktor-ktor-io.js.map +0 -1
  98. package/ktor-ktor-serialization-kotlinx-json.js +0 -67
  99. package/ktor-ktor-serialization-kotlinx.js +0 -865
  100. package/ktor-ktor-serialization-kotlinx.js.map +0 -1
  101. package/ktor-ktor-serialization.js +0 -379
  102. package/ktor-ktor-serialization.js.map +0 -1
  103. package/ktor-ktor-sse.js +0 -15
  104. package/ktor-ktor-sse.js.map +0 -1
  105. package/ktor-ktor-utils.js +0 -2639
  106. package/ktor-ktor-utils.js.map +0 -1
  107. package/ktor-ktor-websocket-serialization.js +0 -15
  108. package/ktor-ktor-websocket-serialization.js.map +0 -1
  109. package/ktor-ktor-websockets.js +0 -2552
  110. package/ktor-ktor-websockets.js.map +0 -1
  111. package/solibo-sdk-sdk-home-api.d.ts +0 -12624
  112. package/solibo-sdk-sdk-home-api.js +0 -203510
  113. package/solibo-sdk-sdk-home-api.js.map +0 -1
@@ -1,3614 +0,0 @@
1
- (function (factory) {
2
- if (typeof define === 'function' && define.amd)
3
- define(['exports', './kotlin-kotlin-stdlib.js', './kotlinx-serialization-kotlinx-serialization-core.js'], factory);
4
- else if (typeof exports === 'object')
5
- factory(module.exports, require('./kotlin-kotlin-stdlib.js'), require('./kotlinx-serialization-kotlinx-serialization-core.js'));
6
- else {
7
- if (typeof globalThis['kotlin-kotlin-stdlib'] === 'undefined') {
8
- throw new Error("Error loading module 'Kotlin-DateTime-library-kotlinx-datetime'. Its dependency 'kotlin-kotlin-stdlib' was not found. Please, check whether 'kotlin-kotlin-stdlib' is loaded prior to 'Kotlin-DateTime-library-kotlinx-datetime'.");
9
- }
10
- if (typeof globalThis['kotlinx-serialization-kotlinx-serialization-core'] === 'undefined') {
11
- throw new Error("Error loading module 'Kotlin-DateTime-library-kotlinx-datetime'. Its dependency 'kotlinx-serialization-kotlinx-serialization-core' was not found. Please, check whether 'kotlinx-serialization-kotlinx-serialization-core' is loaded prior to 'Kotlin-DateTime-library-kotlinx-datetime'.");
12
- }
13
- globalThis['Kotlin-DateTime-library-kotlinx-datetime'] = factory(typeof globalThis['Kotlin-DateTime-library-kotlinx-datetime'] === 'undefined' ? {} : globalThis['Kotlin-DateTime-library-kotlinx-datetime'], globalThis['kotlin-kotlin-stdlib'], globalThis['kotlinx-serialization-kotlinx-serialization-core']);
14
- }
15
- }(function (_, kotlin_kotlin, kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core) {
16
- 'use strict';
17
- //region block: imports
18
- var imul = Math.imul;
19
- var protoOf = kotlin_kotlin.$_$.ub;
20
- var initMetadataForCompanion = kotlin_kotlin.$_$.ya;
21
- var toString = kotlin_kotlin.$_$.xb;
22
- var IllegalArgumentException_init_$Create$ = kotlin_kotlin.$_$.n1;
23
- var Unit_instance = kotlin_kotlin.$_$.y4;
24
- var fromInt = kotlin_kotlin.$_$.q9;
25
- var modulo = kotlin_kotlin.$_$.t9;
26
- var divide = kotlin_kotlin.$_$.p9;
27
- var convertToInt = kotlin_kotlin.$_$.n9;
28
- var shiftRight = kotlin_kotlin.$_$.y9;
29
- var initMetadataForClass = kotlin_kotlin.$_$.xa;
30
- var VOID = kotlin_kotlin.$_$.b;
31
- var enumEntries = kotlin_kotlin.$_$.i9;
32
- var Enum = kotlin_kotlin.$_$.mf;
33
- var IllegalArgumentException_init_$Init$ = kotlin_kotlin.$_$.k1;
34
- var objectCreate = kotlin_kotlin.$_$.tb;
35
- var captureStack = kotlin_kotlin.$_$.fa;
36
- var IllegalArgumentException_init_$Init$_0 = kotlin_kotlin.$_$.m1;
37
- var IllegalArgumentException_init_$Init$_1 = kotlin_kotlin.$_$.o1;
38
- var IllegalArgumentException = kotlin_kotlin.$_$.pf;
39
- var RuntimeException_init_$Init$ = kotlin_kotlin.$_$.z1;
40
- var RuntimeException_init_$Init$_0 = kotlin_kotlin.$_$.b2;
41
- var RuntimeException = kotlin_kotlin.$_$.uf;
42
- var StringBuilder_init_$Create$ = kotlin_kotlin.$_$.c1;
43
- var initMetadataForInterface = kotlin_kotlin.$_$.bb;
44
- var toString_0 = kotlin_kotlin.$_$.n2;
45
- var KProperty0 = kotlin_kotlin.$_$.qc;
46
- var getPropertyCallableRef = kotlin_kotlin.$_$.ua;
47
- var hashCode = kotlin_kotlin.$_$.wa;
48
- var THROW_CCE = kotlin_kotlin.$_$.vf;
49
- var KMutableProperty1 = kotlin_kotlin.$_$.pc;
50
- var initMetadataForObject = kotlin_kotlin.$_$.db;
51
- var _Char___init__impl__6a9atx = kotlin_kotlin.$_$.g2;
52
- var lazy = kotlin_kotlin.$_$.tg;
53
- var getBooleanHashCode = kotlin_kotlin.$_$.ra;
54
- var ArrayList_init_$Create$ = kotlin_kotlin.$_$.j;
55
- var noWhenBranchMatchedException = kotlin_kotlin.$_$.ug;
56
- var isInterface = kotlin_kotlin.$_$.mb;
57
- var equals = kotlin_kotlin.$_$.oa;
58
- var IllegalStateException_init_$Create$ = kotlin_kotlin.$_$.r1;
59
- var toString_1 = kotlin_kotlin.$_$.xg;
60
- var getStringHashCode = kotlin_kotlin.$_$.va;
61
- var charSequenceLength = kotlin_kotlin.$_$.ka;
62
- var charCodeAt = kotlin_kotlin.$_$.ia;
63
- var substring = kotlin_kotlin.$_$.ee;
64
- var listOf = kotlin_kotlin.$_$.f7;
65
- var substring_0 = kotlin_kotlin.$_$.de;
66
- var get_lastIndex = kotlin_kotlin.$_$.nd;
67
- var emptyList = kotlin_kotlin.$_$.l6;
68
- var joinToString = kotlin_kotlin.$_$.z6;
69
- var collectionSizeOrDefault = kotlin_kotlin.$_$.s5;
70
- var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.i;
71
- var single = kotlin_kotlin.$_$.v7;
72
- var abs = kotlin_kotlin.$_$.yb;
73
- var charSequenceSubSequence = kotlin_kotlin.$_$.la;
74
- var numberRangeToNumber = kotlin_kotlin.$_$.rb;
75
- var charSequenceGet = kotlin_kotlin.$_$.ja;
76
- var mutableListOf = kotlin_kotlin.$_$.j7;
77
- var removeLastOrNull = kotlin_kotlin.$_$.p7;
78
- var sortWith = kotlin_kotlin.$_$.w7;
79
- var FunctionAdapter = kotlin_kotlin.$_$.ba;
80
- var Comparator = kotlin_kotlin.$_$.jf;
81
- var compareValues = kotlin_kotlin.$_$.n8;
82
- var Exception = kotlin_kotlin.$_$.of;
83
- var Exception_init_$Init$ = kotlin_kotlin.$_$.h1;
84
- var StringBuilder_init_$Create$_0 = kotlin_kotlin.$_$.b1;
85
- var joinTo = kotlin_kotlin.$_$.a7;
86
- var plus = kotlin_kotlin.$_$.m7;
87
- var toMutableList = kotlin_kotlin.$_$.g8;
88
- var addAll = kotlin_kotlin.$_$.o5;
89
- var Collection = kotlin_kotlin.$_$.a5;
90
- var firstOrNull = kotlin_kotlin.$_$.q6;
91
- var drop = kotlin_kotlin.$_$.k6;
92
- var listOf_0 = kotlin_kotlin.$_$.g7;
93
- var repeat = kotlin_kotlin.$_$.rd;
94
- var checkCountOverflow = kotlin_kotlin.$_$.r5;
95
- var Char__minus_impl_a2frrh = kotlin_kotlin.$_$.i2;
96
- var buildClassSerialDescriptor = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.l1;
97
- var PrimitiveClasses_getInstance = kotlin_kotlin.$_$.n4;
98
- var arrayOf = kotlin_kotlin.$_$.jg;
99
- var createKType = kotlin_kotlin.$_$.kc;
100
- var serializer = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.x2;
101
- var KSerializer = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.o2;
102
- var LazyThreadSafetyMode_PUBLICATION_getInstance = kotlin_kotlin.$_$.e;
103
- var lazy_0 = kotlin_kotlin.$_$.sg;
104
- var KProperty1 = kotlin_kotlin.$_$.rc;
105
- var MissingFieldException_init_$Create$ = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.b;
106
- var getKClass = kotlin_kotlin.$_$.mc;
107
- var SealedClassSerializer = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.q2;
108
- var AbstractPolymorphicSerializer = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.u1;
109
- var SerializationException_init_$Create$ = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.e;
110
- var STRING_getInstance = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.h;
111
- var PrimitiveSerialDescriptor = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.f1;
112
- var add = kotlin_kotlin.$_$.l9;
113
- var subtract = kotlin_kotlin.$_$.z9;
114
- var multiply = kotlin_kotlin.$_$.u9;
115
- var negate = kotlin_kotlin.$_$.v9;
116
- var numberToLong = kotlin_kotlin.$_$.w9;
117
- var get_ONE = kotlin_kotlin.$_$.k9;
118
- var compareTo = kotlin_kotlin.$_$.ma;
119
- var ClosedRange = kotlin_kotlin.$_$.bc;
120
- var contains = kotlin_kotlin.$_$.fc;
121
- var Comparable = kotlin_kotlin.$_$.if;
122
- var ArithmeticException = kotlin_kotlin.$_$.ef;
123
- var compareValuesBy = kotlin_kotlin.$_$.m8;
124
- var ArithmeticException_init_$Create$ = kotlin_kotlin.$_$.d1;
125
- //endregion
126
- //region block: pre-declaration
127
- initMetadataForCompanion(Companion);
128
- initMetadataForCompanion(Companion_0);
129
- initMetadataForCompanion(Companion_1);
130
- initMetadataForCompanion(Companion_2);
131
- initMetadataForClass(DateTimeUnit, 'DateTimeUnit', VOID, VOID, VOID, VOID, VOID, {0: DateTimeUnitSerializer_getInstance});
132
- initMetadataForClass(TimeBased, 'TimeBased', VOID, DateTimeUnit, VOID, VOID, VOID, {0: TimeBasedDateTimeUnitSerializer_getInstance});
133
- initMetadataForClass(DateBased, 'DateBased', VOID, DateTimeUnit, VOID, VOID, VOID, {0: DateBasedDateTimeUnitSerializer_getInstance});
134
- initMetadataForClass(DayBased, 'DayBased', VOID, DateBased, VOID, VOID, VOID, {0: DayBasedDateTimeUnitSerializer_getInstance});
135
- initMetadataForClass(MonthBased, 'MonthBased', VOID, DateBased, VOID, VOID, VOID, {0: MonthBasedDateTimeUnitSerializer_getInstance});
136
- initMetadataForCompanion(Companion_3);
137
- initMetadataForClass(DayOfWeek, 'DayOfWeek', VOID, Enum);
138
- initMetadataForClass(DateTimeFormatException, 'DateTimeFormatException', DateTimeFormatException_init_$Create$, IllegalArgumentException);
139
- initMetadataForClass(DateTimeArithmeticException, 'DateTimeArithmeticException', DateTimeArithmeticException_init_$Create$, RuntimeException);
140
- initMetadataForClass(Month, 'Month', VOID, Enum);
141
- initMetadataForClass(AbstractDateTimeFormat, 'AbstractDateTimeFormat');
142
- initMetadataForClass(Padding, 'Padding', VOID, Enum);
143
- function year$default(padding, $super) {
144
- padding = padding === VOID ? Padding_ZERO_getInstance() : padding;
145
- var tmp;
146
- if ($super === VOID) {
147
- this.z54(padding);
148
- tmp = Unit_instance;
149
- } else {
150
- tmp = $super.z54.call(this, padding);
151
- }
152
- return tmp;
153
- }
154
- function monthNumber$default(padding, $super) {
155
- padding = padding === VOID ? Padding_ZERO_getInstance() : padding;
156
- var tmp;
157
- if ($super === VOID) {
158
- this.b55(padding);
159
- tmp = Unit_instance;
160
- } else {
161
- tmp = $super.b55.call(this, padding);
162
- }
163
- return tmp;
164
- }
165
- initMetadataForInterface(WithYearMonth, 'WithYearMonth');
166
- function day$default(padding, $super) {
167
- padding = padding === VOID ? Padding_ZERO_getInstance() : padding;
168
- var tmp;
169
- if ($super === VOID) {
170
- this.e55(padding);
171
- tmp = Unit_instance;
172
- } else {
173
- tmp = $super.e55.call(this, padding);
174
- }
175
- return tmp;
176
- }
177
- initMetadataForInterface(WithDate, 'WithDate', VOID, VOID, [WithYearMonth]);
178
- function chars(value) {
179
- return this.g55().i55(new ConstantFormatStructure(value));
180
- }
181
- function build() {
182
- return new CachedFormatStructure(this.g55().i2l().j55_1);
183
- }
184
- initMetadataForInterface(AbstractDateTimeFormatBuilder, 'AbstractDateTimeFormatBuilder');
185
- initMetadataForClass(IncompleteLocalDate, 'IncompleteLocalDate', IncompleteLocalDate);
186
- initMetadataForCompanion(Companion_4);
187
- function year(padding) {
188
- return this.k56(new BasicFormatStructure(new YearDirective(padding)));
189
- }
190
- function monthNumber(padding) {
191
- return this.k56(new BasicFormatStructure(new MonthDirective(padding)));
192
- }
193
- initMetadataForInterface(AbstractWithYearMonthBuilder, 'AbstractWithYearMonthBuilder', VOID, VOID, [WithYearMonth]);
194
- function addFormatStructureForYearMonth(structure) {
195
- this.j56(structure);
196
- }
197
- function day(padding) {
198
- return this.j56(new BasicFormatStructure(new DayDirective(padding)));
199
- }
200
- initMetadataForInterface(AbstractWithDateBuilder, 'AbstractWithDateBuilder', VOID, VOID, [AbstractWithYearMonthBuilder, WithDate]);
201
- initMetadataForClass(Builder, 'Builder', VOID, VOID, [AbstractDateTimeFormatBuilder, AbstractWithDateBuilder]);
202
- initMetadataForClass(LocalDateFormat, 'LocalDateFormat', VOID, AbstractDateTimeFormat);
203
- initMetadataForClass(UnsignedIntFieldFormatDirective, 'UnsignedIntFieldFormatDirective');
204
- initMetadataForClass(DayDirective, 'DayDirective', VOID, UnsignedIntFieldFormatDirective);
205
- initMetadataForObject(DateFields, 'DateFields');
206
- initMetadataForClass(IncompleteYearMonth, 'IncompleteYearMonth', IncompleteYearMonth);
207
- initMetadataForCompanion(Companion_5);
208
- initMetadataForClass(Builder_0, 'Builder', VOID, VOID, [AbstractDateTimeFormatBuilder, AbstractWithYearMonthBuilder]);
209
- initMetadataForClass(YearMonthFormat, 'YearMonthFormat', VOID, AbstractDateTimeFormat);
210
- initMetadataForClass(SignedIntFieldFormatDirective, 'SignedIntFieldFormatDirective');
211
- initMetadataForClass(YearDirective, 'YearDirective', VOID, SignedIntFieldFormatDirective);
212
- initMetadataForClass(MonthDirective, 'MonthDirective', VOID, UnsignedIntFieldFormatDirective);
213
- initMetadataForObject(YearMonthFields, 'YearMonthFields');
214
- initMetadataForClass(AppendableFormatStructure, 'AppendableFormatStructure', AppendableFormatStructure);
215
- initMetadataForClass(AbstractFieldSpec, 'AbstractFieldSpec');
216
- initMetadataForClass(GenericFieldSpec, 'GenericFieldSpec', VOID, AbstractFieldSpec);
217
- function getterNotNull(container) {
218
- var tmp0_elvis_lhs = this.u58(container);
219
- var tmp;
220
- if (tmp0_elvis_lhs == null) {
221
- throw IllegalStateException_init_$Create$('Field ' + this.m() + ' is not set');
222
- } else {
223
- tmp = tmp0_elvis_lhs;
224
- }
225
- return tmp;
226
- }
227
- initMetadataForInterface(Accessor, 'Accessor');
228
- initMetadataForClass(PropertyAccessor, 'PropertyAccessor', VOID, VOID, [Accessor]);
229
- initMetadataForClass(UnsignedFieldSpec, 'UnsignedFieldSpec', VOID, AbstractFieldSpec);
230
- initMetadataForClass(ConcatenatedFormatStructure, 'ConcatenatedFormatStructure');
231
- initMetadataForClass(CachedFormatStructure, 'CachedFormatStructure', VOID, ConcatenatedFormatStructure);
232
- initMetadataForInterface(NonConcatenatedFormatStructure, 'NonConcatenatedFormatStructure');
233
- initMetadataForClass(BasicFormatStructure, 'BasicFormatStructure', VOID, VOID, [NonConcatenatedFormatStructure]);
234
- initMetadataForClass(ConstantFormatStructure, 'ConstantFormatStructure', VOID, VOID, [NonConcatenatedFormatStructure]);
235
- function format$default(obj, builder, minusNotRequired, $super) {
236
- minusNotRequired = minusNotRequired === VOID ? false : minusNotRequired;
237
- var tmp;
238
- if ($super === VOID) {
239
- this.x58(obj, builder, minusNotRequired);
240
- tmp = Unit_instance;
241
- } else {
242
- tmp = $super.x58.call(this, obj, builder, minusNotRequired);
243
- }
244
- return tmp;
245
- }
246
- initMetadataForInterface(FormatterStructure, 'FormatterStructure');
247
- initMetadataForClass(SpacePaddedFormatter, 'SpacePaddedFormatter', VOID, VOID, [FormatterStructure]);
248
- initMetadataForClass(ConcatenatedFormatter, 'ConcatenatedFormatter', VOID, VOID, [FormatterStructure]);
249
- initMetadataForClass(UnsignedIntFormatterStructure, 'UnsignedIntFormatterStructure', VOID, VOID, [FormatterStructure]);
250
- initMetadataForClass(SignedIntFormatterStructure, 'SignedIntFormatterStructure', VOID, VOID, [FormatterStructure]);
251
- initMetadataForClass(ConstantStringFormatterStructure, 'ConstantStringFormatterStructure', VOID, VOID, [FormatterStructure]);
252
- initMetadataForClass(NumberConsumer, 'NumberConsumer');
253
- initMetadataForClass(ConstantNumberConsumer, 'ConstantNumberConsumer', VOID, NumberConsumer);
254
- initMetadataForObject(ExpectedInt, 'ExpectedInt');
255
- initMetadataForClass(TooManyDigits, 'TooManyDigits');
256
- initMetadataForClass(TooFewDigits, 'TooFewDigits');
257
- initMetadataForClass(WrongConstant, 'WrongConstant');
258
- initMetadataForClass(Conflicting, 'Conflicting');
259
- initMetadataForClass(UnsignedIntConsumer, 'UnsignedIntConsumer', VOID, NumberConsumer);
260
- initMetadataForClass(ParseError, 'ParseError');
261
- initMetadataForCompanion(Companion_6);
262
- initMetadataForClass(ParserState, 'ParserState');
263
- initMetadataForClass(sam$kotlin_Comparator$0, 'sam$kotlin_Comparator$0', VOID, VOID, [Comparator, FunctionAdapter]);
264
- initMetadataForClass(Parser, 'Parser');
265
- initMetadataForClass(ParserStructure, 'ParserStructure');
266
- initMetadataForClass(ParseException, 'ParseException', VOID, Exception);
267
- initMetadataForClass(NumberSpanParserOperation, 'NumberSpanParserOperation');
268
- initMetadataForClass(PlainStringParserOperation, 'PlainStringParserOperation');
269
- initMetadataForClass(UnconditionalModification, 'UnconditionalModification');
270
- initMetadataForObject(TimeBasedDateTimeUnitSerializer, 'TimeBasedDateTimeUnitSerializer', VOID, VOID, [KSerializer]);
271
- initMetadataForObject(DateBasedDateTimeUnitSerializer, 'DateBasedDateTimeUnitSerializer', VOID, AbstractPolymorphicSerializer);
272
- initMetadataForObject(DayBasedDateTimeUnitSerializer, 'DayBasedDateTimeUnitSerializer', VOID, VOID, [KSerializer]);
273
- initMetadataForObject(MonthBasedDateTimeUnitSerializer, 'MonthBasedDateTimeUnitSerializer', VOID, VOID, [KSerializer]);
274
- initMetadataForObject(DateTimeUnitSerializer, 'DateTimeUnitSerializer', VOID, AbstractPolymorphicSerializer);
275
- initMetadataForObject(LocalDateSerializer, 'LocalDateSerializer', VOID, VOID, [KSerializer]);
276
- initMetadataForObject(YearMonthSerializer, 'YearMonthSerializer', VOID, VOID, [KSerializer]);
277
- initMetadataForCompanion(Companion_7);
278
- initMetadataForObject(Formats, 'Formats');
279
- initMetadataForClass(LocalDate, 'LocalDate', VOID, VOID, [Comparable], VOID, VOID, {0: LocalDateSerializer_getInstance});
280
- initMetadataForCompanion(Companion_8);
281
- initMetadataForObject(Formats_0, 'Formats');
282
- initMetadataForClass(YearMonth, 'YearMonth', VOID, VOID, [Comparable], VOID, VOID, {0: YearMonthSerializer_getInstance});
283
- //endregion
284
- function Companion() {
285
- }
286
- var Companion_instance;
287
- function Companion_getInstance() {
288
- return Companion_instance;
289
- }
290
- function Companion_0() {
291
- }
292
- var Companion_instance_0;
293
- function Companion_getInstance_0() {
294
- return Companion_instance_0;
295
- }
296
- function Companion_1() {
297
- }
298
- var Companion_instance_1;
299
- function Companion_getInstance_1() {
300
- return Companion_instance_1;
301
- }
302
- function Companion_2() {
303
- }
304
- var Companion_instance_2;
305
- function Companion_getInstance_2() {
306
- return Companion_instance_2;
307
- }
308
- function TimeBased(nanoseconds) {
309
- DateTimeUnit.call(this);
310
- this.s53_1 = nanoseconds;
311
- // Inline function 'kotlin.require' call
312
- if (!(this.s53_1 > 0n)) {
313
- var message = 'Unit duration must be positive, but was ' + this.s53_1.toString() + ' ns.';
314
- throw IllegalArgumentException_init_$Create$(toString(message));
315
- }
316
- if (modulo(this.s53_1, 3600000000000n) === 0n) {
317
- this.t53_1 = 'HOUR';
318
- this.u53_1 = divide(this.s53_1, 3600000000000n);
319
- } else {
320
- if (modulo(this.s53_1, 60000000000n) === 0n) {
321
- this.t53_1 = 'MINUTE';
322
- this.u53_1 = divide(this.s53_1, 60000000000n);
323
- } else {
324
- var tmp0 = this.s53_1;
325
- // Inline function 'kotlin.Long.rem' call
326
- var other = 1000000000;
327
- if (modulo(tmp0, fromInt(other)) === 0n) {
328
- this.t53_1 = 'SECOND';
329
- var tmp = this;
330
- var tmp0_0 = this.s53_1;
331
- // Inline function 'kotlin.Long.div' call
332
- var other_0 = 1000000000;
333
- tmp.u53_1 = divide(tmp0_0, fromInt(other_0));
334
- } else {
335
- // Inline function 'kotlin.Long.rem' call
336
- var this_0 = this.s53_1;
337
- if (modulo(this_0, fromInt(1000000)) === 0n) {
338
- this.t53_1 = 'MILLISECOND';
339
- var tmp_0 = this;
340
- // Inline function 'kotlin.Long.div' call
341
- var this_1 = this.s53_1;
342
- tmp_0.u53_1 = divide(this_1, fromInt(1000000));
343
- } else {
344
- // Inline function 'kotlin.Long.rem' call
345
- var this_2 = this.s53_1;
346
- if (modulo(this_2, fromInt(1000)) === 0n) {
347
- this.t53_1 = 'MICROSECOND';
348
- var tmp_1 = this;
349
- // Inline function 'kotlin.Long.div' call
350
- var this_3 = this.s53_1;
351
- tmp_1.u53_1 = divide(this_3, fromInt(1000));
352
- } else {
353
- this.t53_1 = 'NANOSECOND';
354
- this.u53_1 = this.s53_1;
355
- }
356
- }
357
- }
358
- }
359
- }
360
- }
361
- protoOf(TimeBased).v53 = function (scalar) {
362
- return new TimeBased(safeMultiply(this.s53_1, fromInt(scalar)));
363
- };
364
- protoOf(TimeBased).equals = function (other) {
365
- var tmp;
366
- if (this === other) {
367
- tmp = true;
368
- } else {
369
- var tmp_0;
370
- if (other instanceof TimeBased) {
371
- tmp_0 = this.s53_1 === other.s53_1;
372
- } else {
373
- tmp_0 = false;
374
- }
375
- tmp = tmp_0;
376
- }
377
- return tmp;
378
- };
379
- protoOf(TimeBased).hashCode = function () {
380
- return convertToInt(this.s53_1) ^ convertToInt(shiftRight(this.s53_1, 32));
381
- };
382
- protoOf(TimeBased).toString = function () {
383
- return this.w53(this.u53_1, this.t53_1);
384
- };
385
- function DateBased() {
386
- DateTimeUnit.call(this);
387
- }
388
- function DayBased(days) {
389
- DateBased.call(this);
390
- this.y53_1 = days;
391
- // Inline function 'kotlin.require' call
392
- if (!(this.y53_1 > 0)) {
393
- var message = 'Unit duration must be positive, but was ' + this.y53_1 + ' days.';
394
- throw IllegalArgumentException_init_$Create$(toString(message));
395
- }
396
- }
397
- protoOf(DayBased).v53 = function (scalar) {
398
- return new DayBased(safeMultiply_0(this.y53_1, scalar));
399
- };
400
- protoOf(DayBased).equals = function (other) {
401
- var tmp;
402
- if (this === other) {
403
- tmp = true;
404
- } else {
405
- var tmp_0;
406
- if (other instanceof DayBased) {
407
- tmp_0 = this.y53_1 === other.y53_1;
408
- } else {
409
- tmp_0 = false;
410
- }
411
- tmp = tmp_0;
412
- }
413
- return tmp;
414
- };
415
- protoOf(DayBased).hashCode = function () {
416
- return this.y53_1 ^ 65536;
417
- };
418
- protoOf(DayBased).toString = function () {
419
- return (this.y53_1 % 7 | 0) === 0 ? this.x53(this.y53_1 / 7 | 0, 'WEEK') : this.x53(this.y53_1, 'DAY');
420
- };
421
- function MonthBased(months) {
422
- DateBased.call(this);
423
- this.z53_1 = months;
424
- // Inline function 'kotlin.require' call
425
- if (!(this.z53_1 > 0)) {
426
- var message = 'Unit duration must be positive, but was ' + this.z53_1 + ' months.';
427
- throw IllegalArgumentException_init_$Create$(toString(message));
428
- }
429
- }
430
- protoOf(MonthBased).v53 = function (scalar) {
431
- return new MonthBased(safeMultiply_0(this.z53_1, scalar));
432
- };
433
- protoOf(MonthBased).equals = function (other) {
434
- var tmp;
435
- if (this === other) {
436
- tmp = true;
437
- } else {
438
- var tmp_0;
439
- if (other instanceof MonthBased) {
440
- tmp_0 = this.z53_1 === other.z53_1;
441
- } else {
442
- tmp_0 = false;
443
- }
444
- tmp = tmp_0;
445
- }
446
- return tmp;
447
- };
448
- protoOf(MonthBased).hashCode = function () {
449
- return this.z53_1 ^ 131072;
450
- };
451
- protoOf(MonthBased).toString = function () {
452
- return (this.z53_1 % 1200 | 0) === 0 ? this.x53(this.z53_1 / 1200 | 0, 'CENTURY') : (this.z53_1 % 12 | 0) === 0 ? this.x53(this.z53_1 / 12 | 0, 'YEAR') : (this.z53_1 % 3 | 0) === 0 ? this.x53(this.z53_1 / 3 | 0, 'QUARTER') : this.x53(this.z53_1, 'MONTH');
453
- };
454
- function Companion_3() {
455
- Companion_instance_3 = this;
456
- this.a54_1 = new TimeBased(1n);
457
- this.b54_1 = this.a54_1.v53(1000);
458
- this.c54_1 = this.b54_1.v53(1000);
459
- this.d54_1 = this.c54_1.v53(1000);
460
- this.e54_1 = this.d54_1.v53(60);
461
- this.f54_1 = this.e54_1.v53(60);
462
- this.g54_1 = new DayBased(1);
463
- this.h54_1 = this.g54_1.v53(7);
464
- this.i54_1 = new MonthBased(1);
465
- this.j54_1 = this.i54_1.v53(3);
466
- this.k54_1 = this.i54_1.v53(12);
467
- this.l54_1 = this.k54_1.v53(100);
468
- }
469
- var Companion_instance_3;
470
- function Companion_getInstance_3() {
471
- if (Companion_instance_3 == null)
472
- new Companion_3();
473
- return Companion_instance_3;
474
- }
475
- function DateTimeUnit() {
476
- Companion_getInstance_3();
477
- }
478
- protoOf(DateTimeUnit).x53 = function (value, unit) {
479
- return value === 1 ? unit : '' + value + '-' + unit;
480
- };
481
- protoOf(DateTimeUnit).w53 = function (value, unit) {
482
- return value === 1n ? unit : value.toString() + '-' + unit;
483
- };
484
- function get_isoDayNumber(_this__u8e3s4) {
485
- return _this__u8e3s4.a1_1 + 1 | 0;
486
- }
487
- var DayOfWeek_MONDAY_instance;
488
- var DayOfWeek_TUESDAY_instance;
489
- var DayOfWeek_WEDNESDAY_instance;
490
- var DayOfWeek_THURSDAY_instance;
491
- var DayOfWeek_FRIDAY_instance;
492
- var DayOfWeek_SATURDAY_instance;
493
- var DayOfWeek_SUNDAY_instance;
494
- function values() {
495
- return [DayOfWeek_MONDAY_getInstance(), DayOfWeek_TUESDAY_getInstance(), DayOfWeek_WEDNESDAY_getInstance(), DayOfWeek_THURSDAY_getInstance(), DayOfWeek_FRIDAY_getInstance(), DayOfWeek_SATURDAY_getInstance(), DayOfWeek_SUNDAY_getInstance()];
496
- }
497
- function get_entries() {
498
- if ($ENTRIES == null)
499
- $ENTRIES = enumEntries(values());
500
- return $ENTRIES;
501
- }
502
- var DayOfWeek_entriesInitialized;
503
- function DayOfWeek_initEntries() {
504
- if (DayOfWeek_entriesInitialized)
505
- return Unit_instance;
506
- DayOfWeek_entriesInitialized = true;
507
- DayOfWeek_MONDAY_instance = new DayOfWeek('MONDAY', 0);
508
- DayOfWeek_TUESDAY_instance = new DayOfWeek('TUESDAY', 1);
509
- DayOfWeek_WEDNESDAY_instance = new DayOfWeek('WEDNESDAY', 2);
510
- DayOfWeek_THURSDAY_instance = new DayOfWeek('THURSDAY', 3);
511
- DayOfWeek_FRIDAY_instance = new DayOfWeek('FRIDAY', 4);
512
- DayOfWeek_SATURDAY_instance = new DayOfWeek('SATURDAY', 5);
513
- DayOfWeek_SUNDAY_instance = new DayOfWeek('SUNDAY', 6);
514
- }
515
- var $ENTRIES;
516
- function DayOfWeek(name, ordinal) {
517
- Enum.call(this, name, ordinal);
518
- }
519
- function DayOfWeek_0(isoDayNumber) {
520
- // Inline function 'kotlin.require' call
521
- if (!(1 <= isoDayNumber ? isoDayNumber <= 7 : false)) {
522
- var message = 'Expected ISO day-of-week number in 1..7, got ' + isoDayNumber;
523
- throw IllegalArgumentException_init_$Create$(toString(message));
524
- }
525
- return get_entries().h1(isoDayNumber - 1 | 0);
526
- }
527
- function DayOfWeek_MONDAY_getInstance() {
528
- DayOfWeek_initEntries();
529
- return DayOfWeek_MONDAY_instance;
530
- }
531
- function DayOfWeek_TUESDAY_getInstance() {
532
- DayOfWeek_initEntries();
533
- return DayOfWeek_TUESDAY_instance;
534
- }
535
- function DayOfWeek_WEDNESDAY_getInstance() {
536
- DayOfWeek_initEntries();
537
- return DayOfWeek_WEDNESDAY_instance;
538
- }
539
- function DayOfWeek_THURSDAY_getInstance() {
540
- DayOfWeek_initEntries();
541
- return DayOfWeek_THURSDAY_instance;
542
- }
543
- function DayOfWeek_FRIDAY_getInstance() {
544
- DayOfWeek_initEntries();
545
- return DayOfWeek_FRIDAY_instance;
546
- }
547
- function DayOfWeek_SATURDAY_getInstance() {
548
- DayOfWeek_initEntries();
549
- return DayOfWeek_SATURDAY_instance;
550
- }
551
- function DayOfWeek_SUNDAY_getInstance() {
552
- DayOfWeek_initEntries();
553
- return DayOfWeek_SUNDAY_instance;
554
- }
555
- function DateTimeFormatException_init_$Init$($this) {
556
- IllegalArgumentException_init_$Init$($this);
557
- DateTimeFormatException.call($this);
558
- return $this;
559
- }
560
- function DateTimeFormatException_init_$Create$() {
561
- var tmp = DateTimeFormatException_init_$Init$(objectCreate(protoOf(DateTimeFormatException)));
562
- captureStack(tmp, DateTimeFormatException_init_$Create$);
563
- return tmp;
564
- }
565
- function DateTimeFormatException_init_$Init$_0(message, $this) {
566
- IllegalArgumentException_init_$Init$_0(message, $this);
567
- DateTimeFormatException.call($this);
568
- return $this;
569
- }
570
- function DateTimeFormatException_init_$Create$_0(message) {
571
- var tmp = DateTimeFormatException_init_$Init$_0(message, objectCreate(protoOf(DateTimeFormatException)));
572
- captureStack(tmp, DateTimeFormatException_init_$Create$_0);
573
- return tmp;
574
- }
575
- function DateTimeFormatException_init_$Init$_1(message, cause, $this) {
576
- IllegalArgumentException_init_$Init$_1(message, cause, $this);
577
- DateTimeFormatException.call($this);
578
- return $this;
579
- }
580
- function DateTimeFormatException_init_$Create$_1(message, cause) {
581
- var tmp = DateTimeFormatException_init_$Init$_1(message, cause, objectCreate(protoOf(DateTimeFormatException)));
582
- captureStack(tmp, DateTimeFormatException_init_$Create$_1);
583
- return tmp;
584
- }
585
- function DateTimeFormatException() {
586
- captureStack(this, DateTimeFormatException);
587
- }
588
- function DateTimeArithmeticException_init_$Init$($this) {
589
- RuntimeException_init_$Init$($this);
590
- DateTimeArithmeticException.call($this);
591
- return $this;
592
- }
593
- function DateTimeArithmeticException_init_$Create$() {
594
- var tmp = DateTimeArithmeticException_init_$Init$(objectCreate(protoOf(DateTimeArithmeticException)));
595
- captureStack(tmp, DateTimeArithmeticException_init_$Create$);
596
- return tmp;
597
- }
598
- function DateTimeArithmeticException_init_$Init$_0(message, cause, $this) {
599
- RuntimeException_init_$Init$_0(message, cause, $this);
600
- DateTimeArithmeticException.call($this);
601
- return $this;
602
- }
603
- function DateTimeArithmeticException_init_$Create$_0(message, cause) {
604
- var tmp = DateTimeArithmeticException_init_$Init$_0(message, cause, objectCreate(protoOf(DateTimeArithmeticException)));
605
- captureStack(tmp, DateTimeArithmeticException_init_$Create$_0);
606
- return tmp;
607
- }
608
- function DateTimeArithmeticException() {
609
- captureStack(this, DateTimeArithmeticException);
610
- }
611
- function plus_0(_this__u8e3s4, value, unit) {
612
- return plus_1(_this__u8e3s4, fromInt(value), unit);
613
- }
614
- function getIsoDateFormat() {
615
- return Formats_getInstance().n54();
616
- }
617
- function format(_this__u8e3s4, format) {
618
- return format.o54(_this__u8e3s4);
619
- }
620
- function get_number(_this__u8e3s4) {
621
- return _this__u8e3s4.a1_1 + 1 | 0;
622
- }
623
- var Month_JANUARY_instance;
624
- var Month_FEBRUARY_instance;
625
- var Month_MARCH_instance;
626
- var Month_APRIL_instance;
627
- var Month_MAY_instance;
628
- var Month_JUNE_instance;
629
- var Month_JULY_instance;
630
- var Month_AUGUST_instance;
631
- var Month_SEPTEMBER_instance;
632
- var Month_OCTOBER_instance;
633
- var Month_NOVEMBER_instance;
634
- var Month_DECEMBER_instance;
635
- function values_0() {
636
- 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()];
637
- }
638
- function get_entries_0() {
639
- if ($ENTRIES_0 == null)
640
- $ENTRIES_0 = enumEntries(values_0());
641
- return $ENTRIES_0;
642
- }
643
- var Month_entriesInitialized;
644
- function Month_initEntries() {
645
- if (Month_entriesInitialized)
646
- return Unit_instance;
647
- Month_entriesInitialized = true;
648
- Month_JANUARY_instance = new Month('JANUARY', 0);
649
- Month_FEBRUARY_instance = new Month('FEBRUARY', 1);
650
- Month_MARCH_instance = new Month('MARCH', 2);
651
- Month_APRIL_instance = new Month('APRIL', 3);
652
- Month_MAY_instance = new Month('MAY', 4);
653
- Month_JUNE_instance = new Month('JUNE', 5);
654
- Month_JULY_instance = new Month('JULY', 6);
655
- Month_AUGUST_instance = new Month('AUGUST', 7);
656
- Month_SEPTEMBER_instance = new Month('SEPTEMBER', 8);
657
- Month_OCTOBER_instance = new Month('OCTOBER', 9);
658
- Month_NOVEMBER_instance = new Month('NOVEMBER', 10);
659
- Month_DECEMBER_instance = new Month('DECEMBER', 11);
660
- }
661
- var $ENTRIES_0;
662
- function Month(name, ordinal) {
663
- Enum.call(this, name, ordinal);
664
- }
665
- function Month_0(number) {
666
- // Inline function 'kotlin.require' call
667
- // Inline function 'kotlin.require' call
668
- if (!(1 <= number ? number <= 12 : false)) {
669
- var message = 'Failed requirement.';
670
- throw IllegalArgumentException_init_$Create$(toString(message));
671
- }
672
- return get_entries_0().h1(number - 1 | 0);
673
- }
674
- function Month_JANUARY_getInstance() {
675
- Month_initEntries();
676
- return Month_JANUARY_instance;
677
- }
678
- function Month_FEBRUARY_getInstance() {
679
- Month_initEntries();
680
- return Month_FEBRUARY_instance;
681
- }
682
- function Month_MARCH_getInstance() {
683
- Month_initEntries();
684
- return Month_MARCH_instance;
685
- }
686
- function Month_APRIL_getInstance() {
687
- Month_initEntries();
688
- return Month_APRIL_instance;
689
- }
690
- function Month_MAY_getInstance() {
691
- Month_initEntries();
692
- return Month_MAY_instance;
693
- }
694
- function Month_JUNE_getInstance() {
695
- Month_initEntries();
696
- return Month_JUNE_instance;
697
- }
698
- function Month_JULY_getInstance() {
699
- Month_initEntries();
700
- return Month_JULY_instance;
701
- }
702
- function Month_AUGUST_getInstance() {
703
- Month_initEntries();
704
- return Month_AUGUST_instance;
705
- }
706
- function Month_SEPTEMBER_getInstance() {
707
- Month_initEntries();
708
- return Month_SEPTEMBER_instance;
709
- }
710
- function Month_OCTOBER_getInstance() {
711
- Month_initEntries();
712
- return Month_OCTOBER_instance;
713
- }
714
- function Month_NOVEMBER_getInstance() {
715
- Month_initEntries();
716
- return Month_NOVEMBER_instance;
717
- }
718
- function Month_DECEMBER_getInstance() {
719
- Month_initEntries();
720
- return Month_DECEMBER_instance;
721
- }
722
- function AbstractDateTimeFormat() {
723
- }
724
- protoOf(AbstractDateTimeFormat).o54 = function (value) {
725
- // Inline function 'kotlin.also' call
726
- var this_0 = StringBuilder_init_$Create$();
727
- this.p54().w54().x54(this.q54(value), this_0);
728
- return this_0.toString();
729
- };
730
- protoOf(AbstractDateTimeFormat).al = function (input) {
731
- var tmp;
732
- try {
733
- tmp = Parser__match$default_impl_x2xlti(_Parser___init__impl__gdyfby(this.p54().y54()), input, this.s54());
734
- } catch ($p) {
735
- var tmp_0;
736
- if ($p instanceof ParseException) {
737
- var e = $p;
738
- throw DateTimeFormatException_init_$Create$_1("Failed to parse value from '" + toString(input) + "'", e);
739
- } else {
740
- throw $p;
741
- }
742
- }
743
- var matched = tmp;
744
- try {
745
- return this.r54(matched);
746
- } catch ($p) {
747
- if ($p instanceof IllegalArgumentException) {
748
- var e_0 = $p;
749
- var message = e_0.message;
750
- throw DateTimeFormatException_init_$Create$_1(message == null ? "The value parsed from '" + toString(input) + "' is invalid" : '' + message + " (when parsing '" + toString(input) + "')", e_0);
751
- } else {
752
- throw $p;
753
- }
754
- }
755
- };
756
- var Padding_NONE_instance;
757
- var Padding_ZERO_instance;
758
- var Padding_SPACE_instance;
759
- var Padding_entriesInitialized;
760
- function Padding_initEntries() {
761
- if (Padding_entriesInitialized)
762
- return Unit_instance;
763
- Padding_entriesInitialized = true;
764
- Padding_NONE_instance = new Padding('NONE', 0);
765
- Padding_ZERO_instance = new Padding('ZERO', 1);
766
- Padding_SPACE_instance = new Padding('SPACE', 2);
767
- }
768
- function Padding(name, ordinal) {
769
- Enum.call(this, name, ordinal);
770
- }
771
- function Padding_ZERO_getInstance() {
772
- Padding_initEntries();
773
- return Padding_ZERO_instance;
774
- }
775
- function Padding_SPACE_getInstance() {
776
- Padding_initEntries();
777
- return Padding_SPACE_instance;
778
- }
779
- function WithYearMonth() {
780
- }
781
- function WithDate() {
782
- }
783
- function char(_this__u8e3s4, value) {
784
- return _this__u8e3s4.d55(toString_0(value));
785
- }
786
- function AbstractDateTimeFormatBuilder() {
787
- }
788
- function get_ISO_DATE() {
789
- _init_properties_LocalDateFormat_kt__k1uk9u();
790
- var tmp0 = ISO_DATE$delegate;
791
- var tmp = KProperty0;
792
- // Inline function 'kotlin.getValue' call
793
- getPropertyCallableRef('ISO_DATE', 0, tmp, _get_ISO_DATE_$ref_powsum(), null);
794
- return tmp0.m1();
795
- }
796
- var ISO_DATE$delegate;
797
- function get_ISO_DATE_BASIC() {
798
- _init_properties_LocalDateFormat_kt__k1uk9u();
799
- var tmp0 = ISO_DATE_BASIC$delegate;
800
- var tmp = KProperty0;
801
- // Inline function 'kotlin.getValue' call
802
- getPropertyCallableRef('ISO_DATE_BASIC', 0, tmp, _get_ISO_DATE_BASIC_$ref_3fs8eb(), null);
803
- return tmp0.m1();
804
- }
805
- var ISO_DATE_BASIC$delegate;
806
- function get_emptyIncompleteLocalDate() {
807
- _init_properties_LocalDateFormat_kt__k1uk9u();
808
- return emptyIncompleteLocalDate;
809
- }
810
- var emptyIncompleteLocalDate;
811
- function IncompleteLocalDate(yearMonth, day, dayOfWeek, dayOfYear) {
812
- yearMonth = yearMonth === VOID ? new IncompleteYearMonth() : yearMonth;
813
- day = day === VOID ? null : day;
814
- dayOfWeek = dayOfWeek === VOID ? null : dayOfWeek;
815
- dayOfYear = dayOfYear === VOID ? null : dayOfYear;
816
- this.k55_1 = yearMonth;
817
- this.l55_1 = day;
818
- this.m55_1 = dayOfWeek;
819
- this.n55_1 = dayOfYear;
820
- }
821
- protoOf(IncompleteLocalDate).o55 = function (_set____db54di) {
822
- this.l55_1 = _set____db54di;
823
- };
824
- protoOf(IncompleteLocalDate).p55 = function () {
825
- return this.l55_1;
826
- };
827
- protoOf(IncompleteLocalDate).q55 = function (_set____db54di) {
828
- this.m55_1 = _set____db54di;
829
- };
830
- protoOf(IncompleteLocalDate).r55 = function () {
831
- return this.m55_1;
832
- };
833
- protoOf(IncompleteLocalDate).s55 = function (_set____db54di) {
834
- this.n55_1 = _set____db54di;
835
- };
836
- protoOf(IncompleteLocalDate).t55 = function () {
837
- return this.n55_1;
838
- };
839
- protoOf(IncompleteLocalDate).u55 = function () {
840
- var year = requireParsedField(this.v55(), 'year');
841
- var dayOfYear = this.n55_1;
842
- var tmp;
843
- if (dayOfYear == null) {
844
- tmp = new LocalDate(year, requireParsedField(this.a56(), 'monthNumber'), requireParsedField(this.l55_1, 'day'));
845
- } else {
846
- // Inline function 'kotlin.also' call
847
- var this_0 = plus_0(new LocalDate(year, 1, 1), dayOfYear - 1 | 0, Companion_getInstance_3().g54_1);
848
- if (!(this_0.w55_1 === year)) {
849
- throw DateTimeFormatException_init_$Create$_0('Can not create a LocalDate from the given input: ' + ('the day of year is ' + dayOfYear + ', which is not a valid day of year for the year ' + year));
850
- }
851
- if (!(this.a56() == null) && !(get_number(this_0.z55()) === this.a56())) {
852
- throw DateTimeFormatException_init_$Create$_0('Can not create a LocalDate from the given input: ' + ('the day of year is ' + dayOfYear + ', which is ' + this_0.z55().toString() + ', ') + ('but ' + this.a56() + ' was specified as the month number'));
853
- }
854
- if (!(this.l55_1 == null) && !(this_0.x55_1 === this.l55_1)) {
855
- throw DateTimeFormatException_init_$Create$_0('Can not create a LocalDate from the given input: ' + ('the day of year is ' + dayOfYear + ', which is the day ' + this_0.x55_1 + ' of ' + this_0.z55().toString() + ', ') + ('but ' + this.l55_1 + ' was specified as the day of month'));
856
- }
857
- tmp = this_0;
858
- }
859
- var date = tmp;
860
- var tmp0_safe_receiver = this.m55_1;
861
- if (tmp0_safe_receiver == null)
862
- null;
863
- else {
864
- // Inline function 'kotlin.let' call
865
- if (!(tmp0_safe_receiver === get_isoDayNumber(date.r55()))) {
866
- throw DateTimeFormatException_init_$Create$_0('Can not create a LocalDate from the given input: ' + ('the day of week is ' + DayOfWeek_0(tmp0_safe_receiver).toString() + ' but the date is ' + date.toString() + ', which is a ' + date.r55().toString()));
867
- }
868
- }
869
- return date;
870
- };
871
- protoOf(IncompleteLocalDate).b56 = function (date) {
872
- this.c56(date.w55_1);
873
- this.d56(get_number(date.z55()));
874
- this.l55_1 = date.x55_1;
875
- this.m55_1 = get_isoDayNumber(date.r55());
876
- this.n55_1 = date.t55();
877
- };
878
- protoOf(IncompleteLocalDate).e56 = function () {
879
- return new IncompleteLocalDate(this.k55_1.e56(), this.l55_1, this.m55_1, this.n55_1);
880
- };
881
- protoOf(IncompleteLocalDate).equals = function (other) {
882
- var tmp;
883
- var tmp_0;
884
- var tmp_1;
885
- var tmp_2;
886
- if (other instanceof IncompleteLocalDate) {
887
- tmp_2 = this.k55_1.equals(other.k55_1);
888
- } else {
889
- tmp_2 = false;
890
- }
891
- if (tmp_2) {
892
- tmp_1 = this.l55_1 == other.l55_1;
893
- } else {
894
- tmp_1 = false;
895
- }
896
- if (tmp_1) {
897
- tmp_0 = this.m55_1 == other.m55_1;
898
- } else {
899
- tmp_0 = false;
900
- }
901
- if (tmp_0) {
902
- tmp = this.n55_1 == other.n55_1;
903
- } else {
904
- tmp = false;
905
- }
906
- return tmp;
907
- };
908
- protoOf(IncompleteLocalDate).hashCode = function () {
909
- var tmp = imul(this.k55_1.hashCode(), 29791);
910
- // Inline function 'kotlin.hashCode' call
911
- var tmp0_safe_receiver = this.l55_1;
912
- var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : hashCode(tmp0_safe_receiver);
913
- var tmp$ret$0 = tmp1_elvis_lhs == null ? 0 : tmp1_elvis_lhs;
914
- var tmp_0 = tmp + imul(tmp$ret$0, 961) | 0;
915
- // Inline function 'kotlin.hashCode' call
916
- var tmp0_safe_receiver_0 = this.m55_1;
917
- var tmp1_elvis_lhs_0 = tmp0_safe_receiver_0 == null ? null : hashCode(tmp0_safe_receiver_0);
918
- var tmp$ret$1 = tmp1_elvis_lhs_0 == null ? 0 : tmp1_elvis_lhs_0;
919
- var tmp_1 = tmp_0 + imul(tmp$ret$1, 31) | 0;
920
- // Inline function 'kotlin.hashCode' call
921
- var tmp0_safe_receiver_1 = this.n55_1;
922
- var tmp1_elvis_lhs_1 = tmp0_safe_receiver_1 == null ? null : hashCode(tmp0_safe_receiver_1);
923
- return tmp_1 + (tmp1_elvis_lhs_1 == null ? 0 : tmp1_elvis_lhs_1) | 0;
924
- };
925
- protoOf(IncompleteLocalDate).toString = function () {
926
- var tmp;
927
- if (this.n55_1 == null) {
928
- var tmp_0 = this.k55_1.toString();
929
- var tmp0_elvis_lhs = this.l55_1;
930
- var tmp_1 = toString(tmp0_elvis_lhs == null ? '??' : tmp0_elvis_lhs);
931
- var tmp1_elvis_lhs = this.m55_1;
932
- tmp = tmp_0 + '-' + tmp_1 + ' (day of week is ' + toString(tmp1_elvis_lhs == null ? '??' : tmp1_elvis_lhs) + ')';
933
- } else if (this.l55_1 == null && this.a56() == null) {
934
- var tmp2_elvis_lhs = this.k55_1.f56_1;
935
- var tmp_2 = toString(tmp2_elvis_lhs == null ? '??' : tmp2_elvis_lhs);
936
- var tmp_3 = this.n55_1;
937
- var tmp3_elvis_lhs = this.m55_1;
938
- tmp = '(' + tmp_2 + ')-' + tmp_3 + ' (day of week is ' + toString(tmp3_elvis_lhs == null ? '??' : tmp3_elvis_lhs) + ')';
939
- } else {
940
- var tmp_4 = this.k55_1.toString();
941
- var tmp4_elvis_lhs = this.l55_1;
942
- var tmp_5 = toString(tmp4_elvis_lhs == null ? '??' : tmp4_elvis_lhs);
943
- var tmp5_elvis_lhs = this.m55_1;
944
- tmp = tmp_4 + '-' + tmp_5 + ' (day of week is ' + toString(tmp5_elvis_lhs == null ? '??' : tmp5_elvis_lhs) + ', day of year is ' + this.n55_1 + ')';
945
- }
946
- return tmp;
947
- };
948
- protoOf(IncompleteLocalDate).c56 = function (_set____db54di) {
949
- this.k55_1.f56_1 = _set____db54di;
950
- };
951
- protoOf(IncompleteLocalDate).v55 = function () {
952
- return this.k55_1.f56_1;
953
- };
954
- protoOf(IncompleteLocalDate).d56 = function (_set____db54di) {
955
- this.k55_1.g56_1 = _set____db54di;
956
- };
957
- protoOf(IncompleteLocalDate).a56 = function () {
958
- return this.k55_1.g56_1;
959
- };
960
- function Companion_4() {
961
- }
962
- protoOf(Companion_4).h56 = function (block) {
963
- var builder = new Builder(new AppendableFormatStructure());
964
- block(builder);
965
- return new LocalDateFormat(builder.i2l());
966
- };
967
- var Companion_instance_4;
968
- function Companion_getInstance_4() {
969
- return Companion_instance_4;
970
- }
971
- function Builder(actualBuilder) {
972
- this.i56_1 = actualBuilder;
973
- }
974
- protoOf(Builder).g55 = function () {
975
- return this.i56_1;
976
- };
977
- protoOf(Builder).j56 = function (structure) {
978
- return this.i56_1.i55(structure);
979
- };
980
- function LocalDateFormat(actualFormat) {
981
- AbstractDateTimeFormat.call(this);
982
- this.l56_1 = actualFormat;
983
- }
984
- protoOf(LocalDateFormat).p54 = function () {
985
- return this.l56_1;
986
- };
987
- protoOf(LocalDateFormat).m56 = function (value) {
988
- // Inline function 'kotlin.apply' call
989
- var this_0 = new IncompleteLocalDate();
990
- this_0.b56(value);
991
- return this_0;
992
- };
993
- protoOf(LocalDateFormat).q54 = function (value) {
994
- return this.m56(value instanceof LocalDate ? value : THROW_CCE());
995
- };
996
- protoOf(LocalDateFormat).n56 = function (intermediate) {
997
- return intermediate.u55();
998
- };
999
- protoOf(LocalDateFormat).r54 = function (intermediate) {
1000
- return this.n56(intermediate instanceof IncompleteLocalDate ? intermediate : THROW_CCE());
1001
- };
1002
- protoOf(LocalDateFormat).s54 = function () {
1003
- return get_emptyIncompleteLocalDate();
1004
- };
1005
- function AbstractWithDateBuilder() {
1006
- }
1007
- function DayDirective(padding) {
1008
- var tmp = DateFields_getInstance().o56_1;
1009
- // Inline function 'kotlinx.datetime.format.minDigits' call
1010
- var tmp_0 = padding.equals(Padding_ZERO_getInstance()) ? 2 : 1;
1011
- // Inline function 'kotlinx.datetime.format.spaces' call
1012
- var tmp$ret$1 = padding.equals(Padding_SPACE_getInstance()) ? 2 : null;
1013
- UnsignedIntFieldFormatDirective.call(this, tmp, tmp_0, tmp$ret$1);
1014
- this.v56_1 = padding;
1015
- }
1016
- protoOf(DayDirective).equals = function (other) {
1017
- var tmp;
1018
- if (other instanceof DayDirective) {
1019
- tmp = this.v56_1.equals(other.v56_1);
1020
- } else {
1021
- tmp = false;
1022
- }
1023
- return tmp;
1024
- };
1025
- protoOf(DayDirective).hashCode = function () {
1026
- return this.v56_1.hashCode();
1027
- };
1028
- function DateFieldContainer$_get_day_$ref_2ebhxx() {
1029
- return function (p0) {
1030
- return p0.p55();
1031
- };
1032
- }
1033
- function DateFieldContainer$_set_day_$ref_s0jsax() {
1034
- return function (p0, p1) {
1035
- p0.o55(p1);
1036
- return Unit_instance;
1037
- };
1038
- }
1039
- function DateFieldContainer$_get_dayOfWeek_$ref_thwqom() {
1040
- return function (p0) {
1041
- return p0.r55();
1042
- };
1043
- }
1044
- function DateFieldContainer$_set_dayOfWeek_$ref_ea586a() {
1045
- return function (p0, p1) {
1046
- p0.q55(p1);
1047
- return Unit_instance;
1048
- };
1049
- }
1050
- function DateFieldContainer$_get_dayOfYear_$ref_2m6gfz() {
1051
- return function (p0) {
1052
- return p0.t55();
1053
- };
1054
- }
1055
- function DateFieldContainer$_set_dayOfYear_$ref_cll22d() {
1056
- return function (p0, p1) {
1057
- p0.s55(p1);
1058
- return Unit_instance;
1059
- };
1060
- }
1061
- function DateFields() {
1062
- DateFields_instance = this;
1063
- var tmp = this;
1064
- var tmp_0 = KMutableProperty1;
1065
- var tmp_1 = DateFieldContainer$_get_day_$ref_2ebhxx();
1066
- tmp.o56_1 = new UnsignedFieldSpec(new PropertyAccessor(getPropertyCallableRef('day', 1, tmp_0, tmp_1, DateFieldContainer$_set_day_$ref_s0jsax())), 1, 31);
1067
- var tmp_2 = this;
1068
- var tmp_3 = KMutableProperty1;
1069
- var tmp_4 = DateFieldContainer$_get_dayOfWeek_$ref_thwqom();
1070
- tmp_2.p56_1 = new UnsignedFieldSpec(new PropertyAccessor(getPropertyCallableRef('dayOfWeek', 1, tmp_3, tmp_4, DateFieldContainer$_set_dayOfWeek_$ref_ea586a())), 1, 7);
1071
- var tmp_5 = this;
1072
- var tmp_6 = KMutableProperty1;
1073
- var tmp_7 = DateFieldContainer$_get_dayOfYear_$ref_2m6gfz();
1074
- tmp_5.q56_1 = new UnsignedFieldSpec(new PropertyAccessor(getPropertyCallableRef('dayOfYear', 1, tmp_6, tmp_7, DateFieldContainer$_set_dayOfYear_$ref_cll22d())), 1, 366);
1075
- }
1076
- var DateFields_instance;
1077
- function DateFields_getInstance() {
1078
- if (DateFields_instance == null)
1079
- new DateFields();
1080
- return DateFields_instance;
1081
- }
1082
- function ISO_DATE$delegate$lambda() {
1083
- _init_properties_LocalDateFormat_kt__k1uk9u();
1084
- var tmp = Companion_instance_4;
1085
- return tmp.h56(ISO_DATE$delegate$lambda$lambda);
1086
- }
1087
- function ISO_DATE$delegate$lambda$lambda($this$build) {
1088
- _init_properties_LocalDateFormat_kt__k1uk9u();
1089
- $this$build.a55();
1090
- char($this$build, _Char___init__impl__6a9atx(45));
1091
- $this$build.c55();
1092
- char($this$build, _Char___init__impl__6a9atx(45));
1093
- $this$build.f55();
1094
- return Unit_instance;
1095
- }
1096
- function _get_ISO_DATE_$ref_powsum() {
1097
- return function () {
1098
- return get_ISO_DATE();
1099
- };
1100
- }
1101
- function ISO_DATE_BASIC$delegate$lambda() {
1102
- _init_properties_LocalDateFormat_kt__k1uk9u();
1103
- var tmp = Companion_instance_4;
1104
- return tmp.h56(ISO_DATE_BASIC$delegate$lambda$lambda);
1105
- }
1106
- function ISO_DATE_BASIC$delegate$lambda$lambda($this$build) {
1107
- _init_properties_LocalDateFormat_kt__k1uk9u();
1108
- $this$build.a55();
1109
- $this$build.c55();
1110
- $this$build.f55();
1111
- return Unit_instance;
1112
- }
1113
- function _get_ISO_DATE_BASIC_$ref_3fs8eb() {
1114
- return function () {
1115
- return get_ISO_DATE_BASIC();
1116
- };
1117
- }
1118
- var properties_initialized_LocalDateFormat_kt_fmnlhc;
1119
- function _init_properties_LocalDateFormat_kt__k1uk9u() {
1120
- if (!properties_initialized_LocalDateFormat_kt_fmnlhc) {
1121
- properties_initialized_LocalDateFormat_kt_fmnlhc = true;
1122
- ISO_DATE$delegate = lazy(ISO_DATE$delegate$lambda);
1123
- ISO_DATE_BASIC$delegate = lazy(ISO_DATE_BASIC$delegate$lambda);
1124
- emptyIncompleteLocalDate = new IncompleteLocalDate();
1125
- }
1126
- }
1127
- function get_emptyIncompleteYearMonth() {
1128
- _init_properties_YearMonthFormat_kt__i0mmu0();
1129
- return emptyIncompleteYearMonth;
1130
- }
1131
- var emptyIncompleteYearMonth;
1132
- function get_ISO_YEAR_MONTH() {
1133
- _init_properties_YearMonthFormat_kt__i0mmu0();
1134
- var tmp0 = ISO_YEAR_MONTH$delegate;
1135
- var tmp = KProperty0;
1136
- // Inline function 'kotlin.getValue' call
1137
- getPropertyCallableRef('ISO_YEAR_MONTH', 0, tmp, _get_ISO_YEAR_MONTH_$ref_y3tv9a(), null);
1138
- return tmp0.m1();
1139
- }
1140
- var ISO_YEAR_MONTH$delegate;
1141
- function IncompleteYearMonth(year, monthNumber) {
1142
- year = year === VOID ? null : year;
1143
- monthNumber = monthNumber === VOID ? null : monthNumber;
1144
- this.f56_1 = year;
1145
- this.g56_1 = monthNumber;
1146
- }
1147
- protoOf(IncompleteYearMonth).c56 = function (_set____db54di) {
1148
- this.f56_1 = _set____db54di;
1149
- };
1150
- protoOf(IncompleteYearMonth).v55 = function () {
1151
- return this.f56_1;
1152
- };
1153
- protoOf(IncompleteYearMonth).d56 = function (_set____db54di) {
1154
- this.g56_1 = _set____db54di;
1155
- };
1156
- protoOf(IncompleteYearMonth).a56 = function () {
1157
- return this.g56_1;
1158
- };
1159
- protoOf(IncompleteYearMonth).a57 = function () {
1160
- var year = requireParsedField(this.f56_1, 'year');
1161
- var month = requireParsedField(this.g56_1, 'monthNumber');
1162
- return new YearMonth(year, month);
1163
- };
1164
- protoOf(IncompleteYearMonth).b57 = function (yearMonth) {
1165
- this.f56_1 = yearMonth.c57_1;
1166
- this.g56_1 = get_number(yearMonth.z55());
1167
- };
1168
- protoOf(IncompleteYearMonth).e56 = function () {
1169
- return new IncompleteYearMonth(this.f56_1, this.g56_1);
1170
- };
1171
- protoOf(IncompleteYearMonth).equals = function (other) {
1172
- var tmp;
1173
- var tmp_0;
1174
- if (other instanceof IncompleteYearMonth) {
1175
- tmp_0 = this.f56_1 == other.f56_1;
1176
- } else {
1177
- tmp_0 = false;
1178
- }
1179
- if (tmp_0) {
1180
- tmp = this.g56_1 == other.g56_1;
1181
- } else {
1182
- tmp = false;
1183
- }
1184
- return tmp;
1185
- };
1186
- protoOf(IncompleteYearMonth).hashCode = function () {
1187
- // Inline function 'kotlin.hashCode' call
1188
- var tmp0_safe_receiver = this.f56_1;
1189
- var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : hashCode(tmp0_safe_receiver);
1190
- var tmp$ret$0 = tmp1_elvis_lhs == null ? 0 : tmp1_elvis_lhs;
1191
- var tmp = imul(tmp$ret$0, 31);
1192
- // Inline function 'kotlin.hashCode' call
1193
- var tmp0_safe_receiver_0 = this.g56_1;
1194
- var tmp1_elvis_lhs_0 = tmp0_safe_receiver_0 == null ? null : hashCode(tmp0_safe_receiver_0);
1195
- return tmp + (tmp1_elvis_lhs_0 == null ? 0 : tmp1_elvis_lhs_0) | 0;
1196
- };
1197
- protoOf(IncompleteYearMonth).toString = function () {
1198
- var tmp0_elvis_lhs = this.f56_1;
1199
- var tmp = toString(tmp0_elvis_lhs == null ? '??' : tmp0_elvis_lhs);
1200
- var tmp1_elvis_lhs = this.g56_1;
1201
- return tmp + '-' + toString(tmp1_elvis_lhs == null ? '??' : tmp1_elvis_lhs);
1202
- };
1203
- function requireParsedField(field, name) {
1204
- _init_properties_YearMonthFormat_kt__i0mmu0();
1205
- if (field == null) {
1206
- throw DateTimeFormatException_init_$Create$_0('Can not create a ' + name + ' from the given input: the field ' + name + ' is missing');
1207
- }
1208
- return field;
1209
- }
1210
- function AbstractWithYearMonthBuilder() {
1211
- }
1212
- function Companion_5() {
1213
- }
1214
- protoOf(Companion_5).e57 = function (block) {
1215
- var builder = new Builder_0(new AppendableFormatStructure());
1216
- block(builder);
1217
- return new YearMonthFormat(builder.i2l());
1218
- };
1219
- var Companion_instance_5;
1220
- function Companion_getInstance_5() {
1221
- return Companion_instance_5;
1222
- }
1223
- function Builder_0(actualBuilder) {
1224
- this.f57_1 = actualBuilder;
1225
- }
1226
- protoOf(Builder_0).g55 = function () {
1227
- return this.f57_1;
1228
- };
1229
- protoOf(Builder_0).k56 = function (structure) {
1230
- return this.f57_1.i55(structure);
1231
- };
1232
- function YearMonthFormat(actualFormat) {
1233
- AbstractDateTimeFormat.call(this);
1234
- this.g57_1 = actualFormat;
1235
- }
1236
- protoOf(YearMonthFormat).p54 = function () {
1237
- return this.g57_1;
1238
- };
1239
- protoOf(YearMonthFormat).h57 = function (value) {
1240
- // Inline function 'kotlin.apply' call
1241
- var this_0 = new IncompleteYearMonth();
1242
- this_0.b57(value);
1243
- return this_0;
1244
- };
1245
- protoOf(YearMonthFormat).q54 = function (value) {
1246
- return this.h57(value instanceof YearMonth ? value : THROW_CCE());
1247
- };
1248
- protoOf(YearMonthFormat).i57 = function (intermediate) {
1249
- return intermediate.a57();
1250
- };
1251
- protoOf(YearMonthFormat).r54 = function (intermediate) {
1252
- return this.i57(intermediate instanceof IncompleteYearMonth ? intermediate : THROW_CCE());
1253
- };
1254
- protoOf(YearMonthFormat).s54 = function () {
1255
- return get_emptyIncompleteYearMonth();
1256
- };
1257
- function YearDirective(padding, isYearOfEra) {
1258
- isYearOfEra = isYearOfEra === VOID ? false : isYearOfEra;
1259
- var tmp = YearMonthFields_getInstance().j57_1;
1260
- // Inline function 'kotlinx.datetime.format.minDigits' call
1261
- var tmp_0 = padding.equals(Padding_ZERO_getInstance()) ? 4 : 1;
1262
- // Inline function 'kotlinx.datetime.format.spaces' call
1263
- var tmp$ret$1 = padding.equals(Padding_SPACE_getInstance()) ? 4 : null;
1264
- SignedIntFieldFormatDirective.call(this, tmp, tmp_0, null, tmp$ret$1, 4);
1265
- this.q57_1 = padding;
1266
- this.r57_1 = isYearOfEra;
1267
- }
1268
- protoOf(YearDirective).equals = function (other) {
1269
- var tmp;
1270
- var tmp_0;
1271
- if (other instanceof YearDirective) {
1272
- tmp_0 = this.q57_1.equals(other.q57_1);
1273
- } else {
1274
- tmp_0 = false;
1275
- }
1276
- if (tmp_0) {
1277
- tmp = this.r57_1 === other.r57_1;
1278
- } else {
1279
- tmp = false;
1280
- }
1281
- return tmp;
1282
- };
1283
- protoOf(YearDirective).hashCode = function () {
1284
- return imul(this.q57_1.hashCode(), 31) + getBooleanHashCode(this.r57_1) | 0;
1285
- };
1286
- function MonthDirective(padding) {
1287
- var tmp = YearMonthFields_getInstance().k57_1;
1288
- // Inline function 'kotlinx.datetime.format.minDigits' call
1289
- var tmp_0 = padding.equals(Padding_ZERO_getInstance()) ? 2 : 1;
1290
- // Inline function 'kotlinx.datetime.format.spaces' call
1291
- var tmp$ret$1 = padding.equals(Padding_SPACE_getInstance()) ? 2 : null;
1292
- UnsignedIntFieldFormatDirective.call(this, tmp, tmp_0, tmp$ret$1);
1293
- this.b58_1 = padding;
1294
- }
1295
- protoOf(MonthDirective).equals = function (other) {
1296
- var tmp;
1297
- if (other instanceof MonthDirective) {
1298
- tmp = this.b58_1.equals(other.b58_1);
1299
- } else {
1300
- tmp = false;
1301
- }
1302
- return tmp;
1303
- };
1304
- protoOf(MonthDirective).hashCode = function () {
1305
- return this.b58_1.hashCode();
1306
- };
1307
- function YearMonthFieldContainer$_get_year_$ref_7j3zdj() {
1308
- return function (p0) {
1309
- return p0.v55();
1310
- };
1311
- }
1312
- function YearMonthFieldContainer$_set_year_$ref_kc0aub() {
1313
- return function (p0, p1) {
1314
- p0.c56(p1);
1315
- return Unit_instance;
1316
- };
1317
- }
1318
- function YearMonthFieldContainer$_get_monthNumber_$ref_pn0wu5() {
1319
- return function (p0) {
1320
- return p0.a56();
1321
- };
1322
- }
1323
- function YearMonthFieldContainer$_set_monthNumber_$ref_fjapbl() {
1324
- return function (p0, p1) {
1325
- p0.d56(p1);
1326
- return Unit_instance;
1327
- };
1328
- }
1329
- function YearMonthFields() {
1330
- YearMonthFields_instance = this;
1331
- var tmp = this;
1332
- var tmp_0 = KMutableProperty1;
1333
- var tmp_1 = YearMonthFieldContainer$_get_year_$ref_7j3zdj();
1334
- tmp.j57_1 = new GenericFieldSpec(new PropertyAccessor(getPropertyCallableRef('year', 1, tmp_0, tmp_1, YearMonthFieldContainer$_set_year_$ref_kc0aub())));
1335
- var tmp_2 = this;
1336
- var tmp_3 = KMutableProperty1;
1337
- var tmp_4 = YearMonthFieldContainer$_get_monthNumber_$ref_pn0wu5();
1338
- tmp_2.k57_1 = new UnsignedFieldSpec(new PropertyAccessor(getPropertyCallableRef('monthNumber', 1, tmp_3, tmp_4, YearMonthFieldContainer$_set_monthNumber_$ref_fjapbl())), 1, 12);
1339
- }
1340
- var YearMonthFields_instance;
1341
- function YearMonthFields_getInstance() {
1342
- if (YearMonthFields_instance == null)
1343
- new YearMonthFields();
1344
- return YearMonthFields_instance;
1345
- }
1346
- function ISO_YEAR_MONTH$delegate$lambda() {
1347
- _init_properties_YearMonthFormat_kt__i0mmu0();
1348
- var tmp = Companion_instance_5;
1349
- return tmp.e57(ISO_YEAR_MONTH$delegate$lambda$lambda);
1350
- }
1351
- function ISO_YEAR_MONTH$delegate$lambda$lambda($this$build) {
1352
- _init_properties_YearMonthFormat_kt__i0mmu0();
1353
- $this$build.a55();
1354
- char($this$build, _Char___init__impl__6a9atx(45));
1355
- $this$build.c55();
1356
- return Unit_instance;
1357
- }
1358
- function _get_ISO_YEAR_MONTH_$ref_y3tv9a() {
1359
- return function () {
1360
- return get_ISO_YEAR_MONTH();
1361
- };
1362
- }
1363
- var properties_initialized_YearMonthFormat_kt_fp0mk6;
1364
- function _init_properties_YearMonthFormat_kt__i0mmu0() {
1365
- if (!properties_initialized_YearMonthFormat_kt_fp0mk6) {
1366
- properties_initialized_YearMonthFormat_kt_fp0mk6 = true;
1367
- emptyIncompleteYearMonth = new IncompleteYearMonth();
1368
- ISO_YEAR_MONTH$delegate = lazy(ISO_YEAR_MONTH$delegate$lambda);
1369
- }
1370
- }
1371
- function monthLength(_this__u8e3s4, isLeapYear) {
1372
- switch (_this__u8e3s4) {
1373
- case 2:
1374
- return isLeapYear ? 29 : 28;
1375
- case 4:
1376
- case 6:
1377
- case 9:
1378
- case 11:
1379
- return 30;
1380
- default:
1381
- return 31;
1382
- }
1383
- }
1384
- function isLeapYear(year) {
1385
- var prolepticYear = fromInt(year);
1386
- var tmp;
1387
- if ((prolepticYear & 3n) === 0n) {
1388
- var tmp_0;
1389
- // Inline function 'kotlin.Long.rem' call
1390
- if (!(modulo(prolepticYear, fromInt(100)) === 0n)) {
1391
- tmp_0 = true;
1392
- } else {
1393
- // Inline function 'kotlin.Long.rem' call
1394
- tmp_0 = modulo(prolepticYear, fromInt(400)) === 0n;
1395
- }
1396
- tmp = tmp_0;
1397
- } else {
1398
- tmp = false;
1399
- }
1400
- return tmp;
1401
- }
1402
- function AppendableFormatStructure() {
1403
- var tmp = this;
1404
- // Inline function 'kotlin.collections.mutableListOf' call
1405
- tmp.h55_1 = ArrayList_init_$Create$();
1406
- }
1407
- protoOf(AppendableFormatStructure).i2l = function () {
1408
- return new ConcatenatedFormatStructure(this.h55_1);
1409
- };
1410
- protoOf(AppendableFormatStructure).i55 = function (format) {
1411
- if (isInterface(format, NonConcatenatedFormatStructure))
1412
- this.h55_1.e1(format);
1413
- else {
1414
- if (format instanceof ConcatenatedFormatStructure) {
1415
- // Inline function 'kotlin.collections.forEach' call
1416
- var _iterator__ex2g4s = format.j55_1.t();
1417
- while (_iterator__ex2g4s.u()) {
1418
- var element = _iterator__ex2g4s.v();
1419
- this.h55_1.e1(element);
1420
- }
1421
- } else {
1422
- noWhenBranchMatchedException();
1423
- }
1424
- }
1425
- };
1426
- function Accessor$getterNotNull$ref(p0) {
1427
- var l = function (_this__u8e3s4) {
1428
- return p0.c58(_this__u8e3s4);
1429
- };
1430
- l.callableName = 'getterNotNull';
1431
- return l;
1432
- }
1433
- function UnsignedIntFieldFormatDirective(field, minDigits, spacePadding) {
1434
- this.w56_1 = field;
1435
- this.x56_1 = minDigits;
1436
- this.y56_1 = spacePadding;
1437
- this.z56_1 = this.w56_1.j58_1;
1438
- // Inline function 'kotlin.require' call
1439
- if (!(this.x56_1 >= 0)) {
1440
- var message = 'The minimum number of digits (' + this.x56_1 + ') is negative';
1441
- throw IllegalArgumentException_init_$Create$(toString(message));
1442
- }
1443
- // Inline function 'kotlin.require' call
1444
- if (!(this.z56_1 >= this.x56_1)) {
1445
- var message_0 = 'The maximum number of digits (' + this.z56_1 + ') is less than the minimum number of digits (' + this.x56_1 + ')';
1446
- throw IllegalArgumentException_init_$Create$(toString(message_0));
1447
- }
1448
- if (!(this.y56_1 == null)) {
1449
- // Inline function 'kotlin.require' call
1450
- if (!(this.y56_1 > this.x56_1)) {
1451
- var message_1 = 'The space padding (' + this.y56_1 + ') should be more than the minimum number of digits (' + this.x56_1 + ')';
1452
- throw IllegalArgumentException_init_$Create$(toString(message_1));
1453
- }
1454
- }
1455
- }
1456
- protoOf(UnsignedIntFieldFormatDirective).w54 = function () {
1457
- var formatter = new UnsignedIntFormatterStructure(Accessor$getterNotNull$ref(this.w56_1.d58_1), this.x56_1);
1458
- return !(this.y56_1 == null) ? new SpacePaddedFormatter(formatter, this.y56_1) : formatter;
1459
- };
1460
- protoOf(UnsignedIntFieldFormatDirective).y54 = function () {
1461
- return spaceAndZeroPaddedUnsignedInt(this.x56_1, this.z56_1, this.y56_1, this.w56_1.d58_1, this.w56_1.g58_1);
1462
- };
1463
- function Accessor$getterNotNull$ref_0(p0) {
1464
- var l = function (_this__u8e3s4) {
1465
- return p0.c58(_this__u8e3s4);
1466
- };
1467
- l.callableName = 'getterNotNull';
1468
- return l;
1469
- }
1470
- function SignedIntFieldFormatDirective(field, minDigits, maxDigits, spacePadding, outputPlusOnExceededWidth) {
1471
- this.s57_1 = field;
1472
- this.t57_1 = minDigits;
1473
- this.u57_1 = maxDigits;
1474
- this.v57_1 = spacePadding;
1475
- this.w57_1 = outputPlusOnExceededWidth;
1476
- // Inline function 'kotlin.require' call
1477
- if (!(this.t57_1 == null || this.t57_1 >= 0)) {
1478
- var message = 'The minimum number of digits (' + this.t57_1 + ') is negative';
1479
- throw IllegalArgumentException_init_$Create$(toString(message));
1480
- }
1481
- // Inline function 'kotlin.require' call
1482
- if (!(this.u57_1 == null || this.t57_1 == null || this.u57_1 >= this.t57_1)) {
1483
- var message_0 = 'The maximum number of digits (' + this.u57_1 + ') is less than the minimum number of digits (' + this.t57_1 + ')';
1484
- throw IllegalArgumentException_init_$Create$(toString(message_0));
1485
- }
1486
- }
1487
- protoOf(SignedIntFieldFormatDirective).w54 = function () {
1488
- var tmp = Accessor$getterNotNull$ref_0(this.s57_1.k58());
1489
- var tmp0_elvis_lhs = this.t57_1;
1490
- var formatter = new SignedIntFormatterStructure(tmp, tmp0_elvis_lhs == null ? 0 : tmp0_elvis_lhs, this.w57_1);
1491
- return !(this.v57_1 == null) ? new SpacePaddedFormatter(formatter, this.v57_1) : formatter;
1492
- };
1493
- protoOf(SignedIntFieldFormatDirective).y54 = function () {
1494
- return SignedIntParser(this.t57_1, this.u57_1, this.v57_1, this.s57_1.k58(), this.s57_1.m(), this.w57_1);
1495
- };
1496
- function GenericFieldSpec(accessor, name, defaultValue, sign) {
1497
- name = name === VOID ? accessor.m() : name;
1498
- defaultValue = defaultValue === VOID ? null : defaultValue;
1499
- sign = sign === VOID ? null : sign;
1500
- AbstractFieldSpec.call(this);
1501
- this.l58_1 = accessor;
1502
- this.m58_1 = name;
1503
- this.n58_1 = defaultValue;
1504
- this.o58_1 = sign;
1505
- }
1506
- protoOf(GenericFieldSpec).k58 = function () {
1507
- return this.l58_1;
1508
- };
1509
- protoOf(GenericFieldSpec).m = function () {
1510
- return this.m58_1;
1511
- };
1512
- protoOf(GenericFieldSpec).p58 = function () {
1513
- return this.n58_1;
1514
- };
1515
- function PropertyAccessor(property, name) {
1516
- name = name === VOID ? property.callableName : name;
1517
- this.q58_1 = property;
1518
- this.r58_1 = name;
1519
- }
1520
- protoOf(PropertyAccessor).m = function () {
1521
- return this.r58_1;
1522
- };
1523
- protoOf(PropertyAccessor).s58 = function (container, newValue) {
1524
- var oldValue = this.q58_1.get(container);
1525
- var tmp;
1526
- if (oldValue === null) {
1527
- this.q58_1.set(container, newValue);
1528
- tmp = null;
1529
- } else if (equals(oldValue, newValue)) {
1530
- tmp = null;
1531
- } else {
1532
- tmp = oldValue;
1533
- }
1534
- return tmp;
1535
- };
1536
- protoOf(PropertyAccessor).t58 = function (container, newValue) {
1537
- var tmp = (container == null ? true : !(container == null)) ? container : THROW_CCE();
1538
- return this.s58(tmp, (newValue == null ? true : !(newValue == null)) ? newValue : THROW_CCE());
1539
- };
1540
- protoOf(PropertyAccessor).u58 = function (container) {
1541
- return this.q58_1.get(container);
1542
- };
1543
- function UnsignedFieldSpec(accessor, minValue, maxValue, name, defaultValue, sign) {
1544
- name = name === VOID ? accessor.m() : name;
1545
- defaultValue = defaultValue === VOID ? null : defaultValue;
1546
- sign = sign === VOID ? null : sign;
1547
- AbstractFieldSpec.call(this);
1548
- this.d58_1 = accessor;
1549
- this.e58_1 = minValue;
1550
- this.f58_1 = maxValue;
1551
- this.g58_1 = name;
1552
- this.h58_1 = defaultValue;
1553
- this.i58_1 = sign;
1554
- var tmp = this;
1555
- var tmp_0;
1556
- if (this.f58_1 < 10) {
1557
- tmp_0 = 1;
1558
- } else if (this.f58_1 < 100) {
1559
- tmp_0 = 2;
1560
- } else if (this.f58_1 < 1000) {
1561
- tmp_0 = 3;
1562
- } else {
1563
- throw IllegalArgumentException_init_$Create$('Max value ' + this.f58_1 + ' is too large');
1564
- }
1565
- tmp.j58_1 = tmp_0;
1566
- }
1567
- protoOf(UnsignedFieldSpec).k58 = function () {
1568
- return this.d58_1;
1569
- };
1570
- protoOf(UnsignedFieldSpec).m = function () {
1571
- return this.g58_1;
1572
- };
1573
- protoOf(UnsignedFieldSpec).p58 = function () {
1574
- return this.h58_1;
1575
- };
1576
- function Accessor() {
1577
- }
1578
- function AbstractFieldSpec() {
1579
- }
1580
- protoOf(AbstractFieldSpec).toString = function () {
1581
- return 'The field ' + this.m() + ' (default value is ' + toString_1(this.p58()) + ')';
1582
- };
1583
- function CachedFormatStructure(formats) {
1584
- ConcatenatedFormatStructure.call(this, formats);
1585
- this.u54_1 = protoOf(ConcatenatedFormatStructure).w54.call(this);
1586
- this.v54_1 = protoOf(ConcatenatedFormatStructure).y54.call(this);
1587
- }
1588
- protoOf(CachedFormatStructure).w54 = function () {
1589
- return this.u54_1;
1590
- };
1591
- protoOf(CachedFormatStructure).y54 = function () {
1592
- return this.v54_1;
1593
- };
1594
- function BasicFormatStructure(directive) {
1595
- this.v58_1 = directive;
1596
- }
1597
- protoOf(BasicFormatStructure).toString = function () {
1598
- return 'BasicFormatStructure(' + toString(this.v58_1) + ')';
1599
- };
1600
- protoOf(BasicFormatStructure).equals = function (other) {
1601
- var tmp;
1602
- if (other instanceof BasicFormatStructure) {
1603
- tmp = equals(this.v58_1, other.v58_1);
1604
- } else {
1605
- tmp = false;
1606
- }
1607
- return tmp;
1608
- };
1609
- protoOf(BasicFormatStructure).hashCode = function () {
1610
- return hashCode(this.v58_1);
1611
- };
1612
- protoOf(BasicFormatStructure).y54 = function () {
1613
- return this.v58_1.y54();
1614
- };
1615
- protoOf(BasicFormatStructure).w54 = function () {
1616
- return this.v58_1.w54();
1617
- };
1618
- function ConstantFormatStructure(string) {
1619
- this.w58_1 = string;
1620
- }
1621
- protoOf(ConstantFormatStructure).toString = function () {
1622
- return 'ConstantFormatStructure(' + this.w58_1 + ')';
1623
- };
1624
- protoOf(ConstantFormatStructure).equals = function (other) {
1625
- var tmp;
1626
- if (other instanceof ConstantFormatStructure) {
1627
- tmp = this.w58_1 === other.w58_1;
1628
- } else {
1629
- tmp = false;
1630
- }
1631
- return tmp;
1632
- };
1633
- protoOf(ConstantFormatStructure).hashCode = function () {
1634
- return getStringHashCode(this.w58_1);
1635
- };
1636
- protoOf(ConstantFormatStructure).y54 = function () {
1637
- var tmp;
1638
- // Inline function 'kotlin.text.isEmpty' call
1639
- var this_0 = this.w58_1;
1640
- if (charSequenceLength(this_0) === 0) {
1641
- tmp = emptyList();
1642
- } else {
1643
- // Inline function 'kotlin.collections.buildList' call
1644
- // Inline function 'kotlin.collections.buildListInternal' call
1645
- // Inline function 'kotlin.apply' call
1646
- var this_1 = ArrayList_init_$Create$();
1647
- var tmp_0;
1648
- if (isAsciiDigit(charCodeAt(this.w58_1, 0))) {
1649
- var tmp0 = this.w58_1;
1650
- var tmp$ret$2;
1651
- $l$block: {
1652
- // Inline function 'kotlin.text.takeWhile' call
1653
- var inductionVariable = 0;
1654
- var last = tmp0.length;
1655
- if (inductionVariable < last)
1656
- do {
1657
- var index = inductionVariable;
1658
- inductionVariable = inductionVariable + 1 | 0;
1659
- var it = charCodeAt(tmp0, index);
1660
- if (!isAsciiDigit(it)) {
1661
- tmp$ret$2 = substring(tmp0, 0, index);
1662
- break $l$block;
1663
- }
1664
- }
1665
- while (inductionVariable < last);
1666
- tmp$ret$2 = tmp0;
1667
- }
1668
- this_1.e1(new NumberSpanParserOperation(listOf(new ConstantNumberConsumer(tmp$ret$2))));
1669
- var tmp0_0 = this.w58_1;
1670
- var tmp$ret$4;
1671
- $l$block_0: {
1672
- // Inline function 'kotlin.text.dropWhile' call
1673
- var inductionVariable_0 = 0;
1674
- var last_0 = charSequenceLength(tmp0_0) - 1 | 0;
1675
- if (inductionVariable_0 <= last_0)
1676
- do {
1677
- var index_0 = inductionVariable_0;
1678
- inductionVariable_0 = inductionVariable_0 + 1 | 0;
1679
- var it_0 = charCodeAt(tmp0_0, index_0);
1680
- if (!isAsciiDigit(it_0)) {
1681
- tmp$ret$4 = substring_0(tmp0_0, index_0);
1682
- break $l$block_0;
1683
- }
1684
- }
1685
- while (inductionVariable_0 <= last_0);
1686
- tmp$ret$4 = '';
1687
- }
1688
- tmp_0 = tmp$ret$4;
1689
- } else {
1690
- tmp_0 = this.w58_1;
1691
- }
1692
- var suffix = tmp_0;
1693
- // Inline function 'kotlin.text.isNotEmpty' call
1694
- if (charSequenceLength(suffix) > 0) {
1695
- if (isAsciiDigit(charCodeAt(suffix, suffix.length - 1 | 0))) {
1696
- var tmp$ret$7;
1697
- $l$block_1: {
1698
- // Inline function 'kotlin.text.dropLastWhile' call
1699
- var inductionVariable_1 = get_lastIndex(suffix);
1700
- if (0 <= inductionVariable_1)
1701
- do {
1702
- var index_1 = inductionVariable_1;
1703
- inductionVariable_1 = inductionVariable_1 + -1 | 0;
1704
- var it_1 = charCodeAt(suffix, index_1);
1705
- if (!isAsciiDigit(it_1)) {
1706
- tmp$ret$7 = substring(suffix, 0, index_1 + 1 | 0);
1707
- break $l$block_1;
1708
- }
1709
- }
1710
- while (0 <= inductionVariable_1);
1711
- tmp$ret$7 = '';
1712
- }
1713
- this_1.e1(new PlainStringParserOperation(tmp$ret$7));
1714
- var tmp$ret$9;
1715
- $l$block_2: {
1716
- // Inline function 'kotlin.text.takeLastWhile' call
1717
- var inductionVariable_2 = get_lastIndex(suffix);
1718
- if (0 <= inductionVariable_2)
1719
- do {
1720
- var index_2 = inductionVariable_2;
1721
- inductionVariable_2 = inductionVariable_2 + -1 | 0;
1722
- var it_2 = charCodeAt(suffix, index_2);
1723
- if (!isAsciiDigit(it_2)) {
1724
- tmp$ret$9 = substring_0(suffix, index_2 + 1 | 0);
1725
- break $l$block_2;
1726
- }
1727
- }
1728
- while (0 <= inductionVariable_2);
1729
- tmp$ret$9 = suffix;
1730
- }
1731
- this_1.e1(new NumberSpanParserOperation(listOf(new ConstantNumberConsumer(tmp$ret$9))));
1732
- } else {
1733
- this_1.e1(new PlainStringParserOperation(suffix));
1734
- }
1735
- }
1736
- tmp = this_1.j3();
1737
- }
1738
- return new ParserStructure(tmp, emptyList());
1739
- };
1740
- protoOf(ConstantFormatStructure).w54 = function () {
1741
- return new ConstantStringFormatterStructure(this.w58_1);
1742
- };
1743
- function ConcatenatedFormatStructure(formats) {
1744
- this.j55_1 = formats;
1745
- }
1746
- protoOf(ConcatenatedFormatStructure).toString = function () {
1747
- return 'ConcatenatedFormatStructure(' + joinToString(this.j55_1, ', ') + ')';
1748
- };
1749
- protoOf(ConcatenatedFormatStructure).equals = function (other) {
1750
- var tmp;
1751
- if (other instanceof ConcatenatedFormatStructure) {
1752
- tmp = equals(this.j55_1, other.j55_1);
1753
- } else {
1754
- tmp = false;
1755
- }
1756
- return tmp;
1757
- };
1758
- protoOf(ConcatenatedFormatStructure).hashCode = function () {
1759
- return hashCode(this.j55_1);
1760
- };
1761
- protoOf(ConcatenatedFormatStructure).y54 = function () {
1762
- // Inline function 'kotlin.collections.map' call
1763
- var this_0 = this.j55_1;
1764
- // Inline function 'kotlin.collections.mapTo' call
1765
- var destination = ArrayList_init_$Create$_0(collectionSizeOrDefault(this_0, 10));
1766
- var _iterator__ex2g4s = this_0.t();
1767
- while (_iterator__ex2g4s.u()) {
1768
- var item = _iterator__ex2g4s.v();
1769
- var tmp$ret$0 = item.y54();
1770
- destination.e1(tmp$ret$0);
1771
- }
1772
- return concat(destination);
1773
- };
1774
- protoOf(ConcatenatedFormatStructure).w54 = function () {
1775
- // Inline function 'kotlin.collections.map' call
1776
- var this_0 = this.j55_1;
1777
- // Inline function 'kotlin.collections.mapTo' call
1778
- var destination = ArrayList_init_$Create$_0(collectionSizeOrDefault(this_0, 10));
1779
- var _iterator__ex2g4s = this_0.t();
1780
- while (_iterator__ex2g4s.u()) {
1781
- var item = _iterator__ex2g4s.v();
1782
- var tmp$ret$0 = item.w54();
1783
- destination.e1(tmp$ret$0);
1784
- }
1785
- var formatters = destination;
1786
- var tmp;
1787
- if (formatters.g1() === 1) {
1788
- tmp = single(formatters);
1789
- } else {
1790
- tmp = new ConcatenatedFormatter(formatters);
1791
- }
1792
- return tmp;
1793
- };
1794
- function NonConcatenatedFormatStructure() {
1795
- }
1796
- function FormatterStructure() {
1797
- }
1798
- function SpacePaddedFormatter(formatter, padding) {
1799
- this.y58_1 = formatter;
1800
- this.z58_1 = padding;
1801
- }
1802
- protoOf(SpacePaddedFormatter).x58 = function (obj, builder, minusNotRequired) {
1803
- // Inline function 'kotlin.let' call
1804
- var it = StringBuilder_init_$Create$();
1805
- this.y58_1.x58(obj, it, minusNotRequired);
1806
- var string = it.toString();
1807
- // Inline function 'kotlin.repeat' call
1808
- var times = this.z58_1 - string.length | 0;
1809
- var inductionVariable = 0;
1810
- if (inductionVariable < times)
1811
- do {
1812
- var index = inductionVariable;
1813
- inductionVariable = inductionVariable + 1 | 0;
1814
- builder.s(_Char___init__impl__6a9atx(32));
1815
- }
1816
- while (inductionVariable < times);
1817
- builder.f1(string);
1818
- };
1819
- function ConcatenatedFormatter(formatters) {
1820
- this.a59_1 = formatters;
1821
- }
1822
- protoOf(ConcatenatedFormatter).x58 = function (obj, builder, minusNotRequired) {
1823
- var _iterator__ex2g4s = this.a59_1.t();
1824
- while (_iterator__ex2g4s.u()) {
1825
- var formatter = _iterator__ex2g4s.v();
1826
- formatter.x58(obj, builder, minusNotRequired);
1827
- }
1828
- };
1829
- function UnsignedIntFormatterStructure(number, zeroPadding) {
1830
- this.b59_1 = number;
1831
- this.c59_1 = zeroPadding;
1832
- // Inline function 'kotlin.require' call
1833
- if (!(this.c59_1 >= 0)) {
1834
- var message = 'The minimum number of digits (' + this.c59_1 + ') is negative';
1835
- throw IllegalArgumentException_init_$Create$(toString(message));
1836
- }
1837
- // Inline function 'kotlin.require' call
1838
- if (!(this.c59_1 <= 9)) {
1839
- var message_0 = 'The minimum number of digits (' + this.c59_1 + ') exceeds the length of an Int';
1840
- throw IllegalArgumentException_init_$Create$(toString(message_0));
1841
- }
1842
- }
1843
- protoOf(UnsignedIntFormatterStructure).x58 = function (obj, builder, minusNotRequired) {
1844
- var num = this.b59_1(obj);
1845
- var numberStr = num.toString();
1846
- // Inline function 'kotlin.repeat' call
1847
- var times = this.c59_1 - numberStr.length | 0;
1848
- var inductionVariable = 0;
1849
- if (inductionVariable < times)
1850
- do {
1851
- var index = inductionVariable;
1852
- inductionVariable = inductionVariable + 1 | 0;
1853
- builder.s(_Char___init__impl__6a9atx(48));
1854
- }
1855
- while (inductionVariable < times);
1856
- builder.f1(numberStr);
1857
- };
1858
- function SignedIntFormatterStructure(number, zeroPadding, outputPlusOnExceededWidth) {
1859
- this.d59_1 = number;
1860
- this.e59_1 = zeroPadding;
1861
- this.f59_1 = outputPlusOnExceededWidth;
1862
- // Inline function 'kotlin.require' call
1863
- if (!(this.e59_1 >= 0)) {
1864
- var message = 'The minimum number of digits (' + this.e59_1 + ') is negative';
1865
- throw IllegalArgumentException_init_$Create$(toString(message));
1866
- }
1867
- // Inline function 'kotlin.require' call
1868
- if (!(this.e59_1 <= 9)) {
1869
- var message_0 = 'The minimum number of digits (' + this.e59_1 + ') exceeds the length of an Int';
1870
- throw IllegalArgumentException_init_$Create$(toString(message_0));
1871
- }
1872
- }
1873
- protoOf(SignedIntFormatterStructure).x58 = function (obj, builder, minusNotRequired) {
1874
- var innerBuilder = StringBuilder_init_$Create$();
1875
- // Inline function 'kotlin.let' call
1876
- var it = this.d59_1(obj);
1877
- var number = minusNotRequired && it < 0 ? -it | 0 : it;
1878
- if (!(this.f59_1 == null) && number >= get_POWERS_OF_TEN()[this.f59_1]) {
1879
- innerBuilder.s(_Char___init__impl__6a9atx(43));
1880
- }
1881
- // Inline function 'kotlin.math.absoluteValue' call
1882
- if (abs(number) < get_POWERS_OF_TEN()[this.e59_1 - 1 | 0]) {
1883
- if (number >= 0) {
1884
- innerBuilder.zb(number + get_POWERS_OF_TEN()[this.e59_1] | 0).ec(0);
1885
- } else {
1886
- innerBuilder.zb(number - get_POWERS_OF_TEN()[this.e59_1] | 0).ec(1);
1887
- }
1888
- } else {
1889
- innerBuilder.zb(number);
1890
- }
1891
- builder.f1(innerBuilder);
1892
- };
1893
- function ConstantStringFormatterStructure(string) {
1894
- this.g59_1 = string;
1895
- }
1896
- protoOf(ConstantStringFormatterStructure).x58 = function (obj, builder, minusNotRequired) {
1897
- builder.f1(this.g59_1);
1898
- };
1899
- function ConstantNumberConsumer(expected) {
1900
- NumberConsumer.call(this, expected.length, 'the predefined string ' + expected);
1901
- this.j59_1 = expected;
1902
- }
1903
- protoOf(ConstantNumberConsumer).k59 = function (storage, input, start, end) {
1904
- var tmp;
1905
- // Inline function 'kotlin.text.substring' call
1906
- if (toString(charSequenceSubSequence(input, start, end)) === this.j59_1) {
1907
- tmp = null;
1908
- } else {
1909
- tmp = new WrongConstant(this.j59_1);
1910
- }
1911
- return tmp;
1912
- };
1913
- function NumberConsumer(length, whatThisExpects) {
1914
- this.l59_1 = length;
1915
- this.m59_1 = whatThisExpects;
1916
- }
1917
- protoOf(NumberConsumer).a = function () {
1918
- return this.l59_1;
1919
- };
1920
- function ExpectedInt() {
1921
- }
1922
- protoOf(ExpectedInt).n59 = function () {
1923
- return 'expected an Int value';
1924
- };
1925
- var ExpectedInt_instance;
1926
- function ExpectedInt_getInstance() {
1927
- return ExpectedInt_instance;
1928
- }
1929
- function TooManyDigits(maxDigits) {
1930
- this.o59_1 = maxDigits;
1931
- }
1932
- protoOf(TooManyDigits).n59 = function () {
1933
- return 'expected at most ' + this.o59_1 + ' digits';
1934
- };
1935
- function TooFewDigits(minDigits) {
1936
- this.p59_1 = minDigits;
1937
- }
1938
- protoOf(TooFewDigits).n59 = function () {
1939
- return 'expected at least ' + this.p59_1 + ' digits';
1940
- };
1941
- function WrongConstant(expected) {
1942
- this.q59_1 = expected;
1943
- }
1944
- protoOf(WrongConstant).n59 = function () {
1945
- return "expected '" + this.q59_1 + "'";
1946
- };
1947
- function Conflicting(conflicting) {
1948
- this.r59_1 = conflicting;
1949
- }
1950
- protoOf(Conflicting).n59 = function () {
1951
- return "attempted to overwrite the existing value '" + toString(this.r59_1) + "'";
1952
- };
1953
- function setWithoutReassigning(_this__u8e3s4, receiver, value) {
1954
- var tmp0_elvis_lhs = _this__u8e3s4.t58(receiver, value);
1955
- var tmp;
1956
- if (tmp0_elvis_lhs == null) {
1957
- return null;
1958
- } else {
1959
- tmp = tmp0_elvis_lhs;
1960
- }
1961
- var conflictingValue = tmp;
1962
- return new Conflicting(conflictingValue);
1963
- }
1964
- function UnsignedIntConsumer(minLength, maxLength, setter, name, multiplyByMinus1) {
1965
- multiplyByMinus1 = multiplyByMinus1 === VOID ? false : multiplyByMinus1;
1966
- NumberConsumer.call(this, minLength == maxLength ? minLength : null, name);
1967
- this.u59_1 = minLength;
1968
- this.v59_1 = maxLength;
1969
- this.w59_1 = setter;
1970
- this.x59_1 = multiplyByMinus1;
1971
- // Inline function 'kotlin.require' call
1972
- if (!(this.a() == null || numberRangeToNumber(1, 9).vh(this.a()))) {
1973
- var message = 'Invalid length for field ' + this.m59_1 + ': ' + this.a();
1974
- throw IllegalArgumentException_init_$Create$(toString(message));
1975
- }
1976
- }
1977
- protoOf(UnsignedIntConsumer).k59 = function (storage, input, start, end) {
1978
- var tmp;
1979
- if (!(this.v59_1 == null) && (end - start | 0) > this.v59_1) {
1980
- tmp = new TooManyDigits(this.v59_1);
1981
- } else if (!(this.u59_1 == null) && (end - start | 0) < this.u59_1) {
1982
- tmp = new TooFewDigits(this.u59_1);
1983
- } else {
1984
- var result = parseAsciiIntOrNull(input, start, end);
1985
- tmp = result == null ? ExpectedInt_instance : setWithoutReassigning(this.w59_1, storage, this.x59_1 ? -result | 0 : result);
1986
- }
1987
- return tmp;
1988
- };
1989
- function parseAsciiIntOrNull(_this__u8e3s4, start, end) {
1990
- var result = 0;
1991
- var inductionVariable = start;
1992
- if (inductionVariable < end)
1993
- do {
1994
- var i = inductionVariable;
1995
- inductionVariable = inductionVariable + 1 | 0;
1996
- var digit = charSequenceGet(_this__u8e3s4, i);
1997
- result = imul(result, 10) + asciiDigitToInt(digit) | 0;
1998
- if (result < 0)
1999
- return null;
2000
- }
2001
- while (inductionVariable < end);
2002
- return result;
2003
- }
2004
- function ParseError(position, message) {
2005
- this.y59_1 = position;
2006
- this.z59_1 = message;
2007
- }
2008
- function _ParseResult___init__impl__gvz3cn(value) {
2009
- return value;
2010
- }
2011
- function _ParseResult___get_value__impl__86mnxf($this) {
2012
- return $this;
2013
- }
2014
- function Companion_6() {
2015
- }
2016
- protoOf(Companion_6).a5a = function (indexOfNextUnparsed) {
2017
- return _ParseResult___init__impl__gvz3cn(indexOfNextUnparsed);
2018
- };
2019
- protoOf(Companion_6).b5a = function (position, message) {
2020
- return _ParseResult___init__impl__gvz3cn(new ParseError(position, message));
2021
- };
2022
- var Companion_instance_6;
2023
- function Companion_getInstance_6() {
2024
- return Companion_instance_6;
2025
- }
2026
- function _Parser___init__impl__gdyfby(commands) {
2027
- return commands;
2028
- }
2029
- function _get_commands__a20n1($this) {
2030
- return $this;
2031
- }
2032
- function Parser__match_impl_nzt83d($this, input, initialContainer, startIndex) {
2033
- // Inline function 'kotlin.collections.mutableListOf' call
2034
- var errors = ArrayList_init_$Create$();
2035
- // Inline function 'kotlinx.datetime.internal.format.parser.Parser.parse' call
2036
- var parseOptions = mutableListOf([new ParserState(initialContainer, _get_commands__a20n1($this), startIndex)]);
2037
- iterate_over_alternatives: while (true) {
2038
- var tmp0_elvis_lhs = removeLastOrNull(parseOptions);
2039
- var tmp;
2040
- if (tmp0_elvis_lhs == null) {
2041
- break iterate_over_alternatives;
2042
- } else {
2043
- tmp = tmp0_elvis_lhs;
2044
- }
2045
- var state = tmp;
2046
- var output = state.c5a_1.e56();
2047
- var inputPosition = state.e5a_1;
2048
- var parserStructure = state.d5a_1;
2049
- // Inline function 'kotlin.run' call
2050
- $l$block: {
2051
- var inductionVariable = 0;
2052
- var last = parserStructure.g5a_1.g1() - 1 | 0;
2053
- if (inductionVariable <= last)
2054
- do {
2055
- var ix = inductionVariable;
2056
- inductionVariable = inductionVariable + 1 | 0;
2057
- // Inline function 'kotlinx.datetime.internal.format.parser.ParseResult.match' call
2058
- var this_0 = parserStructure.g5a_1.h1(ix).i5a(output, input, inputPosition);
2059
- var tmp0_subject = _ParseResult___get_value__impl__86mnxf(this_0);
2060
- if (typeof tmp0_subject === 'number') {
2061
- inputPosition = _ParseResult___get_value__impl__86mnxf(this_0);
2062
- } else {
2063
- if (tmp0_subject instanceof ParseError) {
2064
- var it = _ParseResult___get_value__impl__86mnxf(this_0);
2065
- errors.e1(it);
2066
- break $l$block;
2067
- } else {
2068
- // Inline function 'kotlin.error' call
2069
- var message = 'Unexpected parse result: ' + toString(_ParseResult___get_value__impl__86mnxf(this_0));
2070
- throw IllegalStateException_init_$Create$(toString(message));
2071
- }
2072
- }
2073
- }
2074
- while (inductionVariable <= last);
2075
- if (parserStructure.h5a_1.r()) {
2076
- if (false || inputPosition === charSequenceLength(input)) {
2077
- return output;
2078
- } else {
2079
- var tmp_0 = inputPosition;
2080
- var it_0 = new ParseError(tmp_0, Parser$match$lambda);
2081
- errors.e1(it_0);
2082
- }
2083
- } else {
2084
- var inductionVariable_0 = parserStructure.h5a_1.g1() - 1 | 0;
2085
- if (0 <= inductionVariable_0)
2086
- do {
2087
- var ix_0 = inductionVariable_0;
2088
- inductionVariable_0 = inductionVariable_0 + -1 | 0;
2089
- parseOptions.e1(new ParserState(output, parserStructure.h5a_1.h1(ix_0), inputPosition));
2090
- }
2091
- while (0 <= inductionVariable_0);
2092
- }
2093
- }
2094
- }
2095
- // Inline function 'kotlin.collections.sortByDescending' call
2096
- if (errors.g1() > 1) {
2097
- // Inline function 'kotlin.comparisons.compareByDescending' call
2098
- var tmp_1 = Parser$match$lambda_0;
2099
- var tmp$ret$8 = new sam$kotlin_Comparator$0(tmp_1);
2100
- sortWith(errors, tmp$ret$8);
2101
- }
2102
- throw new ParseException(errors);
2103
- }
2104
- function Parser__match$default_impl_x2xlti($this, input, initialContainer, startIndex, $super) {
2105
- startIndex = startIndex === VOID ? 0 : startIndex;
2106
- var tmp;
2107
- if ($super === VOID) {
2108
- tmp = Parser__match_impl_nzt83d($this, input, initialContainer, startIndex);
2109
- } else {
2110
- var tmp_0 = $super;
2111
- tmp = (tmp_0 == null ? null : new Parser(tmp_0)).j5a.call(new Parser($this), input, initialContainer, startIndex);
2112
- }
2113
- return tmp;
2114
- }
2115
- function ParserState(output, parserStructure, inputPosition) {
2116
- this.c5a_1 = output;
2117
- this.d5a_1 = parserStructure;
2118
- this.e5a_1 = inputPosition;
2119
- }
2120
- function Parser__toString_impl_x33iea($this) {
2121
- return 'Parser(commands=' + $this.toString() + ')';
2122
- }
2123
- function Parser__hashCode_impl_bbxllf($this) {
2124
- return hashCode($this);
2125
- }
2126
- function Parser__equals_impl_djxokv($this, other) {
2127
- if (!(other instanceof Parser))
2128
- return false;
2129
- var tmp0_other_with_cast = other instanceof Parser ? other.f5a_1 : THROW_CCE();
2130
- if (!equals($this, tmp0_other_with_cast))
2131
- return false;
2132
- return true;
2133
- }
2134
- function sam$kotlin_Comparator$0(function_0) {
2135
- this.k5a_1 = function_0;
2136
- }
2137
- protoOf(sam$kotlin_Comparator$0).mc = function (a, b) {
2138
- return this.k5a_1(a, b);
2139
- };
2140
- protoOf(sam$kotlin_Comparator$0).compare = function (a, b) {
2141
- return this.mc(a, b);
2142
- };
2143
- protoOf(sam$kotlin_Comparator$0).g3 = function () {
2144
- return this.k5a_1;
2145
- };
2146
- protoOf(sam$kotlin_Comparator$0).equals = function (other) {
2147
- var tmp;
2148
- if (!(other == null) ? isInterface(other, Comparator) : false) {
2149
- var tmp_0;
2150
- if (!(other == null) ? isInterface(other, FunctionAdapter) : false) {
2151
- tmp_0 = equals(this.g3(), other.g3());
2152
- } else {
2153
- tmp_0 = false;
2154
- }
2155
- tmp = tmp_0;
2156
- } else {
2157
- tmp = false;
2158
- }
2159
- return tmp;
2160
- };
2161
- protoOf(sam$kotlin_Comparator$0).hashCode = function () {
2162
- return hashCode(this.g3());
2163
- };
2164
- function Parser$match$lambda() {
2165
- return 'There is more input to consume';
2166
- }
2167
- function Parser$match$lambda_0(a, b) {
2168
- // Inline function 'kotlin.comparisons.compareValuesBy' call
2169
- var tmp = b.y59_1;
2170
- var tmp$ret$1 = a.y59_1;
2171
- return compareValues(tmp, tmp$ret$1);
2172
- }
2173
- function Parser(commands) {
2174
- this.f5a_1 = commands;
2175
- }
2176
- protoOf(Parser).toString = function () {
2177
- return Parser__toString_impl_x33iea(this.f5a_1);
2178
- };
2179
- protoOf(Parser).hashCode = function () {
2180
- return Parser__hashCode_impl_bbxllf(this.f5a_1);
2181
- };
2182
- protoOf(Parser).equals = function (other) {
2183
- return Parser__equals_impl_djxokv(this.f5a_1, other);
2184
- };
2185
- function ParserStructure(operations, followedBy) {
2186
- this.g5a_1 = operations;
2187
- this.h5a_1 = followedBy;
2188
- }
2189
- protoOf(ParserStructure).toString = function () {
2190
- return joinToString(this.g5a_1, ', ') + '(' + joinToString(this.h5a_1, ';') + ')';
2191
- };
2192
- function ParseException(errors) {
2193
- Exception_init_$Init$(formatError(errors), this);
2194
- captureStack(this, ParseException);
2195
- }
2196
- function concat(_this__u8e3s4) {
2197
- // Inline function 'kotlin.collections.foldRight' call
2198
- var accumulator = new ParserStructure(emptyList(), emptyList());
2199
- if (!_this__u8e3s4.r()) {
2200
- var iterator = _this__u8e3s4.i1(_this__u8e3s4.g1());
2201
- while (iterator.v4()) {
2202
- var tmp0 = iterator.x4();
2203
- var acc = accumulator;
2204
- accumulator = concat$append(tmp0, acc);
2205
- }
2206
- }
2207
- var naiveParser = accumulator;
2208
- return concat$simplify(naiveParser, emptyList());
2209
- }
2210
- function formatError(errors) {
2211
- if (errors.g1() === 1) {
2212
- return 'Position ' + errors.h1(0).y59_1 + ': ' + errors.h1(0).z59_1();
2213
- }
2214
- var averageMessageLength = 33;
2215
- var tmp0_buffer = StringBuilder_init_$Create$_0(imul(averageMessageLength, errors.g1()));
2216
- return joinTo(errors, tmp0_buffer, ', ', 'Errors: ', VOID, VOID, VOID, formatError$lambda).toString();
2217
- }
2218
- function concat$append(_this__u8e3s4, other) {
2219
- var tmp;
2220
- if (_this__u8e3s4.h5a_1.r()) {
2221
- tmp = new ParserStructure(plus(_this__u8e3s4.g5a_1, other.g5a_1), other.h5a_1);
2222
- } else {
2223
- // Inline function 'kotlin.collections.map' call
2224
- var this_0 = _this__u8e3s4.h5a_1;
2225
- // Inline function 'kotlin.collections.mapTo' call
2226
- var destination = ArrayList_init_$Create$_0(collectionSizeOrDefault(this_0, 10));
2227
- var _iterator__ex2g4s = this_0.t();
2228
- while (_iterator__ex2g4s.u()) {
2229
- var item = _iterator__ex2g4s.v();
2230
- var tmp$ret$0 = concat$append(item, other);
2231
- destination.e1(tmp$ret$0);
2232
- }
2233
- tmp = new ParserStructure(_this__u8e3s4.g5a_1, destination);
2234
- }
2235
- return tmp;
2236
- }
2237
- function concat$simplify(_this__u8e3s4, unconditionalModifications) {
2238
- // Inline function 'kotlin.collections.mutableListOf' call
2239
- var newOperations = ArrayList_init_$Create$();
2240
- var currentNumberSpan = null;
2241
- var unconditionalModificationsForTails = toMutableList(unconditionalModifications);
2242
- var _iterator__ex2g4s = _this__u8e3s4.g5a_1.t();
2243
- while (_iterator__ex2g4s.u()) {
2244
- var op = _iterator__ex2g4s.v();
2245
- if (op instanceof NumberSpanParserOperation) {
2246
- if (!(currentNumberSpan == null)) {
2247
- currentNumberSpan.j1(op.l5a_1);
2248
- } else {
2249
- currentNumberSpan = toMutableList(op.l5a_1);
2250
- }
2251
- } else {
2252
- if (op instanceof UnconditionalModification) {
2253
- unconditionalModificationsForTails.e1(op);
2254
- } else {
2255
- if (!(currentNumberSpan == null)) {
2256
- newOperations.e1(new NumberSpanParserOperation(currentNumberSpan));
2257
- currentNumberSpan = null;
2258
- }
2259
- newOperations.e1(op);
2260
- }
2261
- }
2262
- }
2263
- // Inline function 'kotlin.collections.flatMap' call
2264
- var tmp0 = _this__u8e3s4.h5a_1;
2265
- // Inline function 'kotlin.collections.flatMapTo' call
2266
- var destination = ArrayList_init_$Create$();
2267
- var _iterator__ex2g4s_0 = tmp0.t();
2268
- while (_iterator__ex2g4s_0.u()) {
2269
- var element = _iterator__ex2g4s_0.v();
2270
- var simplified = concat$simplify(element, unconditionalModificationsForTails);
2271
- var tmp;
2272
- if (simplified.g5a_1.r()) {
2273
- // Inline function 'kotlin.collections.ifEmpty' call
2274
- var this_0 = simplified.h5a_1;
2275
- var tmp_0;
2276
- if (this_0.r()) {
2277
- tmp_0 = listOf(simplified);
2278
- } else {
2279
- tmp_0 = this_0;
2280
- }
2281
- tmp = tmp_0;
2282
- } else {
2283
- tmp = listOf(simplified);
2284
- }
2285
- var list = tmp;
2286
- addAll(destination, list);
2287
- }
2288
- // Inline function 'kotlin.collections.ifEmpty' call
2289
- var tmp_1;
2290
- if (destination.r()) {
2291
- tmp_1 = listOf(new ParserStructure(unconditionalModificationsForTails, emptyList()));
2292
- } else {
2293
- tmp_1 = destination;
2294
- }
2295
- var mergedTails = tmp_1;
2296
- var tmp_2;
2297
- if (currentNumberSpan == null) {
2298
- tmp_2 = new ParserStructure(newOperations, mergedTails);
2299
- } else {
2300
- var tmp$ret$8;
2301
- $l$block_0: {
2302
- // Inline function 'kotlin.collections.none' call
2303
- var tmp_3;
2304
- if (isInterface(mergedTails, Collection)) {
2305
- tmp_3 = mergedTails.r();
2306
- } else {
2307
- tmp_3 = false;
2308
- }
2309
- if (tmp_3) {
2310
- tmp$ret$8 = true;
2311
- break $l$block_0;
2312
- }
2313
- var _iterator__ex2g4s_1 = mergedTails.t();
2314
- while (_iterator__ex2g4s_1.u()) {
2315
- var element_0 = _iterator__ex2g4s_1.v();
2316
- var tmp0_safe_receiver = firstOrNull(element_0.g5a_1);
2317
- var tmp_4;
2318
- if (tmp0_safe_receiver == null) {
2319
- tmp_4 = null;
2320
- } else {
2321
- // Inline function 'kotlin.let' call
2322
- tmp_4 = tmp0_safe_receiver instanceof NumberSpanParserOperation;
2323
- }
2324
- if (tmp_4 === true) {
2325
- tmp$ret$8 = false;
2326
- break $l$block_0;
2327
- }
2328
- }
2329
- tmp$ret$8 = true;
2330
- }
2331
- if (tmp$ret$8) {
2332
- newOperations.e1(new NumberSpanParserOperation(currentNumberSpan));
2333
- tmp_2 = new ParserStructure(newOperations, mergedTails);
2334
- } else {
2335
- // Inline function 'kotlin.collections.map' call
2336
- // Inline function 'kotlin.collections.mapTo' call
2337
- var destination_0 = ArrayList_init_$Create$_0(collectionSizeOrDefault(mergedTails, 10));
2338
- var _iterator__ex2g4s_2 = mergedTails.t();
2339
- while (_iterator__ex2g4s_2.u()) {
2340
- var item = _iterator__ex2g4s_2.v();
2341
- var firstOperation = firstOrNull(item.g5a_1);
2342
- var tmp_5;
2343
- if (firstOperation instanceof NumberSpanParserOperation) {
2344
- tmp_5 = new ParserStructure(plus(listOf(new NumberSpanParserOperation(plus(currentNumberSpan, firstOperation.l5a_1))), drop(item.g5a_1, 1)), item.h5a_1);
2345
- } else {
2346
- if (firstOperation == null) {
2347
- tmp_5 = new ParserStructure(listOf(new NumberSpanParserOperation(currentNumberSpan)), item.h5a_1);
2348
- } else {
2349
- tmp_5 = new ParserStructure(plus(listOf(new NumberSpanParserOperation(currentNumberSpan)), item.g5a_1), item.h5a_1);
2350
- }
2351
- }
2352
- var tmp$ret$12 = tmp_5;
2353
- destination_0.e1(tmp$ret$12);
2354
- }
2355
- var newTails = destination_0;
2356
- tmp_2 = new ParserStructure(newOperations, newTails);
2357
- }
2358
- }
2359
- return tmp_2;
2360
- }
2361
- function formatError$lambda(it) {
2362
- return 'position ' + it.y59_1 + ": '" + it.z59_1() + "'";
2363
- }
2364
- function spaceAndZeroPaddedUnsignedInt(minDigits, maxDigits, spacePadding, setter, name, withMinus) {
2365
- withMinus = withMinus === VOID ? false : withMinus;
2366
- var minNumberLength = (minDigits == null ? 1 : minDigits) + (withMinus ? 1 : 0) | 0;
2367
- var tmp;
2368
- if (maxDigits == null) {
2369
- tmp = null;
2370
- } else {
2371
- // Inline function 'kotlin.let' call
2372
- tmp = withMinus ? maxDigits + 1 | 0 : maxDigits;
2373
- }
2374
- var tmp2_elvis_lhs = tmp;
2375
- var maxNumberLength = tmp2_elvis_lhs == null ? 2147483647 : tmp2_elvis_lhs;
2376
- var spacePadding_0 = spacePadding == null ? 0 : spacePadding;
2377
- // Inline function 'kotlin.comparisons.minOf' call
2378
- var maxPaddedNumberLength = Math.min(maxNumberLength, spacePadding_0);
2379
- if (minNumberLength >= maxPaddedNumberLength)
2380
- return spaceAndZeroPaddedUnsignedInt$numberOfRequiredLengths(withMinus, setter, name, minNumberLength, maxNumberLength);
2381
- var accumulated = spaceAndZeroPaddedUnsignedInt$numberOfRequiredLengths(withMinus, setter, name, minNumberLength, minNumberLength);
2382
- var inductionVariable = minNumberLength;
2383
- if (inductionVariable < maxPaddedNumberLength)
2384
- do {
2385
- var accumulatedWidth = inductionVariable;
2386
- inductionVariable = inductionVariable + 1 | 0;
2387
- accumulated = new ParserStructure(emptyList(), listOf_0([spaceAndZeroPaddedUnsignedInt$numberOfRequiredLengths(withMinus, setter, name, accumulatedWidth + 1 | 0, accumulatedWidth + 1 | 0), concat(listOf_0([new ParserStructure(listOf(new PlainStringParserOperation(' ')), emptyList()), accumulated]))]));
2388
- }
2389
- while (inductionVariable < maxPaddedNumberLength);
2390
- var tmp_0;
2391
- if (spacePadding_0 > maxNumberLength) {
2392
- var prepadding = new PlainStringParserOperation(repeat(' ', spacePadding_0 - maxNumberLength | 0));
2393
- tmp_0 = concat(listOf_0([new ParserStructure(listOf(prepadding), emptyList()), accumulated]));
2394
- } else if (spacePadding_0 === maxNumberLength) {
2395
- tmp_0 = accumulated;
2396
- } else {
2397
- var r = new ParserStructure(emptyList(), listOf_0([spaceAndZeroPaddedUnsignedInt$numberOfRequiredLengths(withMinus, setter, name, spacePadding_0 + 1 | 0, maxNumberLength), accumulated]));
2398
- tmp_0 = r;
2399
- }
2400
- return tmp_0;
2401
- }
2402
- function _get_whatThisExpects__4pg11j($this) {
2403
- // Inline function 'kotlin.collections.map' call
2404
- var this_0 = $this.l5a_1;
2405
- // Inline function 'kotlin.collections.mapTo' call
2406
- var destination = ArrayList_init_$Create$_0(collectionSizeOrDefault(this_0, 10));
2407
- var _iterator__ex2g4s = this_0.t();
2408
- while (_iterator__ex2g4s.u()) {
2409
- var item = _iterator__ex2g4s.v();
2410
- var length = item.a();
2411
- var tmp$ret$0 = (length == null ? 'at least one digit' : '' + length + ' digits') + (' for ' + item.m59_1);
2412
- destination.e1(tmp$ret$0);
2413
- }
2414
- var consumerLengths = destination;
2415
- var tmp;
2416
- if ($this.n5a_1) {
2417
- tmp = 'a number with at least ' + $this.m5a_1 + ' digits: ' + toString(consumerLengths);
2418
- } else {
2419
- tmp = 'a number with exactly ' + $this.m5a_1 + ' digits: ' + toString(consumerLengths);
2420
- }
2421
- return tmp;
2422
- }
2423
- function NumberSpanParserOperation$consume$lambda(this$0) {
2424
- return function () {
2425
- return 'Unexpected end of input: yet to parse ' + _get_whatThisExpects__4pg11j(this$0);
2426
- };
2427
- }
2428
- function NumberSpanParserOperation$consume$lambda_0($digitsInRow, this$0) {
2429
- return function () {
2430
- return 'Only found ' + $digitsInRow._v + ' digits in a row, but need to parse ' + _get_whatThisExpects__4pg11j(this$0);
2431
- };
2432
- }
2433
- function NumberSpanParserOperation$consume$lambda_1($numberString, this$0, $i, $error) {
2434
- return function () {
2435
- return "Can not interpret the string '" + $numberString + "' as " + this$0.l5a_1.h1($i).m59_1 + ': ' + $error.n59();
2436
- };
2437
- }
2438
- function NumberSpanParserOperation(consumers) {
2439
- this.l5a_1 = consumers;
2440
- var tmp = this;
2441
- // Inline function 'kotlin.collections.sumOf' call
2442
- var sum = 0;
2443
- var _iterator__ex2g4s = this.l5a_1.t();
2444
- while (_iterator__ex2g4s.u()) {
2445
- var element = _iterator__ex2g4s.v();
2446
- var tmp_0 = sum;
2447
- var tmp0_elvis_lhs = element.a();
2448
- sum = tmp_0 + (tmp0_elvis_lhs == null ? 1 : tmp0_elvis_lhs) | 0;
2449
- }
2450
- tmp.m5a_1 = sum;
2451
- var tmp_1 = this;
2452
- var tmp0 = this.l5a_1;
2453
- var tmp$ret$2;
2454
- $l$block_0: {
2455
- // Inline function 'kotlin.collections.any' call
2456
- var tmp_2;
2457
- if (isInterface(tmp0, Collection)) {
2458
- tmp_2 = tmp0.r();
2459
- } else {
2460
- tmp_2 = false;
2461
- }
2462
- if (tmp_2) {
2463
- tmp$ret$2 = false;
2464
- break $l$block_0;
2465
- }
2466
- var _iterator__ex2g4s_0 = tmp0.t();
2467
- while (_iterator__ex2g4s_0.u()) {
2468
- var element_0 = _iterator__ex2g4s_0.v();
2469
- if (element_0.a() == null) {
2470
- tmp$ret$2 = true;
2471
- break $l$block_0;
2472
- }
2473
- }
2474
- tmp$ret$2 = false;
2475
- }
2476
- tmp_1.n5a_1 = tmp$ret$2;
2477
- var tmp0_0 = this.l5a_1;
2478
- var tmp$ret$4;
2479
- $l$block_2: {
2480
- // Inline function 'kotlin.collections.all' call
2481
- var tmp_3;
2482
- if (isInterface(tmp0_0, Collection)) {
2483
- tmp_3 = tmp0_0.r();
2484
- } else {
2485
- tmp_3 = false;
2486
- }
2487
- if (tmp_3) {
2488
- tmp$ret$4 = true;
2489
- break $l$block_2;
2490
- }
2491
- var _iterator__ex2g4s_1 = tmp0_0.t();
2492
- while (_iterator__ex2g4s_1.u()) {
2493
- var element_1 = _iterator__ex2g4s_1.v();
2494
- var tmp0_elvis_lhs_0 = element_1.a();
2495
- if (!((tmp0_elvis_lhs_0 == null ? 2147483647 : tmp0_elvis_lhs_0) > 0)) {
2496
- tmp$ret$4 = false;
2497
- break $l$block_2;
2498
- }
2499
- }
2500
- tmp$ret$4 = true;
2501
- }
2502
- // Inline function 'kotlin.require' call
2503
- // Inline function 'kotlin.require' call
2504
- if (!tmp$ret$4) {
2505
- var message = 'Failed requirement.';
2506
- throw IllegalArgumentException_init_$Create$(toString(message));
2507
- }
2508
- var tmp0_1 = this.l5a_1;
2509
- var tmp$ret$9;
2510
- $l$block_3: {
2511
- // Inline function 'kotlin.collections.count' call
2512
- var tmp_4;
2513
- if (isInterface(tmp0_1, Collection)) {
2514
- tmp_4 = tmp0_1.r();
2515
- } else {
2516
- tmp_4 = false;
2517
- }
2518
- if (tmp_4) {
2519
- tmp$ret$9 = 0;
2520
- break $l$block_3;
2521
- }
2522
- var count = 0;
2523
- var _iterator__ex2g4s_2 = tmp0_1.t();
2524
- while (_iterator__ex2g4s_2.u()) {
2525
- var element_2 = _iterator__ex2g4s_2.v();
2526
- if (element_2.a() == null) {
2527
- count = count + 1 | 0;
2528
- checkCountOverflow(count);
2529
- }
2530
- }
2531
- tmp$ret$9 = count;
2532
- }
2533
- // Inline function 'kotlin.require' call
2534
- if (!(tmp$ret$9 <= 1)) {
2535
- // Inline function 'kotlin.collections.filter' call
2536
- var tmp0_2 = this.l5a_1;
2537
- // Inline function 'kotlin.collections.filterTo' call
2538
- var destination = ArrayList_init_$Create$();
2539
- var _iterator__ex2g4s_3 = tmp0_2.t();
2540
- while (_iterator__ex2g4s_3.u()) {
2541
- var element_3 = _iterator__ex2g4s_3.v();
2542
- if (element_3.a() == null) {
2543
- destination.e1(element_3);
2544
- }
2545
- }
2546
- // Inline function 'kotlin.collections.map' call
2547
- // Inline function 'kotlin.collections.mapTo' call
2548
- var destination_0 = ArrayList_init_$Create$_0(collectionSizeOrDefault(destination, 10));
2549
- var _iterator__ex2g4s_4 = destination.t();
2550
- while (_iterator__ex2g4s_4.u()) {
2551
- var item = _iterator__ex2g4s_4.v();
2552
- var tmp$ret$14 = item.m59_1;
2553
- destination_0.e1(tmp$ret$14);
2554
- }
2555
- var fieldNames = destination_0;
2556
- var message_0 = 'At most one variable-length numeric field in a row is allowed, but got several: ' + toString(fieldNames) + '. ' + "Parsing is undefined: for example, with variable-length month number and variable-length day of month, '111' can be parsed as Jan 11th or Nov 1st.";
2557
- throw IllegalArgumentException_init_$Create$(toString(message_0));
2558
- }
2559
- }
2560
- protoOf(NumberSpanParserOperation).i5a = function (storage, input, startIndex) {
2561
- if ((startIndex + this.m5a_1 | 0) > charSequenceLength(input)) {
2562
- var tmp = Companion_instance_6;
2563
- return tmp.b5a(startIndex, NumberSpanParserOperation$consume$lambda(this));
2564
- }
2565
- var digitsInRow = {_v: 0};
2566
- while ((startIndex + digitsInRow._v | 0) < charSequenceLength(input) && isAsciiDigit(charSequenceGet(input, startIndex + digitsInRow._v | 0))) {
2567
- digitsInRow._v = digitsInRow._v + 1 | 0;
2568
- digitsInRow._v;
2569
- }
2570
- if (digitsInRow._v < this.m5a_1) {
2571
- var tmp_0 = Companion_instance_6;
2572
- return tmp_0.b5a(startIndex, NumberSpanParserOperation$consume$lambda_0(digitsInRow, this));
2573
- }
2574
- var index = startIndex;
2575
- var inductionVariable = 0;
2576
- var last = this.l5a_1.g1() - 1 | 0;
2577
- if (inductionVariable <= last)
2578
- do {
2579
- var i = inductionVariable;
2580
- inductionVariable = inductionVariable + 1 | 0;
2581
- var tmp0_elvis_lhs = this.l5a_1.h1(i).a();
2582
- var length = tmp0_elvis_lhs == null ? (digitsInRow._v - this.m5a_1 | 0) + 1 | 0 : tmp0_elvis_lhs;
2583
- var error = this.l5a_1.h1(i).k59(storage, input, index, index + length | 0);
2584
- if (!(error == null)) {
2585
- var tmp2 = index;
2586
- // Inline function 'kotlin.text.substring' call
2587
- var endIndex = index + length | 0;
2588
- var numberString = toString(charSequenceSubSequence(input, tmp2, endIndex));
2589
- var tmp_1 = Companion_instance_6;
2590
- var tmp_2 = index;
2591
- return tmp_1.b5a(tmp_2, NumberSpanParserOperation$consume$lambda_1(numberString, this, i, error));
2592
- }
2593
- index = index + length | 0;
2594
- }
2595
- while (inductionVariable <= last);
2596
- return Companion_instance_6.a5a(index);
2597
- };
2598
- protoOf(NumberSpanParserOperation).toString = function () {
2599
- return _get_whatThisExpects__4pg11j(this);
2600
- };
2601
- function SignedIntParser(minDigits, maxDigits, spacePadding, setter, name, plusOnExceedsWidth) {
2602
- var parsers = mutableListOf([spaceAndZeroPaddedUnsignedInt(minDigits, maxDigits, spacePadding, setter, name, true)]);
2603
- if (!(plusOnExceedsWidth == null)) {
2604
- parsers.e1(spaceAndZeroPaddedUnsignedInt(minDigits, plusOnExceedsWidth, spacePadding, setter, name));
2605
- parsers.e1(new ParserStructure(listOf_0([new PlainStringParserOperation('+'), new NumberSpanParserOperation(listOf(new UnsignedIntConsumer(plusOnExceedsWidth + 1 | 0, maxDigits, setter, name, false)))]), emptyList()));
2606
- } else {
2607
- parsers.e1(spaceAndZeroPaddedUnsignedInt(minDigits, maxDigits, spacePadding, setter, name));
2608
- }
2609
- return new ParserStructure(emptyList(), parsers);
2610
- }
2611
- function PlainStringParserOperation$consume$lambda(this$0) {
2612
- return function () {
2613
- return "Unexpected end of input: yet to parse '" + this$0.o5a_1 + "'";
2614
- };
2615
- }
2616
- function PlainStringParserOperation$consume$lambda_0(this$0, $input, $startIndex, $i) {
2617
- return function () {
2618
- var tmp0 = $input;
2619
- var tmp2 = $startIndex;
2620
- // Inline function 'kotlin.text.substring' call
2621
- var endIndex = ($startIndex + $i | 0) + 1 | 0;
2622
- var tmp$ret$0 = toString(charSequenceSubSequence(tmp0, tmp2, endIndex));
2623
- return 'Expected ' + this$0.o5a_1 + ' but got ' + tmp$ret$0;
2624
- };
2625
- }
2626
- function PlainStringParserOperation(string) {
2627
- this.o5a_1 = string;
2628
- // Inline function 'kotlin.text.isNotEmpty' call
2629
- var this_0 = this.o5a_1;
2630
- // Inline function 'kotlin.require' call
2631
- if (!(charSequenceLength(this_0) > 0)) {
2632
- var message = 'Empty string is not allowed';
2633
- throw IllegalArgumentException_init_$Create$(toString(message));
2634
- }
2635
- // Inline function 'kotlin.require' call
2636
- if (!!isAsciiDigit(charCodeAt(this.o5a_1, 0))) {
2637
- var message_0 = "String '" + this.o5a_1 + "' starts with a digit";
2638
- throw IllegalArgumentException_init_$Create$(toString(message_0));
2639
- }
2640
- // Inline function 'kotlin.require' call
2641
- if (!!isAsciiDigit(charCodeAt(this.o5a_1, this.o5a_1.length - 1 | 0))) {
2642
- var message_1 = "String '" + this.o5a_1 + "' ends with a digit";
2643
- throw IllegalArgumentException_init_$Create$(toString(message_1));
2644
- }
2645
- }
2646
- protoOf(PlainStringParserOperation).i5a = function (storage, input, startIndex) {
2647
- if ((startIndex + this.o5a_1.length | 0) > charSequenceLength(input)) {
2648
- var tmp = Companion_instance_6;
2649
- return tmp.b5a(startIndex, PlainStringParserOperation$consume$lambda(this));
2650
- }
2651
- var inductionVariable = 0;
2652
- var last = charSequenceLength(this.o5a_1) - 1 | 0;
2653
- if (inductionVariable <= last)
2654
- do {
2655
- var i = inductionVariable;
2656
- inductionVariable = inductionVariable + 1 | 0;
2657
- if (!(charSequenceGet(input, startIndex + i | 0) === charCodeAt(this.o5a_1, i))) {
2658
- var tmp_0 = Companion_instance_6;
2659
- return tmp_0.b5a(startIndex, PlainStringParserOperation$consume$lambda_0(this, input, startIndex, i));
2660
- }
2661
- }
2662
- while (inductionVariable <= last);
2663
- return Companion_instance_6.a5a(startIndex + this.o5a_1.length | 0);
2664
- };
2665
- protoOf(PlainStringParserOperation).toString = function () {
2666
- return "'" + this.o5a_1 + "'";
2667
- };
2668
- function UnconditionalModification() {
2669
- }
2670
- function spaceAndZeroPaddedUnsignedInt$numberOfRequiredLengths($withMinus, $setter, $name, minNumberLength, maxNumberLength) {
2671
- // Inline function 'kotlin.check' call
2672
- if (!(maxNumberLength >= (1 + ($withMinus ? 1 : 0) | 0))) {
2673
- throw IllegalStateException_init_$Create$('Check failed.');
2674
- }
2675
- // Inline function 'kotlin.collections.buildList' call
2676
- // Inline function 'kotlin.collections.buildListInternal' call
2677
- // Inline function 'kotlin.apply' call
2678
- var this_0 = ArrayList_init_$Create$();
2679
- if ($withMinus) {
2680
- this_0.e1(new PlainStringParserOperation('-'));
2681
- }
2682
- this_0.e1(new NumberSpanParserOperation(listOf(new UnsignedIntConsumer(minNumberLength - ($withMinus ? 1 : 0) | 0, maxNumberLength - ($withMinus ? 1 : 0) | 0, $setter, $name, $withMinus))));
2683
- var tmp$ret$4 = this_0.j3();
2684
- return new ParserStructure(tmp$ret$4, emptyList());
2685
- }
2686
- function get_POWERS_OF_TEN() {
2687
- _init_properties_math_kt__tgcmt4();
2688
- return POWERS_OF_TEN;
2689
- }
2690
- var POWERS_OF_TEN;
2691
- var properties_initialized_math_kt_amm9wq;
2692
- function _init_properties_math_kt__tgcmt4() {
2693
- if (!properties_initialized_math_kt_amm9wq) {
2694
- properties_initialized_math_kt_amm9wq = true;
2695
- // Inline function 'kotlin.intArrayOf' call
2696
- POWERS_OF_TEN = new Int32Array([1, 10, 100, 1000, 10000, 100000, 1000000, 10000000, 100000000, 1000000000]);
2697
- }
2698
- }
2699
- function isAsciiDigit(_this__u8e3s4) {
2700
- return _Char___init__impl__6a9atx(48) <= _this__u8e3s4 ? _this__u8e3s4 <= _Char___init__impl__6a9atx(57) : false;
2701
- }
2702
- function asciiDigitToInt(_this__u8e3s4) {
2703
- return Char__minus_impl_a2frrh(_this__u8e3s4, _Char___init__impl__6a9atx(48));
2704
- }
2705
- function TimeBasedDateTimeUnitSerializer$descriptor$delegate$lambda() {
2706
- return buildClassSerialDescriptor('kotlinx.datetime.TimeBased', [], TimeBasedDateTimeUnitSerializer$descriptor$delegate$lambda$lambda);
2707
- }
2708
- function TimeBasedDateTimeUnitSerializer$descriptor$delegate$lambda$lambda($this$buildClassSerialDescriptor) {
2709
- // Inline function 'kotlinx.serialization.descriptors.element' call
2710
- var elementName = 'nanoseconds';
2711
- var annotations = emptyList();
2712
- // Inline function 'kotlinx.serialization.serializer' call
2713
- // Inline function 'kotlinx.serialization.internal.cast' call
2714
- var this_0 = serializer(createKType(PrimitiveClasses_getInstance().jb(), arrayOf([]), false));
2715
- var descriptor = (isInterface(this_0, KSerializer) ? this_0 : THROW_CCE()).z1r();
2716
- $this$buildClassSerialDescriptor.j1u(elementName, descriptor, annotations, false);
2717
- return Unit_instance;
2718
- }
2719
- function TimeBasedDateTimeUnitSerializer$_get_descriptor_$ref_ezonyw() {
2720
- return function (p0) {
2721
- return p0.z1r();
2722
- };
2723
- }
2724
- function TimeBasedDateTimeUnitSerializer() {
2725
- TimeBasedDateTimeUnitSerializer_instance = this;
2726
- var tmp = this;
2727
- var tmp_0 = LazyThreadSafetyMode_PUBLICATION_getInstance();
2728
- tmp.p5a_1 = lazy_0(tmp_0, TimeBasedDateTimeUnitSerializer$descriptor$delegate$lambda);
2729
- }
2730
- protoOf(TimeBasedDateTimeUnitSerializer).z1r = function () {
2731
- var tmp0 = this.p5a_1;
2732
- var tmp = KProperty1;
2733
- // Inline function 'kotlin.getValue' call
2734
- getPropertyCallableRef('descriptor', 1, tmp, TimeBasedDateTimeUnitSerializer$_get_descriptor_$ref_ezonyw(), null);
2735
- return tmp0.m1();
2736
- };
2737
- protoOf(TimeBasedDateTimeUnitSerializer).q5a = function (encoder, value) {
2738
- // Inline function 'kotlinx.serialization.encoding.encodeStructure' call
2739
- var descriptor = this.z1r();
2740
- var composite = encoder.n1v(descriptor);
2741
- composite.y1w(TimeBasedDateTimeUnitSerializer_getInstance().z1r(), 0, value.s53_1);
2742
- composite.o1v(descriptor);
2743
- };
2744
- protoOf(TimeBasedDateTimeUnitSerializer).a1s = function (encoder, value) {
2745
- return this.q5a(encoder, value instanceof TimeBased ? value : THROW_CCE());
2746
- };
2747
- protoOf(TimeBasedDateTimeUnitSerializer).b1s = function (decoder) {
2748
- var seen = {_v: false};
2749
- var nanoseconds = {_v: 0n};
2750
- // Inline function 'kotlinx.serialization.encoding.decodeStructure' call
2751
- var descriptor = this.z1r();
2752
- var composite = decoder.n1v(descriptor);
2753
- if (composite.d1w()) {
2754
- nanoseconds._v = composite.t1v(TimeBasedDateTimeUnitSerializer_getInstance().z1r(), 0);
2755
- seen._v = true;
2756
- } else {
2757
- loop: while (true) {
2758
- var elementIndex = composite.e1w(TimeBasedDateTimeUnitSerializer_getInstance().z1r());
2759
- switch (elementIndex) {
2760
- case 0:
2761
- nanoseconds._v = composite.t1v(TimeBasedDateTimeUnitSerializer_getInstance().z1r(), 0);
2762
- seen._v = true;
2763
- break;
2764
- case -1:
2765
- break loop;
2766
- default:
2767
- throwUnknownIndexException(elementIndex);
2768
- break;
2769
- }
2770
- }
2771
- }
2772
- var result = Unit_instance;
2773
- composite.o1v(descriptor);
2774
- if (!seen._v)
2775
- throw MissingFieldException_init_$Create$('nanoseconds', this.z1r().a1t());
2776
- return new TimeBased(nanoseconds._v);
2777
- };
2778
- var TimeBasedDateTimeUnitSerializer_instance;
2779
- function TimeBasedDateTimeUnitSerializer_getInstance() {
2780
- if (TimeBasedDateTimeUnitSerializer_instance == null)
2781
- new TimeBasedDateTimeUnitSerializer();
2782
- return TimeBasedDateTimeUnitSerializer_instance;
2783
- }
2784
- function _get_impl__d88w17($this) {
2785
- var tmp0 = $this.r5a_1;
2786
- var tmp = KProperty1;
2787
- // Inline function 'kotlin.getValue' call
2788
- getPropertyCallableRef('impl', 1, tmp, DateBasedDateTimeUnitSerializer$_get_impl_$ref_m860rs(), null);
2789
- return tmp0.m1();
2790
- }
2791
- function DateBasedDateTimeUnitSerializer$impl$delegate$lambda() {
2792
- var tmp = getKClass(DateBased);
2793
- // Inline function 'kotlin.arrayOf' call
2794
- // Inline function 'kotlin.js.unsafeCast' call
2795
- // Inline function 'kotlin.js.asDynamic' call
2796
- var tmp_0 = [getKClass(DayBased), getKClass(MonthBased)];
2797
- // Inline function 'kotlin.arrayOf' call
2798
- // Inline function 'kotlin.js.unsafeCast' call
2799
- // Inline function 'kotlin.js.asDynamic' call
2800
- var tmp$ret$5 = [DayBasedDateTimeUnitSerializer_getInstance(), MonthBasedDateTimeUnitSerializer_getInstance()];
2801
- return new SealedClassSerializer('kotlinx.datetime.DateTimeUnit.DateBased', tmp, tmp_0, tmp$ret$5);
2802
- }
2803
- function DateBasedDateTimeUnitSerializer$_get_impl_$ref_m860rs() {
2804
- return function (p0) {
2805
- return _get_impl__d88w17(p0);
2806
- };
2807
- }
2808
- function DateBasedDateTimeUnitSerializer() {
2809
- DateBasedDateTimeUnitSerializer_instance = this;
2810
- AbstractPolymorphicSerializer.call(this);
2811
- var tmp = this;
2812
- var tmp_0 = LazyThreadSafetyMode_PUBLICATION_getInstance();
2813
- tmp.r5a_1 = lazy_0(tmp_0, DateBasedDateTimeUnitSerializer$impl$delegate$lambda);
2814
- }
2815
- protoOf(DateBasedDateTimeUnitSerializer).c1s = function (decoder, klassName) {
2816
- return _get_impl__d88w17(this).c1s(decoder, klassName);
2817
- };
2818
- protoOf(DateBasedDateTimeUnitSerializer).s5a = function (encoder, value) {
2819
- return _get_impl__d88w17(this).e1s(encoder, value);
2820
- };
2821
- protoOf(DateBasedDateTimeUnitSerializer).e1s = function (encoder, value) {
2822
- return this.s5a(encoder, value instanceof DateBased ? value : THROW_CCE());
2823
- };
2824
- protoOf(DateBasedDateTimeUnitSerializer).d1s = function () {
2825
- return getKClass(DateBased);
2826
- };
2827
- protoOf(DateBasedDateTimeUnitSerializer).z1r = function () {
2828
- return _get_impl__d88w17(this).z1r();
2829
- };
2830
- var DateBasedDateTimeUnitSerializer_instance;
2831
- function DateBasedDateTimeUnitSerializer_getInstance() {
2832
- if (DateBasedDateTimeUnitSerializer_instance == null)
2833
- new DateBasedDateTimeUnitSerializer();
2834
- return DateBasedDateTimeUnitSerializer_instance;
2835
- }
2836
- function DayBasedDateTimeUnitSerializer$descriptor$delegate$lambda() {
2837
- return buildClassSerialDescriptor('kotlinx.datetime.DayBased', [], DayBasedDateTimeUnitSerializer$descriptor$delegate$lambda$lambda);
2838
- }
2839
- function DayBasedDateTimeUnitSerializer$descriptor$delegate$lambda$lambda($this$buildClassSerialDescriptor) {
2840
- // Inline function 'kotlinx.serialization.descriptors.element' call
2841
- var annotations = emptyList();
2842
- // Inline function 'kotlinx.serialization.serializer' call
2843
- // Inline function 'kotlinx.serialization.internal.cast' call
2844
- var this_0 = serializer(createKType(PrimitiveClasses_getInstance().ib(), arrayOf([]), false));
2845
- var descriptor = (isInterface(this_0, KSerializer) ? this_0 : THROW_CCE()).z1r();
2846
- $this$buildClassSerialDescriptor.j1u('days', descriptor, annotations, false);
2847
- return Unit_instance;
2848
- }
2849
- function DayBasedDateTimeUnitSerializer$_get_descriptor_$ref_2ycvl3() {
2850
- return function (p0) {
2851
- return p0.z1r();
2852
- };
2853
- }
2854
- function DayBasedDateTimeUnitSerializer() {
2855
- DayBasedDateTimeUnitSerializer_instance = this;
2856
- var tmp = this;
2857
- var tmp_0 = LazyThreadSafetyMode_PUBLICATION_getInstance();
2858
- tmp.t5a_1 = lazy_0(tmp_0, DayBasedDateTimeUnitSerializer$descriptor$delegate$lambda);
2859
- }
2860
- protoOf(DayBasedDateTimeUnitSerializer).z1r = function () {
2861
- var tmp0 = this.t5a_1;
2862
- var tmp = KProperty1;
2863
- // Inline function 'kotlin.getValue' call
2864
- getPropertyCallableRef('descriptor', 1, tmp, DayBasedDateTimeUnitSerializer$_get_descriptor_$ref_2ycvl3(), null);
2865
- return tmp0.m1();
2866
- };
2867
- protoOf(DayBasedDateTimeUnitSerializer).u5a = function (encoder, value) {
2868
- // Inline function 'kotlinx.serialization.encoding.encodeStructure' call
2869
- var descriptor = this.z1r();
2870
- var composite = encoder.n1v(descriptor);
2871
- composite.x1w(DayBasedDateTimeUnitSerializer_getInstance().z1r(), 0, value.y53_1);
2872
- composite.o1v(descriptor);
2873
- };
2874
- protoOf(DayBasedDateTimeUnitSerializer).a1s = function (encoder, value) {
2875
- return this.u5a(encoder, value instanceof DayBased ? value : THROW_CCE());
2876
- };
2877
- protoOf(DayBasedDateTimeUnitSerializer).b1s = function (decoder) {
2878
- var seen = {_v: false};
2879
- var days = {_v: 0};
2880
- // Inline function 'kotlinx.serialization.encoding.decodeStructure' call
2881
- var descriptor = this.z1r();
2882
- var composite = decoder.n1v(descriptor);
2883
- if (composite.d1w()) {
2884
- days._v = composite.s1v(DayBasedDateTimeUnitSerializer_getInstance().z1r(), 0);
2885
- seen._v = true;
2886
- } else {
2887
- loop: while (true) {
2888
- var elementIndex = composite.e1w(DayBasedDateTimeUnitSerializer_getInstance().z1r());
2889
- switch (elementIndex) {
2890
- case 0:
2891
- days._v = composite.s1v(DayBasedDateTimeUnitSerializer_getInstance().z1r(), 0);
2892
- seen._v = true;
2893
- break;
2894
- case -1:
2895
- break loop;
2896
- default:
2897
- throwUnknownIndexException(elementIndex);
2898
- break;
2899
- }
2900
- }
2901
- }
2902
- var result = Unit_instance;
2903
- composite.o1v(descriptor);
2904
- if (!seen._v)
2905
- throw MissingFieldException_init_$Create$('days', this.z1r().a1t());
2906
- return new DayBased(days._v);
2907
- };
2908
- var DayBasedDateTimeUnitSerializer_instance;
2909
- function DayBasedDateTimeUnitSerializer_getInstance() {
2910
- if (DayBasedDateTimeUnitSerializer_instance == null)
2911
- new DayBasedDateTimeUnitSerializer();
2912
- return DayBasedDateTimeUnitSerializer_instance;
2913
- }
2914
- function MonthBasedDateTimeUnitSerializer$descriptor$delegate$lambda() {
2915
- return buildClassSerialDescriptor('kotlinx.datetime.MonthBased', [], MonthBasedDateTimeUnitSerializer$descriptor$delegate$lambda$lambda);
2916
- }
2917
- function MonthBasedDateTimeUnitSerializer$descriptor$delegate$lambda$lambda($this$buildClassSerialDescriptor) {
2918
- // Inline function 'kotlinx.serialization.descriptors.element' call
2919
- var annotations = emptyList();
2920
- // Inline function 'kotlinx.serialization.serializer' call
2921
- // Inline function 'kotlinx.serialization.internal.cast' call
2922
- var this_0 = serializer(createKType(PrimitiveClasses_getInstance().ib(), arrayOf([]), false));
2923
- var descriptor = (isInterface(this_0, KSerializer) ? this_0 : THROW_CCE()).z1r();
2924
- $this$buildClassSerialDescriptor.j1u('months', descriptor, annotations, false);
2925
- return Unit_instance;
2926
- }
2927
- function MonthBasedDateTimeUnitSerializer$_get_descriptor_$ref_vroatn() {
2928
- return function (p0) {
2929
- return p0.z1r();
2930
- };
2931
- }
2932
- function MonthBasedDateTimeUnitSerializer() {
2933
- MonthBasedDateTimeUnitSerializer_instance = this;
2934
- var tmp = this;
2935
- var tmp_0 = LazyThreadSafetyMode_PUBLICATION_getInstance();
2936
- tmp.v5a_1 = lazy_0(tmp_0, MonthBasedDateTimeUnitSerializer$descriptor$delegate$lambda);
2937
- }
2938
- protoOf(MonthBasedDateTimeUnitSerializer).z1r = function () {
2939
- var tmp0 = this.v5a_1;
2940
- var tmp = KProperty1;
2941
- // Inline function 'kotlin.getValue' call
2942
- getPropertyCallableRef('descriptor', 1, tmp, MonthBasedDateTimeUnitSerializer$_get_descriptor_$ref_vroatn(), null);
2943
- return tmp0.m1();
2944
- };
2945
- protoOf(MonthBasedDateTimeUnitSerializer).w5a = function (encoder, value) {
2946
- // Inline function 'kotlinx.serialization.encoding.encodeStructure' call
2947
- var descriptor = this.z1r();
2948
- var composite = encoder.n1v(descriptor);
2949
- composite.x1w(MonthBasedDateTimeUnitSerializer_getInstance().z1r(), 0, value.z53_1);
2950
- composite.o1v(descriptor);
2951
- };
2952
- protoOf(MonthBasedDateTimeUnitSerializer).a1s = function (encoder, value) {
2953
- return this.w5a(encoder, value instanceof MonthBased ? value : THROW_CCE());
2954
- };
2955
- protoOf(MonthBasedDateTimeUnitSerializer).b1s = function (decoder) {
2956
- var seen = {_v: false};
2957
- var months = {_v: 0};
2958
- // Inline function 'kotlinx.serialization.encoding.decodeStructure' call
2959
- var descriptor = this.z1r();
2960
- var composite = decoder.n1v(descriptor);
2961
- if (composite.d1w()) {
2962
- months._v = composite.s1v(MonthBasedDateTimeUnitSerializer_getInstance().z1r(), 0);
2963
- seen._v = true;
2964
- } else {
2965
- loop: while (true) {
2966
- var elementIndex = composite.e1w(MonthBasedDateTimeUnitSerializer_getInstance().z1r());
2967
- switch (elementIndex) {
2968
- case 0:
2969
- months._v = composite.s1v(MonthBasedDateTimeUnitSerializer_getInstance().z1r(), 0);
2970
- seen._v = true;
2971
- break;
2972
- case -1:
2973
- break loop;
2974
- default:
2975
- throwUnknownIndexException(elementIndex);
2976
- break;
2977
- }
2978
- }
2979
- }
2980
- var result = Unit_instance;
2981
- composite.o1v(descriptor);
2982
- if (!seen._v)
2983
- throw MissingFieldException_init_$Create$('months', this.z1r().a1t());
2984
- return new MonthBased(months._v);
2985
- };
2986
- var MonthBasedDateTimeUnitSerializer_instance;
2987
- function MonthBasedDateTimeUnitSerializer_getInstance() {
2988
- if (MonthBasedDateTimeUnitSerializer_instance == null)
2989
- new MonthBasedDateTimeUnitSerializer();
2990
- return MonthBasedDateTimeUnitSerializer_instance;
2991
- }
2992
- function _get_impl__d88w17_0($this) {
2993
- var tmp0 = $this.x5a_1;
2994
- var tmp = KProperty1;
2995
- // Inline function 'kotlin.getValue' call
2996
- getPropertyCallableRef('impl', 1, tmp, DateTimeUnitSerializer$_get_impl_$ref_2y1hvx(), null);
2997
- return tmp0.m1();
2998
- }
2999
- function DateTimeUnitSerializer$impl$delegate$lambda() {
3000
- var tmp = getKClass(DateTimeUnit);
3001
- // Inline function 'kotlin.arrayOf' call
3002
- // Inline function 'kotlin.js.unsafeCast' call
3003
- // Inline function 'kotlin.js.asDynamic' call
3004
- var tmp_0 = [getKClass(DayBased), getKClass(MonthBased), getKClass(TimeBased)];
3005
- // Inline function 'kotlin.arrayOf' call
3006
- // Inline function 'kotlin.js.unsafeCast' call
3007
- // Inline function 'kotlin.js.asDynamic' call
3008
- var tmp$ret$5 = [DayBasedDateTimeUnitSerializer_getInstance(), MonthBasedDateTimeUnitSerializer_getInstance(), TimeBasedDateTimeUnitSerializer_getInstance()];
3009
- return new SealedClassSerializer('kotlinx.datetime.DateTimeUnit', tmp, tmp_0, tmp$ret$5);
3010
- }
3011
- function DateTimeUnitSerializer$_get_impl_$ref_2y1hvx() {
3012
- return function (p0) {
3013
- return _get_impl__d88w17_0(p0);
3014
- };
3015
- }
3016
- function DateTimeUnitSerializer() {
3017
- DateTimeUnitSerializer_instance = this;
3018
- AbstractPolymorphicSerializer.call(this);
3019
- var tmp = this;
3020
- var tmp_0 = LazyThreadSafetyMode_PUBLICATION_getInstance();
3021
- tmp.x5a_1 = lazy_0(tmp_0, DateTimeUnitSerializer$impl$delegate$lambda);
3022
- }
3023
- protoOf(DateTimeUnitSerializer).c1s = function (decoder, klassName) {
3024
- return _get_impl__d88w17_0(this).c1s(decoder, klassName);
3025
- };
3026
- protoOf(DateTimeUnitSerializer).y5a = function (encoder, value) {
3027
- return _get_impl__d88w17_0(this).e1s(encoder, value);
3028
- };
3029
- protoOf(DateTimeUnitSerializer).e1s = function (encoder, value) {
3030
- return this.y5a(encoder, value instanceof DateTimeUnit ? value : THROW_CCE());
3031
- };
3032
- protoOf(DateTimeUnitSerializer).d1s = function () {
3033
- return getKClass(DateTimeUnit);
3034
- };
3035
- protoOf(DateTimeUnitSerializer).z1r = function () {
3036
- return _get_impl__d88w17_0(this).z1r();
3037
- };
3038
- var DateTimeUnitSerializer_instance;
3039
- function DateTimeUnitSerializer_getInstance() {
3040
- if (DateTimeUnitSerializer_instance == null)
3041
- new DateTimeUnitSerializer();
3042
- return DateTimeUnitSerializer_instance;
3043
- }
3044
- function throwUnknownIndexException(index) {
3045
- throw SerializationException_init_$Create$('An unknown field for index ' + index);
3046
- }
3047
- function LocalDateSerializer() {
3048
- LocalDateSerializer_instance = this;
3049
- this.z5a_1 = PrimitiveSerialDescriptor('kotlinx.datetime.LocalDate', STRING_getInstance());
3050
- }
3051
- protoOf(LocalDateSerializer).z1r = function () {
3052
- return this.z5a_1;
3053
- };
3054
- protoOf(LocalDateSerializer).b1s = function (decoder) {
3055
- return Companion_getInstance_7().e5b(decoder.i1v());
3056
- };
3057
- protoOf(LocalDateSerializer).f5b = function (encoder, value) {
3058
- encoder.r1w(value.toString());
3059
- };
3060
- protoOf(LocalDateSerializer).a1s = function (encoder, value) {
3061
- return this.f5b(encoder, value instanceof LocalDate ? value : THROW_CCE());
3062
- };
3063
- var LocalDateSerializer_instance;
3064
- function LocalDateSerializer_getInstance() {
3065
- if (LocalDateSerializer_instance == null)
3066
- new LocalDateSerializer();
3067
- return LocalDateSerializer_instance;
3068
- }
3069
- function YearMonthSerializer() {
3070
- YearMonthSerializer_instance = this;
3071
- this.g5b_1 = PrimitiveSerialDescriptor('kotlinx.datetime.YearMonth', STRING_getInstance());
3072
- }
3073
- protoOf(YearMonthSerializer).z1r = function () {
3074
- return this.g5b_1;
3075
- };
3076
- protoOf(YearMonthSerializer).b1s = function (decoder) {
3077
- return Companion_instance_8.h5b(decoder.i1v());
3078
- };
3079
- protoOf(YearMonthSerializer).i5b = function (encoder, value) {
3080
- encoder.r1w(value.toString());
3081
- };
3082
- protoOf(YearMonthSerializer).a1s = function (encoder, value) {
3083
- return this.i5b(encoder, value instanceof YearMonth ? value : THROW_CCE());
3084
- };
3085
- var YearMonthSerializer_instance;
3086
- function YearMonthSerializer_getInstance() {
3087
- if (YearMonthSerializer_instance == null)
3088
- new YearMonthSerializer();
3089
- return YearMonthSerializer_instance;
3090
- }
3091
- function Companion_7() {
3092
- Companion_instance_7 = this;
3093
- this.a5b_1 = new LocalDate(-999999999, 1, 1);
3094
- this.b5b_1 = new LocalDate(999999999, 12, 31);
3095
- this.c5b_1 = -365243219162n;
3096
- this.d5b_1 = 365241780471n;
3097
- }
3098
- protoOf(Companion_7).j5b = function (input, format) {
3099
- return format.al(input);
3100
- };
3101
- protoOf(Companion_7).e5b = function (input, format, $super) {
3102
- format = format === VOID ? getIsoDateFormat() : format;
3103
- return $super === VOID ? this.j5b(input, format) : $super.j5b.call(this, input, format);
3104
- };
3105
- protoOf(Companion_7).k5b = function (epochDays) {
3106
- // Inline function 'kotlin.require' call
3107
- if (!(-365243219162n <= epochDays ? epochDays <= 365241780471n : false)) {
3108
- var message = 'Invalid date: epoch day ' + epochDays.toString() + ' is outside the boundaries of LocalDate';
3109
- throw IllegalArgumentException_init_$Create$(toString(message));
3110
- }
3111
- // Inline function 'kotlin.Long.plus' call
3112
- var zeroDay = add(epochDays, fromInt(719528));
3113
- // Inline function 'kotlin.Long.minus' call
3114
- var this_0 = zeroDay;
3115
- zeroDay = subtract(this_0, fromInt(60));
3116
- var adjust = 0n;
3117
- if (zeroDay < 0n) {
3118
- // Inline function 'kotlin.Long.plus' call
3119
- var this_1 = zeroDay;
3120
- // Inline function 'kotlin.Long.div' call
3121
- var this_2 = add(this_1, fromInt(1));
3122
- // Inline function 'kotlin.Long.minus' call
3123
- var this_3 = divide(this_2, fromInt(146097));
3124
- var adjustCycles = subtract(this_3, fromInt(1));
3125
- // Inline function 'kotlin.Long.times' call
3126
- adjust = multiply(adjustCycles, fromInt(400));
3127
- var tmp = zeroDay;
3128
- // Inline function 'kotlin.Long.times' call
3129
- var this_4 = negate(adjustCycles);
3130
- var tmp$ret$8 = multiply(this_4, fromInt(146097));
3131
- zeroDay = add(tmp, tmp$ret$8);
3132
- }
3133
- // Inline function 'kotlin.Long.plus' call
3134
- var this_5 = multiply(numberToLong(400), zeroDay);
3135
- // Inline function 'kotlin.Long.div' call
3136
- var this_6 = add(this_5, fromInt(591));
3137
- var yearEst = divide(this_6, fromInt(146097));
3138
- var tmp_0 = zeroDay;
3139
- var tmp_1 = multiply(numberToLong(365), yearEst);
3140
- // Inline function 'kotlin.Long.div' call
3141
- var this_7 = yearEst;
3142
- var tmp$ret$11 = divide(this_7, fromInt(4));
3143
- var tmp_2 = add(tmp_1, tmp$ret$11);
3144
- // Inline function 'kotlin.Long.div' call
3145
- var this_8 = yearEst;
3146
- var tmp$ret$12 = divide(this_8, fromInt(100));
3147
- var tmp_3 = subtract(tmp_2, tmp$ret$12);
3148
- // Inline function 'kotlin.Long.div' call
3149
- var this_9 = yearEst;
3150
- var tmp$ret$13 = divide(this_9, fromInt(400));
3151
- var doyEst = subtract(tmp_0, add(tmp_3, tmp$ret$13));
3152
- if (doyEst < 0n) {
3153
- var _unary__edvuaz = yearEst;
3154
- yearEst = subtract(_unary__edvuaz, get_ONE());
3155
- var tmp_4 = zeroDay;
3156
- var tmp_5 = multiply(numberToLong(365), yearEst);
3157
- // Inline function 'kotlin.Long.div' call
3158
- var this_10 = yearEst;
3159
- var tmp$ret$14 = divide(this_10, fromInt(4));
3160
- var tmp_6 = add(tmp_5, tmp$ret$14);
3161
- // Inline function 'kotlin.Long.div' call
3162
- var this_11 = yearEst;
3163
- var tmp$ret$15 = divide(this_11, fromInt(100));
3164
- var tmp_7 = subtract(tmp_6, tmp$ret$15);
3165
- // Inline function 'kotlin.Long.div' call
3166
- var this_12 = yearEst;
3167
- var tmp$ret$16 = divide(this_12, fromInt(400));
3168
- doyEst = subtract(tmp_4, add(tmp_7, tmp$ret$16));
3169
- }
3170
- yearEst = add(yearEst, adjust);
3171
- var marchDoy0 = convertToInt(doyEst);
3172
- var marchMonth0 = (imul(marchDoy0, 5) + 2 | 0) / 153 | 0;
3173
- var month = ((marchMonth0 + 2 | 0) % 12 | 0) + 1 | 0;
3174
- var dom = (marchDoy0 - ((imul(marchMonth0, 306) + 5 | 0) / 10 | 0) | 0) + 1 | 0;
3175
- var tmp0 = yearEst;
3176
- // Inline function 'kotlin.Long.plus' call
3177
- var other = marchMonth0 / 10 | 0;
3178
- yearEst = add(tmp0, fromInt(other));
3179
- return new LocalDate(convertToInt(yearEst), month, dom);
3180
- };
3181
- var Companion_instance_7;
3182
- function Companion_getInstance_7() {
3183
- if (Companion_instance_7 == null)
3184
- new Companion_7();
3185
- return Companion_instance_7;
3186
- }
3187
- function Formats() {
3188
- Formats_instance = this;
3189
- this.m54_1 = get_ISO_DATE_BASIC();
3190
- }
3191
- protoOf(Formats).n54 = function () {
3192
- return get_ISO_DATE();
3193
- };
3194
- var Formats_instance;
3195
- function Formats_getInstance() {
3196
- if (Formats_instance == null)
3197
- new Formats();
3198
- return Formats_instance;
3199
- }
3200
- function resolvePreviousValid($this, year, month, day) {
3201
- // Inline function 'kotlin.math.min' call
3202
- var b = monthLength(month, isLeapYear(year));
3203
- var newDay = Math.min(day, b);
3204
- return new LocalDate(year, month, newDay);
3205
- }
3206
- function LocalDate(year, month, day) {
3207
- Companion_getInstance_7();
3208
- this.w55_1 = year;
3209
- this.x55_1 = day;
3210
- this.y55_1 = month;
3211
- // Inline function 'kotlin.require' call
3212
- if (!isValidYear(this.w55_1)) {
3213
- var message = 'Invalid date: the year is out of range';
3214
- throw IllegalArgumentException_init_$Create$(toString(message));
3215
- }
3216
- var containsArg = this.y55_1;
3217
- // Inline function 'kotlin.require' call
3218
- if (!(1 <= containsArg ? containsArg <= 12 : false)) {
3219
- var message_0 = 'Invalid date: month must be a number between 1 and 12, got ' + this.y55_1;
3220
- throw IllegalArgumentException_init_$Create$(toString(message_0));
3221
- }
3222
- var containsArg_0 = this.x55_1;
3223
- // Inline function 'kotlin.require' call
3224
- if (!(1 <= containsArg_0 ? containsArg_0 <= 31 : false)) {
3225
- var message_1 = 'Invalid date: day of month must be a number between 1 and 31, got ' + this.x55_1;
3226
- throw IllegalArgumentException_init_$Create$(toString(message_1));
3227
- }
3228
- if (this.x55_1 > 28 && this.x55_1 > monthLength(this.y55_1, isLeapYear(this.w55_1))) {
3229
- if (this.x55_1 === 29) {
3230
- throw IllegalArgumentException_init_$Create$("Invalid date 'February 29' as '" + this.w55_1 + "' is not a leap year");
3231
- } else {
3232
- throw IllegalArgumentException_init_$Create$("Invalid date '" + Month_0(month).toString() + ' ' + this.x55_1 + "'");
3233
- }
3234
- }
3235
- }
3236
- protoOf(LocalDate).l5b = function () {
3237
- var y = fromInt(this.w55_1);
3238
- var m = fromInt(this.y55_1);
3239
- var total = 0n;
3240
- total = add(total, multiply(numberToLong(365), y));
3241
- if (y >= 0n) {
3242
- var tmp = total;
3243
- // Inline function 'kotlin.Long.plus' call
3244
- // Inline function 'kotlin.Long.div' call
3245
- var this_0 = add(y, fromInt(3));
3246
- var tmp_0 = divide(this_0, fromInt(4));
3247
- // Inline function 'kotlin.Long.plus' call
3248
- // Inline function 'kotlin.Long.div' call
3249
- var this_1 = add(y, fromInt(99));
3250
- var tmp$ret$3 = divide(this_1, fromInt(100));
3251
- var tmp_1 = subtract(tmp_0, tmp$ret$3);
3252
- // Inline function 'kotlin.Long.plus' call
3253
- // Inline function 'kotlin.Long.div' call
3254
- var this_2 = add(y, fromInt(399));
3255
- var tmp$ret$5 = divide(this_2, fromInt(400));
3256
- total = add(tmp, add(tmp_1, tmp$ret$5));
3257
- } else {
3258
- var tmp_2 = total;
3259
- // Inline function 'kotlin.Long.div' call
3260
- var tmp_3 = divide(y, fromInt(-4));
3261
- // Inline function 'kotlin.Long.div' call
3262
- var tmp$ret$7 = divide(y, fromInt(-100));
3263
- var tmp_4 = subtract(tmp_3, tmp$ret$7);
3264
- // Inline function 'kotlin.Long.div' call
3265
- var tmp$ret$8 = divide(y, fromInt(-400));
3266
- total = subtract(tmp_2, add(tmp_4, tmp$ret$8));
3267
- }
3268
- var tmp_5 = total;
3269
- // Inline function 'kotlin.Long.minus' call
3270
- var this_3 = multiply(numberToLong(367), m);
3271
- // Inline function 'kotlin.Long.div' call
3272
- var this_4 = subtract(this_3, fromInt(362));
3273
- var tmp$ret$10 = divide(this_4, fromInt(12));
3274
- total = add(tmp_5, tmp$ret$10);
3275
- var tmp0 = total;
3276
- // Inline function 'kotlin.Long.plus' call
3277
- var other = this.x55_1 - 1 | 0;
3278
- total = add(tmp0, fromInt(other));
3279
- if (m > 2n) {
3280
- var _unary__edvuaz = total;
3281
- total = subtract(_unary__edvuaz, get_ONE());
3282
- if (!isLeapYear(this.w55_1)) {
3283
- var _unary__edvuaz_0 = total;
3284
- total = subtract(_unary__edvuaz_0, get_ONE());
3285
- }
3286
- }
3287
- // Inline function 'kotlin.Long.minus' call
3288
- var this_5 = total;
3289
- return subtract(this_5, fromInt(719528));
3290
- };
3291
- protoOf(LocalDate).z55 = function () {
3292
- return Month_0(this.y55_1);
3293
- };
3294
- protoOf(LocalDate).r55 = function () {
3295
- // Inline function 'kotlin.Long.plus' call
3296
- var this_0 = this.l5b();
3297
- // Inline function 'kotlin.mod' call
3298
- var tmp0 = add(this_0, fromInt(3));
3299
- // Inline function 'kotlin.mod' call
3300
- var other = fromInt(7);
3301
- var r = modulo(tmp0, other);
3302
- var tmp$ret$1 = add(r, other & shiftRight((r ^ other) & (r | negate(r)), 63));
3303
- var dow0 = convertToInt(tmp$ret$1);
3304
- return DayOfWeek_0(dow0 + 1 | 0);
3305
- };
3306
- protoOf(LocalDate).t55 = function () {
3307
- return (firstDayOfYear(this.z55(), isLeapYear(this.w55_1)) + this.x55_1 | 0) - 1 | 0;
3308
- };
3309
- protoOf(LocalDate).m5b = function (other) {
3310
- var y = compareTo(this.w55_1, other.w55_1);
3311
- if (!(y === 0)) {
3312
- return y;
3313
- }
3314
- var m = compareTo(this.y55_1, other.y55_1);
3315
- if (!(m === 0)) {
3316
- return m;
3317
- }
3318
- return compareTo(this.x55_1, other.x55_1);
3319
- };
3320
- protoOf(LocalDate).d = function (other) {
3321
- return this.m5b(other instanceof LocalDate ? other : THROW_CCE());
3322
- };
3323
- protoOf(LocalDate).n5b = function (monthsToAdd) {
3324
- if (monthsToAdd === 0n) {
3325
- return this;
3326
- }
3327
- var tmp0 = multiply(numberToLong(this.w55_1), 12n);
3328
- // Inline function 'kotlin.Long.plus' call
3329
- var other = this.y55_1 - 1 | 0;
3330
- var monthCount = add(tmp0, fromInt(other));
3331
- var calcMonths = safeAdd(monthCount, monthsToAdd);
3332
- // Inline function 'kotlin.floorDiv' call
3333
- // Inline function 'kotlin.floorDiv' call
3334
- var other_0 = fromInt(12);
3335
- var q = divide(calcMonths, other_0);
3336
- if ((calcMonths ^ other_0) < 0n && !(multiply(q, other_0) === calcMonths)) {
3337
- var _unary__edvuaz = q;
3338
- q = subtract(_unary__edvuaz, get_ONE());
3339
- }
3340
- var newYear = q;
3341
- // Inline function 'kotlin.ranges.contains' call
3342
- var this_0 = numberRangeToNumber(-999999999, 999999999);
3343
- if (!contains(isInterface(this_0, ClosedRange) ? this_0 : THROW_CCE(), newYear)) {
3344
- throw IllegalArgumentException_init_$Create$('The result of adding ' + monthsToAdd.toString() + ' months to ' + this.toString() + ' is out of LocalDate range.');
3345
- }
3346
- // Inline function 'kotlin.mod' call
3347
- // Inline function 'kotlin.mod' call
3348
- var other_1 = fromInt(12);
3349
- var r = modulo(calcMonths, other_1);
3350
- var tmp$ret$4 = add(r, other_1 & shiftRight((r ^ other_1) & (r | negate(r)), 63));
3351
- var newMonth = convertToInt(tmp$ret$4) + 1 | 0;
3352
- return resolvePreviousValid(this, convertToInt(newYear), newMonth, this.x55_1);
3353
- };
3354
- protoOf(LocalDate).o5b = function (daysToAdd) {
3355
- return daysToAdd === 0n ? this : Companion_getInstance_7().k5b(safeAdd(this.l5b(), daysToAdd));
3356
- };
3357
- protoOf(LocalDate).equals = function (other) {
3358
- var tmp;
3359
- if (this === other) {
3360
- tmp = true;
3361
- } else {
3362
- var tmp_0;
3363
- if (other instanceof LocalDate) {
3364
- tmp_0 = this.m5b(other) === 0;
3365
- } else {
3366
- tmp_0 = false;
3367
- }
3368
- tmp = tmp_0;
3369
- }
3370
- return tmp;
3371
- };
3372
- protoOf(LocalDate).hashCode = function () {
3373
- var yearValue = this.w55_1;
3374
- var monthValue = this.y55_1;
3375
- var dayValue = this.x55_1;
3376
- return yearValue & -2048 ^ (((yearValue << 11) + (monthValue << 6) | 0) + dayValue | 0);
3377
- };
3378
- protoOf(LocalDate).toString = function () {
3379
- return format(this, Formats_getInstance().n54());
3380
- };
3381
- function isValidYear(year) {
3382
- return year >= -999999999 && year <= 999999999;
3383
- }
3384
- function plus_1(_this__u8e3s4, value, unit) {
3385
- var tmp;
3386
- try {
3387
- var tmp_0;
3388
- if (unit instanceof DayBased) {
3389
- tmp_0 = _this__u8e3s4.o5b(safeMultiply(value, fromInt(unit.y53_1)));
3390
- } else {
3391
- if (unit instanceof MonthBased) {
3392
- tmp_0 = _this__u8e3s4.n5b(safeMultiply(value, fromInt(unit.z53_1)));
3393
- } else {
3394
- noWhenBranchMatchedException();
3395
- }
3396
- }
3397
- tmp = tmp_0;
3398
- } catch ($p) {
3399
- var tmp_1;
3400
- if ($p instanceof ArithmeticException) {
3401
- var e = $p;
3402
- throw DateTimeArithmeticException_init_$Create$_0('Arithmetic overflow when adding a value to a date', e);
3403
- } else {
3404
- if ($p instanceof IllegalArgumentException) {
3405
- var e_0 = $p;
3406
- throw DateTimeArithmeticException_init_$Create$_0('Boundaries of LocalDate exceeded when adding a value', e_0);
3407
- } else {
3408
- throw $p;
3409
- }
3410
- }
3411
- }
3412
- return tmp;
3413
- }
3414
- function firstDayOfYear(_this__u8e3s4, leapYear) {
3415
- var leap = leapYear ? 1 : 0;
3416
- var tmp;
3417
- switch (_this__u8e3s4.a1_1) {
3418
- case 0:
3419
- tmp = 1;
3420
- break;
3421
- case 1:
3422
- tmp = 32;
3423
- break;
3424
- case 2:
3425
- tmp = 60 + leap | 0;
3426
- break;
3427
- case 3:
3428
- tmp = 91 + leap | 0;
3429
- break;
3430
- case 4:
3431
- tmp = 121 + leap | 0;
3432
- break;
3433
- case 5:
3434
- tmp = 152 + leap | 0;
3435
- break;
3436
- case 6:
3437
- tmp = 182 + leap | 0;
3438
- break;
3439
- case 7:
3440
- tmp = 213 + leap | 0;
3441
- break;
3442
- case 8:
3443
- tmp = 244 + leap | 0;
3444
- break;
3445
- case 9:
3446
- tmp = 274 + leap | 0;
3447
- break;
3448
- case 10:
3449
- tmp = 305 + leap | 0;
3450
- break;
3451
- case 11:
3452
- tmp = 335 + leap | 0;
3453
- break;
3454
- default:
3455
- noWhenBranchMatchedException();
3456
- break;
3457
- }
3458
- return tmp;
3459
- }
3460
- function Companion_8() {
3461
- }
3462
- protoOf(Companion_8).p5b = function (input, format) {
3463
- return format.al(input);
3464
- };
3465
- protoOf(Companion_8).h5b = function (input, format, $super) {
3466
- format = format === VOID ? Formats_instance_0.n54() : format;
3467
- return $super === VOID ? this.p5b(input, format) : $super.p5b.call(this, input, format);
3468
- };
3469
- var Companion_instance_8;
3470
- function Companion_getInstance_8() {
3471
- return Companion_instance_8;
3472
- }
3473
- function Formats_0() {
3474
- }
3475
- protoOf(Formats_0).n54 = function () {
3476
- return get_ISO_YEAR_MONTH();
3477
- };
3478
- var Formats_instance_0;
3479
- function Formats_getInstance_0() {
3480
- return Formats_instance_0;
3481
- }
3482
- function YearMonth$_get_year_$ref_chp4n6() {
3483
- return function (p0) {
3484
- return p0.c57_1;
3485
- };
3486
- }
3487
- function YearMonth$_get_month_$ref_9rphhd() {
3488
- return function (p0) {
3489
- return p0.z55();
3490
- };
3491
- }
3492
- function YearMonth(year, month) {
3493
- this.c57_1 = year;
3494
- this.d57_1 = month;
3495
- // Inline function 'kotlin.require' call
3496
- if (!(1 <= month ? month <= 12 : false)) {
3497
- var message = 'Month must be in 1..12, but was ' + month;
3498
- throw IllegalArgumentException_init_$Create$(toString(message));
3499
- }
3500
- var containsLower = Companion_getInstance_7().a5b_1.w55_1;
3501
- var containsUpper = Companion_getInstance_7().b5b_1.w55_1;
3502
- var containsArg = this.c57_1;
3503
- // Inline function 'kotlin.require' call
3504
- if (!(containsLower <= containsArg ? containsArg <= containsUpper : false)) {
3505
- var message_0 = 'Year ' + this.c57_1 + ' is out of range: ' + Companion_getInstance_7().a5b_1.w55_1 + '..' + Companion_getInstance_7().b5b_1.w55_1;
3506
- throw IllegalArgumentException_init_$Create$(toString(message_0));
3507
- }
3508
- }
3509
- protoOf(YearMonth).z55 = function () {
3510
- return Month_0(this.d57_1);
3511
- };
3512
- protoOf(YearMonth).q5b = function (other) {
3513
- var tmp = KProperty1;
3514
- var tmp_0 = getPropertyCallableRef('year', 1, tmp, YearMonth$_get_year_$ref_chp4n6(), null);
3515
- var tmp_1 = KProperty1;
3516
- return compareValuesBy(this, other, [tmp_0, getPropertyCallableRef('month', 1, tmp_1, YearMonth$_get_month_$ref_9rphhd(), null)]);
3517
- };
3518
- protoOf(YearMonth).d = function (other) {
3519
- return this.q5b(other instanceof YearMonth ? other : THROW_CCE());
3520
- };
3521
- protoOf(YearMonth).toString = function () {
3522
- return Formats_instance_0.n54().o54(this);
3523
- };
3524
- protoOf(YearMonth).equals = function (other) {
3525
- var tmp;
3526
- var tmp_0;
3527
- if (other instanceof YearMonth) {
3528
- tmp_0 = this.c57_1 === other.c57_1;
3529
- } else {
3530
- tmp_0 = false;
3531
- }
3532
- if (tmp_0) {
3533
- tmp = this.z55().equals(other.z55());
3534
- } else {
3535
- tmp = false;
3536
- }
3537
- return tmp;
3538
- };
3539
- protoOf(YearMonth).hashCode = function () {
3540
- return imul(this.c57_1, 31) + this.z55().hashCode() | 0;
3541
- };
3542
- function safeAdd(a, b) {
3543
- var sum = add(a, b);
3544
- if ((a ^ sum) < 0n && (a ^ b) >= 0n) {
3545
- throw ArithmeticException_init_$Create$('Addition overflows a long: ' + a.toString() + ' + ' + b.toString());
3546
- }
3547
- return sum;
3548
- }
3549
- function safeMultiply(a, b) {
3550
- if (b === 1n) {
3551
- return a;
3552
- }
3553
- if (a === 1n) {
3554
- return b;
3555
- }
3556
- if (a === 0n || b === 0n) {
3557
- return 0n;
3558
- }
3559
- var total = multiply(a, b);
3560
- if (!(divide(total, b) === a) || (a === -9223372036854775808n && b === -1n) || (b === -9223372036854775808n && a === -1n)) {
3561
- throw ArithmeticException_init_$Create$('Multiplication overflows a long: ' + a.toString() + ' * ' + b.toString());
3562
- }
3563
- return total;
3564
- }
3565
- function safeMultiply_0(a, b) {
3566
- var total = multiply(fromInt(a), fromInt(b));
3567
- if (total < -2147483648n || total > 2147483647n) {
3568
- throw ArithmeticException_init_$Create$('Multiplication overflows an int: ' + a + ' * ' + b);
3569
- }
3570
- return convertToInt(total);
3571
- }
3572
- //region block: post-declaration
3573
- protoOf(Builder).d55 = chars;
3574
- protoOf(Builder).i2l = build;
3575
- protoOf(Builder).k56 = addFormatStructureForYearMonth;
3576
- protoOf(Builder).e55 = day;
3577
- protoOf(Builder).f55 = day$default;
3578
- protoOf(Builder).z54 = year;
3579
- protoOf(Builder).a55 = year$default;
3580
- protoOf(Builder).b55 = monthNumber;
3581
- protoOf(Builder).c55 = monthNumber$default;
3582
- protoOf(Builder_0).d55 = chars;
3583
- protoOf(Builder_0).i2l = build;
3584
- protoOf(Builder_0).z54 = year;
3585
- protoOf(Builder_0).a55 = year$default;
3586
- protoOf(Builder_0).b55 = monthNumber;
3587
- protoOf(Builder_0).c55 = monthNumber$default;
3588
- protoOf(PropertyAccessor).c58 = getterNotNull;
3589
- protoOf(SpacePaddedFormatter).x54 = format$default;
3590
- protoOf(ConcatenatedFormatter).x54 = format$default;
3591
- protoOf(UnsignedIntFormatterStructure).x54 = format$default;
3592
- protoOf(SignedIntFormatterStructure).x54 = format$default;
3593
- protoOf(ConstantStringFormatterStructure).x54 = format$default;
3594
- //endregion
3595
- //region block: init
3596
- Companion_instance = new Companion();
3597
- Companion_instance_0 = new Companion_0();
3598
- Companion_instance_1 = new Companion_1();
3599
- Companion_instance_2 = new Companion_2();
3600
- Companion_instance_4 = new Companion_4();
3601
- Companion_instance_5 = new Companion_5();
3602
- ExpectedInt_instance = new ExpectedInt();
3603
- Companion_instance_6 = new Companion_6();
3604
- Companion_instance_8 = new Companion_8();
3605
- Formats_instance_0 = new Formats_0();
3606
- //endregion
3607
- //region block: exports
3608
- _.$_$ = _.$_$ || {};
3609
- _.$_$.a = LocalDateSerializer_getInstance;
3610
- //endregion
3611
- return _;
3612
- }));
3613
-
3614
- //# sourceMappingURL=Kotlin-DateTime-library-kotlinx-datetime.js.map