@js-joda/core 5.7.0 → 6.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/js-joda.js CHANGED
@@ -1,4 +1,4 @@
1
- //! @version @js-joda/core - 5.7.0
1
+ //! @version @js-joda/core - 6.0.1
2
2
  //! @copyright (c) 2015-present, Philipp Thürwächter, Pattrick Hüper & js-joda contributors
3
3
  //! @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
4
4
  //! @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
@@ -76,23 +76,17 @@
76
76
  };
77
77
  }
78
78
 
79
- function _inheritsLoose(subClass, superClass) {
80
- subClass.prototype = Object.create(superClass.prototype);
81
- subClass.prototype.constructor = subClass;
82
- _setPrototypeOf(subClass, superClass);
79
+ function _assertThisInitialized(e) {
80
+ if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
81
+ return e;
83
82
  }
84
- function _setPrototypeOf(o, p) {
85
- _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
86
- o.__proto__ = p;
87
- return o;
88
- };
89
- return _setPrototypeOf(o, p);
83
+ function _inheritsLoose(t, o) {
84
+ t.prototype = Object.create(o.prototype), t.prototype.constructor = t, _setPrototypeOf(t, o);
90
85
  }
91
- function _assertThisInitialized(self) {
92
- if (self === void 0) {
93
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
94
- }
95
- return self;
86
+ function _setPrototypeOf(t, e) {
87
+ return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) {
88
+ return t.__proto__ = e, t;
89
+ }, _setPrototypeOf(t, e);
96
90
  }
97
91
 
98
92
  /**
@@ -211,18 +205,10 @@
211
205
  }
212
206
  return r;
213
207
  };
214
- MathUtil.parseInt = function (_parseInt) {
215
- function parseInt(_x) {
216
- return _parseInt.apply(this, arguments);
217
- }
218
- parseInt.toString = function () {
219
- return _parseInt.toString();
220
- };
221
- return parseInt;
222
- }(function (value) {
208
+ MathUtil.parseInt = function (value) {
223
209
  var r = parseInt(value);
224
210
  return MathUtil.safeToInt(r);
225
- });
211
+ };
226
212
  MathUtil.safeToInt = function safeToInt(value) {
227
213
  MathUtil.verifyInt(value);
228
214
  return MathUtil.safeZero(value);
@@ -234,11 +220,7 @@
234
220
  if (isNaN(value)) {
235
221
  throw new ArithmeticException('Invalid int value, using NaN as argument');
236
222
  }
237
- if (Number.isInteger) {
238
- if (!Number.isInteger(Number(value))) {
239
- throw new ArithmeticException("Invalid value: '" + value + "' is a float");
240
- }
241
- } else if (value % 1 !== 0) {
223
+ if (!Number.isInteger(Number(value))) {
242
224
  throw new ArithmeticException("Invalid value: '" + value + "' is a float");
243
225
  }
244
226
  if (value > MAX_SAFE_INTEGER || value < MIN_SAFE_INTEGER) {
@@ -373,7 +355,6 @@
373
355
  }();
374
356
 
375
357
  var Duration = function (_TemporalAmount) {
376
- _inheritsLoose(Duration, _TemporalAmount);
377
358
  function Duration(seconds, nanos) {
378
359
  var _this;
379
360
  _this = _TemporalAmount.call(this) || this;
@@ -381,6 +362,7 @@
381
362
  _this._nanos = MathUtil.safeToInt(nanos);
382
363
  return _this;
383
364
  }
365
+ _inheritsLoose(Duration, _TemporalAmount);
384
366
  Duration.ofDays = function ofDays(days) {
385
367
  return Duration._create(MathUtil.safeMultiply(days, LocalTime.SECONDS_PER_DAY), 0);
386
368
  };
@@ -829,7 +811,6 @@
829
811
  }
830
812
 
831
813
  var ChronoUnit = function (_TemporalUnit) {
832
- _inheritsLoose(ChronoUnit, _TemporalUnit);
833
814
  function ChronoUnit(name, estimatedDuration) {
834
815
  var _this;
835
816
  _this = _TemporalUnit.call(this) || this;
@@ -837,6 +818,7 @@
837
818
  _this._duration = estimatedDuration;
838
819
  return _this;
839
820
  }
821
+ _inheritsLoose(ChronoUnit, _TemporalUnit);
840
822
  var _proto = ChronoUnit.prototype;
841
823
  _proto.duration = function duration() {
842
824
  return this._duration;
@@ -1038,6 +1020,15 @@
1038
1020
  }();
1039
1021
 
1040
1022
  var ChronoField = function (_TemporalField) {
1023
+ function ChronoField(name, baseUnit, rangeUnit, range) {
1024
+ var _this;
1025
+ _this = _TemporalField.call(this) || this;
1026
+ _this._name = name;
1027
+ _this._baseUnit = baseUnit;
1028
+ _this._rangeUnit = rangeUnit;
1029
+ _this._range = range;
1030
+ return _this;
1031
+ }
1041
1032
  _inheritsLoose(ChronoField, _TemporalField);
1042
1033
  ChronoField.byName = function byName(fieldName) {
1043
1034
  for (var prop in ChronoField) {
@@ -1048,15 +1039,6 @@
1048
1039
  }
1049
1040
  }
1050
1041
  };
1051
- function ChronoField(name, baseUnit, rangeUnit, range) {
1052
- var _this;
1053
- _this = _TemporalField.call(this) || this;
1054
- _this._name = name;
1055
- _this._baseUnit = baseUnit;
1056
- _this._rangeUnit = rangeUnit;
1057
- _this._range = range;
1058
- return _this;
1059
- }
1060
1042
  var _proto = ChronoField.prototype;
1061
1043
  _proto.name = function name() {
1062
1044
  return this._name;
@@ -1207,10 +1189,10 @@
1207
1189
  }();
1208
1190
 
1209
1191
  var TemporalQuery = function (_Enum) {
1210
- _inheritsLoose(TemporalQuery, _Enum);
1211
1192
  function TemporalQuery() {
1212
1193
  return _Enum.apply(this, arguments) || this;
1213
1194
  }
1195
+ _inheritsLoose(TemporalQuery, _Enum);
1214
1196
  var _proto = TemporalQuery.prototype;
1215
1197
  _proto.queryFrom = function queryFrom(temporal) {
1216
1198
  abstractMethodFail('queryFrom');
@@ -1219,10 +1201,10 @@
1219
1201
  }(Enum);
1220
1202
  function createTemporalQuery(name, queryFromFunction) {
1221
1203
  var ExtendedTemporalQuery = function (_TemporalQuery) {
1222
- _inheritsLoose(ExtendedTemporalQuery, _TemporalQuery);
1223
1204
  function ExtendedTemporalQuery() {
1224
1205
  return _TemporalQuery.apply(this, arguments) || this;
1225
1206
  }
1207
+ _inheritsLoose(ExtendedTemporalQuery, _TemporalQuery);
1226
1208
  return ExtendedTemporalQuery;
1227
1209
  }(TemporalQuery);
1228
1210
  ExtendedTemporalQuery.prototype.queryFrom = queryFromFunction;
@@ -1230,7 +1212,6 @@
1230
1212
  }
1231
1213
 
1232
1214
  var DayOfWeek = function (_TemporalAccessor) {
1233
- _inheritsLoose(DayOfWeek, _TemporalAccessor);
1234
1215
  function DayOfWeek(ordinal, name) {
1235
1216
  var _this;
1236
1217
  _this = _TemporalAccessor.call(this) || this;
@@ -1238,6 +1219,7 @@
1238
1219
  _this._name = name;
1239
1220
  return _this;
1240
1221
  }
1222
+ _inheritsLoose(DayOfWeek, _TemporalAccessor);
1241
1223
  var _proto = DayOfWeek.prototype;
1242
1224
  _proto.ordinal = function ordinal() {
1243
1225
  return this._ordinal;
@@ -1364,7 +1346,6 @@
1364
1346
  }
1365
1347
 
1366
1348
  var Month = function (_TemporalAccessor) {
1367
- _inheritsLoose(Month, _TemporalAccessor);
1368
1349
  function Month(value, name) {
1369
1350
  var _this;
1370
1351
  _this = _TemporalAccessor.call(this) || this;
@@ -1372,6 +1353,7 @@
1372
1353
  _this._name = name;
1373
1354
  return _this;
1374
1355
  }
1356
+ _inheritsLoose(Month, _TemporalAccessor);
1375
1357
  var _proto = Month.prototype;
1376
1358
  _proto.value = function value() {
1377
1359
  return this._value;
@@ -1609,7 +1591,6 @@
1609
1591
 
1610
1592
  var PATTERN = /([-+]?)P(?:([-+]?[0-9]+)Y)?(?:([-+]?[0-9]+)M)?(?:([-+]?[0-9]+)W)?(?:([-+]?[0-9]+)D)?/;
1611
1593
  var Period = function (_TemporalAmount) {
1612
- _inheritsLoose(Period, _TemporalAmount);
1613
1594
  function Period(years, months, days) {
1614
1595
  var _this;
1615
1596
  _this = _TemporalAmount.call(this) || this;
@@ -1621,7 +1602,7 @@
1621
1602
  _this._years = _years;
1622
1603
  _this._months = _months;
1623
1604
  _this._days = _days;
1624
- Period.ZERO = _assertThisInitialized(_this);
1605
+ Period.ZERO = _this;
1625
1606
  }
1626
1607
  return Period.ZERO || _assertThisInitialized(_this);
1627
1608
  }
@@ -1630,6 +1611,7 @@
1630
1611
  _this._days = _days;
1631
1612
  return _this;
1632
1613
  }
1614
+ _inheritsLoose(Period, _TemporalAmount);
1633
1615
  Period.ofYears = function ofYears(years) {
1634
1616
  return Period.create(years, 0, 0);
1635
1617
  };
@@ -1973,10 +1955,10 @@
1973
1955
  }();
1974
1956
 
1975
1957
  var ResolverStyle = function (_Enum) {
1976
- _inheritsLoose(ResolverStyle, _Enum);
1977
1958
  function ResolverStyle() {
1978
1959
  return _Enum.apply(this, arguments) || this;
1979
1960
  }
1961
+ _inheritsLoose(ResolverStyle, _Enum);
1980
1962
  return ResolverStyle;
1981
1963
  }(Enum);
1982
1964
  ResolverStyle.STRICT = new ResolverStyle('STRICT');
@@ -1984,10 +1966,10 @@
1984
1966
  ResolverStyle.LENIENT = new ResolverStyle('LENIENT');
1985
1967
 
1986
1968
  var Temporal = function (_TemporalAccessor) {
1987
- _inheritsLoose(Temporal, _TemporalAccessor);
1988
1969
  function Temporal() {
1989
1970
  return _TemporalAccessor.apply(this, arguments) || this;
1990
1971
  }
1972
+ _inheritsLoose(Temporal, _TemporalAccessor);
1991
1973
  var _proto = Temporal.prototype;
1992
1974
  _proto.isSupported = function isSupported(fieldOrUnit) {
1993
1975
  abstractMethodFail('isSupported');
@@ -2055,10 +2037,10 @@
2055
2037
  }
2056
2038
 
2057
2039
  var ChronoLocalDate = function (_Temporal) {
2058
- _inheritsLoose(ChronoLocalDate, _Temporal);
2059
2040
  function ChronoLocalDate() {
2060
2041
  return _Temporal.apply(this, arguments) || this;
2061
2042
  }
2043
+ _inheritsLoose(ChronoLocalDate, _Temporal);
2062
2044
  var _proto = ChronoLocalDate.prototype;
2063
2045
  _proto.isSupported = function isSupported(fieldOrUnit) {
2064
2046
  if (fieldOrUnit instanceof ChronoField) {
@@ -2240,13 +2222,13 @@
2240
2222
  return ZoneRules;
2241
2223
  }();
2242
2224
  var Fixed = function (_ZoneRules) {
2243
- _inheritsLoose(Fixed, _ZoneRules);
2244
2225
  function Fixed(offset) {
2245
2226
  var _this;
2246
2227
  _this = _ZoneRules.call(this) || this;
2247
2228
  _this._offset = offset;
2248
2229
  return _this;
2249
2230
  }
2231
+ _inheritsLoose(Fixed, _ZoneRules);
2250
2232
  var _proto2 = Fixed.prototype;
2251
2233
  _proto2.isFixedOffset = function isFixedOffset() {
2252
2234
  return true;
@@ -2308,16 +2290,16 @@
2308
2290
  var SECONDS_CACHE = {};
2309
2291
  var ID_CACHE = {};
2310
2292
  var ZoneOffset = function (_ZoneId) {
2311
- _inheritsLoose(ZoneOffset, _ZoneId);
2312
2293
  function ZoneOffset(totalSeconds) {
2313
2294
  var _this;
2314
2295
  _this = _ZoneId.call(this) || this;
2315
2296
  ZoneOffset._validateTotalSeconds(totalSeconds);
2316
2297
  _this._totalSeconds = MathUtil.safeToInt(totalSeconds);
2317
- _this._rules = ZoneRules.of(_assertThisInitialized(_this));
2298
+ _this._rules = ZoneRules.of(_this);
2318
2299
  _this._id = ZoneOffset._buildId(totalSeconds);
2319
2300
  return _this;
2320
2301
  }
2302
+ _inheritsLoose(ZoneOffset, _ZoneId);
2321
2303
  var _proto = ZoneOffset.prototype;
2322
2304
  _proto.totalSeconds = function totalSeconds() {
2323
2305
  return this._totalSeconds;
@@ -2513,12 +2495,6 @@
2513
2495
  }
2514
2496
 
2515
2497
  var DateTimeBuilder = function (_TemporalAccessor) {
2516
- _inheritsLoose(DateTimeBuilder, _TemporalAccessor);
2517
- DateTimeBuilder.create = function create(field, value) {
2518
- var dtb = new DateTimeBuilder();
2519
- dtb._addFieldValue(field, value);
2520
- return dtb;
2521
- };
2522
2498
  function DateTimeBuilder() {
2523
2499
  var _this;
2524
2500
  _this = _TemporalAccessor.call(this) || this;
@@ -2531,6 +2507,12 @@
2531
2507
  _this.excessDays = null;
2532
2508
  return _this;
2533
2509
  }
2510
+ _inheritsLoose(DateTimeBuilder, _TemporalAccessor);
2511
+ DateTimeBuilder.create = function create(field, value) {
2512
+ var dtb = new DateTimeBuilder();
2513
+ dtb._addFieldValue(field, value);
2514
+ return dtb;
2515
+ };
2534
2516
  var _proto = DateTimeBuilder.prototype;
2535
2517
  _proto.getFieldValue0 = function getFieldValue0(field) {
2536
2518
  return this.fieldValues.get(field);
@@ -2968,7 +2950,6 @@
2968
2950
  return DateTimeParseContext;
2969
2951
  }();
2970
2952
  var Parsed = function (_Temporal) {
2971
- _inheritsLoose(Parsed, _Temporal);
2972
2953
  function Parsed(dateTimeParseContext) {
2973
2954
  var _this;
2974
2955
  _this = _Temporal.call(this) || this;
@@ -2979,6 +2960,7 @@
2979
2960
  _this.dateTimeParseContext = dateTimeParseContext;
2980
2961
  return _this;
2981
2962
  }
2963
+ _inheritsLoose(Parsed, _Temporal);
2982
2964
  var _proto2 = Parsed.prototype;
2983
2965
  _proto2.copy = function copy() {
2984
2966
  var cloned = new Parsed();
@@ -3092,10 +3074,10 @@
3092
3074
  var IsoFields = {};
3093
3075
  var QUARTER_DAYS = [0, 90, 181, 273, 0, 91, 182, 274];
3094
3076
  var Field = function (_TemporalField) {
3095
- _inheritsLoose(Field, _TemporalField);
3096
3077
  function Field() {
3097
3078
  return _TemporalField.apply(this, arguments) || this;
3098
3079
  }
3080
+ _inheritsLoose(Field, _TemporalField);
3099
3081
  var _proto = Field.prototype;
3100
3082
  _proto.isDateBased = function isDateBased() {
3101
3083
  return true;
@@ -3167,10 +3149,10 @@
3167
3149
  return Field;
3168
3150
  }(TemporalField);
3169
3151
  var DAY_OF_QUARTER_FIELD = function (_Field) {
3170
- _inheritsLoose(DAY_OF_QUARTER_FIELD, _Field);
3171
3152
  function DAY_OF_QUARTER_FIELD() {
3172
3153
  return _Field.apply(this, arguments) || this;
3173
3154
  }
3155
+ _inheritsLoose(DAY_OF_QUARTER_FIELD, _Field);
3174
3156
  var _proto2 = DAY_OF_QUARTER_FIELD.prototype;
3175
3157
  _proto2.toString = function toString() {
3176
3158
  return 'DayOfQuarter';
@@ -3253,10 +3235,10 @@
3253
3235
  return DAY_OF_QUARTER_FIELD;
3254
3236
  }(Field);
3255
3237
  var QUARTER_OF_YEAR_FIELD = function (_Field2) {
3256
- _inheritsLoose(QUARTER_OF_YEAR_FIELD, _Field2);
3257
3238
  function QUARTER_OF_YEAR_FIELD() {
3258
3239
  return _Field2.apply(this, arguments) || this;
3259
3240
  }
3241
+ _inheritsLoose(QUARTER_OF_YEAR_FIELD, _Field2);
3260
3242
  var _proto3 = QUARTER_OF_YEAR_FIELD.prototype;
3261
3243
  _proto3.toString = function toString() {
3262
3244
  return 'QuarterOfYear';
@@ -3291,10 +3273,10 @@
3291
3273
  return QUARTER_OF_YEAR_FIELD;
3292
3274
  }(Field);
3293
3275
  var WEEK_OF_WEEK_BASED_YEAR_FIELD = function (_Field3) {
3294
- _inheritsLoose(WEEK_OF_WEEK_BASED_YEAR_FIELD, _Field3);
3295
3276
  function WEEK_OF_WEEK_BASED_YEAR_FIELD() {
3296
3277
  return _Field3.apply(this, arguments) || this;
3297
3278
  }
3279
+ _inheritsLoose(WEEK_OF_WEEK_BASED_YEAR_FIELD, _Field3);
3298
3280
  var _proto4 = WEEK_OF_WEEK_BASED_YEAR_FIELD.prototype;
3299
3281
  _proto4.toString = function toString() {
3300
3282
  return 'WeekOfWeekBasedYear';
@@ -3369,10 +3351,10 @@
3369
3351
  return WEEK_OF_WEEK_BASED_YEAR_FIELD;
3370
3352
  }(Field);
3371
3353
  var WEEK_BASED_YEAR_FIELD = function (_Field4) {
3372
- _inheritsLoose(WEEK_BASED_YEAR_FIELD, _Field4);
3373
3354
  function WEEK_BASED_YEAR_FIELD() {
3374
3355
  return _Field4.apply(this, arguments) || this;
3375
3356
  }
3357
+ _inheritsLoose(WEEK_BASED_YEAR_FIELD, _Field4);
3376
3358
  var _proto5 = WEEK_BASED_YEAR_FIELD.prototype;
3377
3359
  _proto5.toString = function toString() {
3378
3360
  return 'WeekBasedYear';
@@ -3417,7 +3399,6 @@
3417
3399
  return WEEK_BASED_YEAR_FIELD;
3418
3400
  }(Field);
3419
3401
  var Unit = function (_TemporalUnit) {
3420
- _inheritsLoose(Unit, _TemporalUnit);
3421
3402
  function Unit(name, estimatedDuration) {
3422
3403
  var _this;
3423
3404
  _this = _TemporalUnit.call(this) || this;
@@ -3425,6 +3406,7 @@
3425
3406
  _this._duration = estimatedDuration;
3426
3407
  return _this;
3427
3408
  }
3409
+ _inheritsLoose(Unit, _TemporalUnit);
3428
3410
  var _proto6 = Unit.prototype;
3429
3411
  _proto6.duration = function duration() {
3430
3412
  return this._duration;
@@ -3588,10 +3570,10 @@
3588
3570
  DecimalStyle.STANDARD = new DecimalStyle('0', '+', '-', '.');
3589
3571
 
3590
3572
  var SignStyle = function (_Enum) {
3591
- _inheritsLoose(SignStyle, _Enum);
3592
3573
  function SignStyle() {
3593
3574
  return _Enum.apply(this, arguments) || this;
3594
3575
  }
3576
+ _inheritsLoose(SignStyle, _Enum);
3595
3577
  var _proto = SignStyle.prototype;
3596
3578
  _proto.parse = function parse(positive, strict, fixedWidth) {
3597
3579
  switch (this) {
@@ -3613,10 +3595,10 @@
3613
3595
  SignStyle.NOT_NEGATIVE = new SignStyle('NOT_NEGATIVE');
3614
3596
 
3615
3597
  var TextStyle = function (_Enum) {
3616
- _inheritsLoose(TextStyle, _Enum);
3617
3598
  function TextStyle() {
3618
3599
  return _Enum.apply(this, arguments) || this;
3619
3600
  }
3601
+ _inheritsLoose(TextStyle, _Enum);
3620
3602
  var _proto = TextStyle.prototype;
3621
3603
  _proto.isStandalone = function isStandalone() {
3622
3604
  switch (this) {
@@ -4077,7 +4059,6 @@
4077
4059
  return NumberPrinterParser;
4078
4060
  }();
4079
4061
  var ReducedPrinterParser = function (_NumberPrinterParser) {
4080
- _inheritsLoose(ReducedPrinterParser, _NumberPrinterParser);
4081
4062
  function ReducedPrinterParser(field, width, maxWidth, baseValue, baseDate) {
4082
4063
  var _this;
4083
4064
  _this = _NumberPrinterParser.call(this, field, width, maxWidth, SignStyle.NOT_NEGATIVE) || this;
@@ -4102,6 +4083,7 @@
4102
4083
  _this._baseDate = baseDate;
4103
4084
  return _this;
4104
4085
  }
4086
+ _inheritsLoose(ReducedPrinterParser, _NumberPrinterParser);
4105
4087
  var _proto2 = ReducedPrinterParser.prototype;
4106
4088
  _proto2._getValue = function _getValue(context, value) {
4107
4089
  var absValue = Math.abs(value);
@@ -4338,10 +4320,10 @@
4338
4320
  }();
4339
4321
 
4340
4322
  var SettingsParser = function (_Enum) {
4341
- _inheritsLoose(SettingsParser, _Enum);
4342
4323
  function SettingsParser() {
4343
4324
  return _Enum.apply(this, arguments) || this;
4344
4325
  }
4326
+ _inheritsLoose(SettingsParser, _Enum);
4345
4327
  var _proto = SettingsParser.prototype;
4346
4328
  _proto.print = function print() {
4347
4329
  return true;
@@ -4430,11 +4412,6 @@
4430
4412
  }();
4431
4413
 
4432
4414
  var ZoneRegion = function (_ZoneId) {
4433
- _inheritsLoose(ZoneRegion, _ZoneId);
4434
- ZoneRegion.ofId = function ofId(zoneId) {
4435
- var rules = ZoneRulesProvider.getRules(zoneId);
4436
- return new ZoneRegion(zoneId, rules);
4437
- };
4438
4415
  function ZoneRegion(id, rules) {
4439
4416
  var _this;
4440
4417
  _this = _ZoneId.call(this) || this;
@@ -4442,6 +4419,11 @@
4442
4419
  _this._rules = rules;
4443
4420
  return _this;
4444
4421
  }
4422
+ _inheritsLoose(ZoneRegion, _ZoneId);
4423
+ ZoneRegion.ofId = function ofId(zoneId) {
4424
+ var rules = ZoneRulesProvider.getRules(zoneId);
4425
+ return new ZoneRegion(zoneId, rules);
4426
+ };
4445
4427
  var _proto = ZoneRegion.prototype;
4446
4428
  _proto.id = function id() {
4447
4429
  return this._id;
@@ -4555,6 +4537,10 @@
4555
4537
  return ZoneIdPrinterParser;
4556
4538
  }();
4557
4539
  var ZoneIdTree = function () {
4540
+ function ZoneIdTree(size, treeMap) {
4541
+ this.size = size;
4542
+ this.treeMap = treeMap;
4543
+ }
4558
4544
  ZoneIdTree.createTreeMap = function createTreeMap(availableZoneIds) {
4559
4545
  var sortedZoneIds = availableZoneIds.sort(function (a, b) {
4560
4546
  return a.length - b.length;
@@ -4565,10 +4551,6 @@
4565
4551
  }
4566
4552
  return new ZoneIdTree(sortedZoneIds.length, treeMap);
4567
4553
  };
4568
- function ZoneIdTree(size, treeMap) {
4569
- this.size = size;
4570
- this.treeMap = treeMap;
4571
- }
4572
4554
  return ZoneIdTree;
4573
4555
  }();
4574
4556
  var ZoneIdTreeMap = function () {
@@ -5369,15 +5351,6 @@
5369
5351
  */
5370
5352
 
5371
5353
  var DateTimeFormatter = function () {
5372
- DateTimeFormatter.parsedExcessDays = function parsedExcessDays() {
5373
- return DateTimeFormatter.PARSED_EXCESS_DAYS;
5374
- };
5375
- DateTimeFormatter.parsedLeapSecond = function parsedLeapSecond() {
5376
- return DateTimeFormatter.PARSED_LEAP_SECOND;
5377
- };
5378
- DateTimeFormatter.ofPattern = function ofPattern(pattern) {
5379
- return new DateTimeFormatterBuilder().appendPattern(pattern).toFormatter();
5380
- };
5381
5354
  function DateTimeFormatter(printerParser, locale, decimalStyle, resolverStyle, resolverFields, chrono, zone) {
5382
5355
  if (chrono === void 0) {
5383
5356
  chrono = IsoChronology.INSTANCE;
@@ -5393,6 +5366,15 @@
5393
5366
  this._chrono = chrono;
5394
5367
  this._zone = zone;
5395
5368
  }
5369
+ DateTimeFormatter.parsedExcessDays = function parsedExcessDays() {
5370
+ return DateTimeFormatter.PARSED_EXCESS_DAYS;
5371
+ };
5372
+ DateTimeFormatter.parsedLeapSecond = function parsedLeapSecond() {
5373
+ return DateTimeFormatter.PARSED_LEAP_SECOND;
5374
+ };
5375
+ DateTimeFormatter.ofPattern = function ofPattern(pattern) {
5376
+ return new DateTimeFormatterBuilder().appendPattern(pattern).toFormatter();
5377
+ };
5396
5378
  var _proto = DateTimeFormatter.prototype;
5397
5379
  _proto.locale = function locale() {
5398
5380
  return this._locale;
@@ -5547,6 +5529,13 @@
5547
5529
  }
5548
5530
 
5549
5531
  var MonthDay = function (_TemporalAccessor) {
5532
+ function MonthDay(month, dayOfMonth) {
5533
+ var _this;
5534
+ _this = _TemporalAccessor.call(this) || this;
5535
+ _this._month = MathUtil.safeToInt(month);
5536
+ _this._day = MathUtil.safeToInt(dayOfMonth);
5537
+ return _this;
5538
+ }
5550
5539
  _inheritsLoose(MonthDay, _TemporalAccessor);
5551
5540
  MonthDay.now = function now(zoneIdOrClock) {
5552
5541
  if (arguments.length === 0) {
@@ -5617,13 +5606,6 @@
5617
5606
  requireInstance(formatter, DateTimeFormatter, 'formatter');
5618
5607
  return formatter.parse(text, MonthDay.FROM);
5619
5608
  };
5620
- function MonthDay(month, dayOfMonth) {
5621
- var _this;
5622
- _this = _TemporalAccessor.call(this) || this;
5623
- _this._month = MathUtil.safeToInt(month);
5624
- _this._day = MathUtil.safeToInt(dayOfMonth);
5625
- return _this;
5626
- }
5627
5609
  var _proto = MonthDay.prototype;
5628
5610
  _proto.monthValue = function monthValue() {
5629
5611
  return this._month;
@@ -5751,6 +5733,13 @@
5751
5733
  }
5752
5734
 
5753
5735
  var YearMonth = function (_Temporal) {
5736
+ function YearMonth(year, month) {
5737
+ var _this;
5738
+ _this = _Temporal.call(this) || this;
5739
+ _this._year = MathUtil.safeToInt(year);
5740
+ _this._month = MathUtil.safeToInt(month);
5741
+ return _this;
5742
+ }
5754
5743
  _inheritsLoose(YearMonth, _Temporal);
5755
5744
  YearMonth.now = function now(zoneIdOrClock) {
5756
5745
  if (arguments.length === 0) {
@@ -5815,13 +5804,6 @@
5815
5804
  requireNonNull(formatter, 'formatter');
5816
5805
  return formatter.parse(text, YearMonth.FROM);
5817
5806
  };
5818
- function YearMonth(year, month) {
5819
- var _this;
5820
- _this = _Temporal.call(this) || this;
5821
- _this._year = MathUtil.safeToInt(year);
5822
- _this._month = MathUtil.safeToInt(month);
5823
- return _this;
5824
- }
5825
5807
  var _proto = YearMonth.prototype;
5826
5808
  _proto.isSupported = function isSupported(fieldOrUnit) {
5827
5809
  if (arguments.length === 1 && fieldOrUnit instanceof TemporalField) {
@@ -6075,13 +6057,13 @@
6075
6057
  }
6076
6058
 
6077
6059
  var Year = function (_Temporal) {
6078
- _inheritsLoose(Year, _Temporal);
6079
6060
  function Year(value) {
6080
6061
  var _this;
6081
6062
  _this = _Temporal.call(this) || this;
6082
6063
  _this._year = MathUtil.safeToInt(value);
6083
6064
  return _this;
6084
6065
  }
6066
+ _inheritsLoose(Year, _Temporal);
6085
6067
  var _proto = Year.prototype;
6086
6068
  _proto.value = function value() {
6087
6069
  return this._year;
@@ -6422,13 +6404,13 @@
6422
6404
  return TemporalAdjusters;
6423
6405
  }();
6424
6406
  var Impl = function (_TemporalAdjuster) {
6425
- _inheritsLoose(Impl, _TemporalAdjuster);
6426
6407
  function Impl(ordinal) {
6427
6408
  var _this;
6428
6409
  _this = _TemporalAdjuster.call(this) || this;
6429
6410
  _this._ordinal = ordinal;
6430
6411
  return _this;
6431
6412
  }
6413
+ _inheritsLoose(Impl, _TemporalAdjuster);
6432
6414
  var _proto = Impl.prototype;
6433
6415
  _proto.adjustInto = function adjustInto(temporal) {
6434
6416
  switch (this._ordinal) {
@@ -6456,7 +6438,6 @@
6456
6438
  Impl.LAST_DAY_OF_YEAR = new Impl(4);
6457
6439
  Impl.FIRST_DAY_OF_NEXT_YEAR = new Impl(5);
6458
6440
  var DayOfWeekInMonth = function (_TemporalAdjuster2) {
6459
- _inheritsLoose(DayOfWeekInMonth, _TemporalAdjuster2);
6460
6441
  function DayOfWeekInMonth(ordinal, dow) {
6461
6442
  var _this2;
6462
6443
  _this2 = _TemporalAdjuster2.call(this) || this;
@@ -6464,6 +6445,7 @@
6464
6445
  _this2._dowValue = dow.value();
6465
6446
  return _this2;
6466
6447
  }
6448
+ _inheritsLoose(DayOfWeekInMonth, _TemporalAdjuster2);
6467
6449
  var _proto2 = DayOfWeekInMonth.prototype;
6468
6450
  _proto2.adjustInto = function adjustInto(temporal) {
6469
6451
  if (this._ordinal >= 0) {
@@ -6484,7 +6466,6 @@
6484
6466
  return DayOfWeekInMonth;
6485
6467
  }(TemporalAdjuster);
6486
6468
  var RelativeDayOfWeek = function (_TemporalAdjuster3) {
6487
- _inheritsLoose(RelativeDayOfWeek, _TemporalAdjuster3);
6488
6469
  function RelativeDayOfWeek(relative, dayOfWeek) {
6489
6470
  var _this3;
6490
6471
  _this3 = _TemporalAdjuster3.call(this) || this;
@@ -6493,6 +6474,7 @@
6493
6474
  _this3._dowValue = dayOfWeek.value();
6494
6475
  return _this3;
6495
6476
  }
6477
+ _inheritsLoose(RelativeDayOfWeek, _TemporalAdjuster3);
6496
6478
  var _proto3 = RelativeDayOfWeek.prototype;
6497
6479
  _proto3.adjustInto = function adjustInto(temporal) {
6498
6480
  var calDow = temporal.get(ChronoField.DAY_OF_WEEK);
@@ -6511,10 +6493,10 @@
6511
6493
  }(TemporalAdjuster);
6512
6494
 
6513
6495
  var IsoChronology = function (_Enum) {
6514
- _inheritsLoose(IsoChronology, _Enum);
6515
6496
  function IsoChronology() {
6516
6497
  return _Enum.apply(this, arguments) || this;
6517
6498
  }
6499
+ _inheritsLoose(IsoChronology, _Enum);
6518
6500
  IsoChronology.isLeapYear = function isLeapYear(prolepticYear) {
6519
6501
  return (prolepticYear & 3) === 0 && (prolepticYear % 100 !== 0 || prolepticYear % 400 === 0);
6520
6502
  };
@@ -6644,6 +6626,17 @@
6644
6626
  }
6645
6627
 
6646
6628
  var OffsetTime = function (_Temporal) {
6629
+ function OffsetTime(time, offset) {
6630
+ var _this;
6631
+ _this = _Temporal.call(this) || this;
6632
+ requireNonNull(time, 'time');
6633
+ requireInstance(time, LocalTime, 'time');
6634
+ requireNonNull(offset, 'offset');
6635
+ requireInstance(offset, ZoneOffset, 'offset');
6636
+ _this._time = time;
6637
+ _this._offset = offset;
6638
+ return _this;
6639
+ }
6647
6640
  _inheritsLoose(OffsetTime, _Temporal);
6648
6641
  OffsetTime.from = function from(temporal) {
6649
6642
  requireNonNull(temporal, 'temporal');
@@ -6710,17 +6703,6 @@
6710
6703
  requireNonNull(formatter, 'formatter');
6711
6704
  return formatter.parse(text, OffsetTime.FROM);
6712
6705
  };
6713
- function OffsetTime(time, offset) {
6714
- var _this;
6715
- _this = _Temporal.call(this) || this;
6716
- requireNonNull(time, 'time');
6717
- requireInstance(time, LocalTime, 'time');
6718
- requireNonNull(offset, 'offset');
6719
- requireInstance(offset, ZoneOffset, 'offset');
6720
- _this._time = time;
6721
- _this._offset = offset;
6722
- return _this;
6723
- }
6724
6706
  var _proto = OffsetTime.prototype;
6725
6707
  _proto.adjustInto = function adjustInto(temporal) {
6726
6708
  return temporal.with(ChronoField.NANO_OF_DAY, this._time.toNanoOfDay()).with(ChronoField.OFFSET_SECONDS, this.offset().totalSeconds());
@@ -6971,10 +6953,10 @@
6971
6953
  }
6972
6954
 
6973
6955
  var ChronoZonedDateTime = function (_Temporal) {
6974
- _inheritsLoose(ChronoZonedDateTime, _Temporal);
6975
6956
  function ChronoZonedDateTime() {
6976
6957
  return _Temporal.apply(this, arguments) || this;
6977
6958
  }
6959
+ _inheritsLoose(ChronoZonedDateTime, _Temporal);
6978
6960
  var _proto = ChronoZonedDateTime.prototype;
6979
6961
  _proto.query = function query(_query) {
6980
6962
  if (_query === TemporalQueries.zoneId() || _query === TemporalQueries.zone()) {
@@ -7057,6 +7039,17 @@
7057
7039
  }
7058
7040
 
7059
7041
  var ZonedDateTime = function (_ChronoZonedDateTime) {
7042
+ function ZonedDateTime(dateTime, offset, zone) {
7043
+ var _this;
7044
+ requireNonNull(dateTime, 'dateTime');
7045
+ requireNonNull(offset, 'offset');
7046
+ requireNonNull(zone, 'zone');
7047
+ _this = _ChronoZonedDateTime.call(this) || this;
7048
+ _this._dateTime = dateTime;
7049
+ _this._offset = offset;
7050
+ _this._zone = zone;
7051
+ return _this;
7052
+ }
7060
7053
  _inheritsLoose(ZonedDateTime, _ChronoZonedDateTime);
7061
7054
  ZonedDateTime.now = function now(clockOrZone) {
7062
7055
  var clock;
@@ -7192,17 +7185,6 @@
7192
7185
  requireNonNull(formatter, 'formatter');
7193
7186
  return formatter.parse(text, ZonedDateTime.FROM);
7194
7187
  };
7195
- function ZonedDateTime(dateTime, offset, zone) {
7196
- var _this;
7197
- requireNonNull(dateTime, 'dateTime');
7198
- requireNonNull(offset, 'offset');
7199
- requireNonNull(zone, 'zone');
7200
- _this = _ChronoZonedDateTime.call(this) || this;
7201
- _this._dateTime = dateTime;
7202
- _this._offset = offset;
7203
- _this._zone = zone;
7204
- return _this;
7205
- }
7206
7188
  var _proto = ZonedDateTime.prototype;
7207
7189
  _proto._resolveLocal = function _resolveLocal(newDateTime) {
7208
7190
  requireNonNull(newDateTime, 'newDateTime');
@@ -7503,6 +7485,17 @@
7503
7485
  }
7504
7486
 
7505
7487
  var OffsetDateTime = function (_Temporal) {
7488
+ function OffsetDateTime(dateTime, offset) {
7489
+ var _this;
7490
+ _this = _Temporal.call(this) || this;
7491
+ requireNonNull(dateTime, 'dateTime');
7492
+ requireInstance(dateTime, LocalDateTime, 'dateTime');
7493
+ requireNonNull(offset, 'offset');
7494
+ requireInstance(offset, ZoneOffset, 'offset');
7495
+ _this._dateTime = dateTime;
7496
+ _this._offset = offset;
7497
+ return _this;
7498
+ }
7506
7499
  _inheritsLoose(OffsetDateTime, _Temporal);
7507
7500
  OffsetDateTime.from = function from(temporal) {
7508
7501
  requireNonNull(temporal, 'temporal');
@@ -7530,8 +7523,8 @@
7530
7523
  if (clockOrZone instanceof ZoneId) {
7531
7524
  return OffsetDateTime.now(Clock.system(clockOrZone));
7532
7525
  } else if (clockOrZone instanceof Clock) {
7533
- var now = clockOrZone.instant();
7534
- return OffsetDateTime.ofInstant(now, clockOrZone.zone().rules().offset(now));
7526
+ var _now = clockOrZone.instant();
7527
+ return OffsetDateTime.ofInstant(_now, clockOrZone.zone().rules().offset(_now));
7535
7528
  } else {
7536
7529
  throw new IllegalArgumentException('clockOrZone must be an instance of ZoneId or Clock');
7537
7530
  }
@@ -7584,17 +7577,6 @@
7584
7577
  requireNonNull(formatter, 'formatter');
7585
7578
  return formatter.parse(text, OffsetDateTime.FROM);
7586
7579
  };
7587
- function OffsetDateTime(dateTime, offset) {
7588
- var _this;
7589
- _this = _Temporal.call(this) || this;
7590
- requireNonNull(dateTime, 'dateTime');
7591
- requireInstance(dateTime, LocalDateTime, 'dateTime');
7592
- requireNonNull(offset, 'offset');
7593
- requireInstance(offset, ZoneOffset, 'offset');
7594
- _this._dateTime = dateTime;
7595
- _this._offset = offset;
7596
- return _this;
7597
- }
7598
7580
  var _proto = OffsetDateTime.prototype;
7599
7581
  _proto.adjustInto = function adjustInto(temporal) {
7600
7582
  return temporal.with(ChronoField.EPOCH_DAY, this.toLocalDate().toEpochDay()).with(ChronoField.NANO_OF_DAY, this.toLocalTime().toNanoOfDay()).with(ChronoField.OFFSET_SECONDS, this.offset().totalSeconds());
@@ -7932,6 +7914,21 @@
7932
7914
  var DAYS_PER_CYCLE = 146097;
7933
7915
  var DAYS_0000_TO_1970 = DAYS_PER_CYCLE * 5 - (30 * 365 + 7);
7934
7916
  var LocalDate = function (_ChronoLocalDate) {
7917
+ function LocalDate(year, month, dayOfMonth) {
7918
+ var _this;
7919
+ _this = _ChronoLocalDate.call(this) || this;
7920
+ requireNonNull(year, 'year');
7921
+ requireNonNull(month, 'month');
7922
+ requireNonNull(dayOfMonth, 'dayOfMonth');
7923
+ if (month instanceof Month) {
7924
+ month = month.value();
7925
+ }
7926
+ _this._year = MathUtil.safeToInt(year);
7927
+ _this._month = MathUtil.safeToInt(month);
7928
+ _this._day = MathUtil.safeToInt(dayOfMonth);
7929
+ LocalDate._validate(_this._year, _this._month, _this._day);
7930
+ return _this;
7931
+ }
7935
7932
  _inheritsLoose(LocalDate, _ChronoLocalDate);
7936
7933
  LocalDate.now = function now(clockOrZone) {
7937
7934
  var clock;
@@ -8028,21 +8025,6 @@
8028
8025
  }
8029
8026
  return LocalDate.of(year, month, day);
8030
8027
  };
8031
- function LocalDate(year, month, dayOfMonth) {
8032
- var _this;
8033
- _this = _ChronoLocalDate.call(this) || this;
8034
- requireNonNull(year, 'year');
8035
- requireNonNull(month, 'month');
8036
- requireNonNull(dayOfMonth, 'dayOfMonth');
8037
- if (month instanceof Month) {
8038
- month = month.value();
8039
- }
8040
- _this._year = MathUtil.safeToInt(year);
8041
- _this._month = MathUtil.safeToInt(month);
8042
- _this._day = MathUtil.safeToInt(dayOfMonth);
8043
- LocalDate._validate(_this._year, _this._month, _this._day);
8044
- return _this;
8045
- }
8046
8028
  LocalDate._validate = function _validate(year, month, dayOfMonth) {
8047
8029
  var dom;
8048
8030
  ChronoField.YEAR.checkValidValue(year);
@@ -8541,10 +8523,10 @@
8541
8523
  }
8542
8524
 
8543
8525
  var ChronoLocalDateTime = function (_Temporal) {
8544
- _inheritsLoose(ChronoLocalDateTime, _Temporal);
8545
8526
  function ChronoLocalDateTime() {
8546
8527
  return _Temporal.apply(this, arguments) || this;
8547
8528
  }
8529
+ _inheritsLoose(ChronoLocalDateTime, _Temporal);
8548
8530
  var _proto = ChronoLocalDateTime.prototype;
8549
8531
  _proto.chronology = function chronology() {
8550
8532
  return this.toLocalDate().chronology();
@@ -8581,6 +8563,15 @@
8581
8563
  }(Temporal);
8582
8564
 
8583
8565
  var LocalDateTime = function (_ChronoLocalDateTime) {
8566
+ function LocalDateTime(date, time) {
8567
+ var _this;
8568
+ _this = _ChronoLocalDateTime.call(this) || this;
8569
+ requireInstance(date, LocalDate, 'date');
8570
+ requireInstance(time, LocalTime, 'time');
8571
+ _this._date = date;
8572
+ _this._time = time;
8573
+ return _this;
8574
+ }
8584
8575
  _inheritsLoose(LocalDateTime, _ChronoLocalDateTime);
8585
8576
  LocalDateTime.now = function now(clockOrZone) {
8586
8577
  if (clockOrZone == null) {
@@ -8684,15 +8675,6 @@
8684
8675
  requireNonNull(formatter, 'formatter');
8685
8676
  return formatter.parse(text, LocalDateTime.FROM);
8686
8677
  };
8687
- function LocalDateTime(date, time) {
8688
- var _this;
8689
- _this = _ChronoLocalDateTime.call(this) || this;
8690
- requireInstance(date, LocalDate, 'date');
8691
- requireInstance(time, LocalTime, 'time');
8692
- _this._date = date;
8693
- _this._time = time;
8694
- return _this;
8695
- }
8696
8678
  var _proto = LocalDateTime.prototype;
8697
8679
  _proto._withDateTime = function _withDateTime(newDate, newTime) {
8698
8680
  if (this._date.equals(newDate) && this._time.equals(newTime)) {
@@ -9031,6 +9013,42 @@
9031
9013
  }
9032
9014
 
9033
9015
  var LocalTime = function (_Temporal) {
9016
+ function LocalTime(hour, minute, second, nanoOfSecond) {
9017
+ var _this;
9018
+ if (hour === void 0) {
9019
+ hour = 0;
9020
+ }
9021
+ if (minute === void 0) {
9022
+ minute = 0;
9023
+ }
9024
+ if (second === void 0) {
9025
+ second = 0;
9026
+ }
9027
+ if (nanoOfSecond === void 0) {
9028
+ nanoOfSecond = 0;
9029
+ }
9030
+ _this = _Temporal.call(this) || this;
9031
+ var _hour = MathUtil.safeToInt(hour);
9032
+ var _minute = MathUtil.safeToInt(minute);
9033
+ var _second = MathUtil.safeToInt(second);
9034
+ var _nanoOfSecond = MathUtil.safeToInt(nanoOfSecond);
9035
+ LocalTime._validate(_hour, _minute, _second, _nanoOfSecond);
9036
+ if (_minute === 0 && _second === 0 && _nanoOfSecond === 0) {
9037
+ if (!LocalTime.HOURS[_hour]) {
9038
+ _this._hour = _hour;
9039
+ _this._minute = _minute;
9040
+ _this._second = _second;
9041
+ _this._nano = _nanoOfSecond;
9042
+ LocalTime.HOURS[_hour] = _this;
9043
+ }
9044
+ return LocalTime.HOURS[_hour] || _assertThisInitialized(_this);
9045
+ }
9046
+ _this._hour = _hour;
9047
+ _this._minute = _minute;
9048
+ _this._second = _second;
9049
+ _this._nano = _nanoOfSecond;
9050
+ return _this;
9051
+ }
9034
9052
  _inheritsLoose(LocalTime, _Temporal);
9035
9053
  LocalTime.now = function now(clockOrZone) {
9036
9054
  if (clockOrZone == null) {
@@ -9106,42 +9124,6 @@
9106
9124
  requireNonNull(formatter, 'formatter');
9107
9125
  return formatter.parse(text, LocalTime.FROM);
9108
9126
  };
9109
- function LocalTime(hour, minute, second, nanoOfSecond) {
9110
- var _this;
9111
- if (hour === void 0) {
9112
- hour = 0;
9113
- }
9114
- if (minute === void 0) {
9115
- minute = 0;
9116
- }
9117
- if (second === void 0) {
9118
- second = 0;
9119
- }
9120
- if (nanoOfSecond === void 0) {
9121
- nanoOfSecond = 0;
9122
- }
9123
- _this = _Temporal.call(this) || this;
9124
- var _hour = MathUtil.safeToInt(hour);
9125
- var _minute = MathUtil.safeToInt(minute);
9126
- var _second = MathUtil.safeToInt(second);
9127
- var _nanoOfSecond = MathUtil.safeToInt(nanoOfSecond);
9128
- LocalTime._validate(_hour, _minute, _second, _nanoOfSecond);
9129
- if (_minute === 0 && _second === 0 && _nanoOfSecond === 0) {
9130
- if (!LocalTime.HOURS[_hour]) {
9131
- _this._hour = _hour;
9132
- _this._minute = _minute;
9133
- _this._second = _second;
9134
- _this._nano = _nanoOfSecond;
9135
- LocalTime.HOURS[_hour] = _assertThisInitialized(_this);
9136
- }
9137
- return LocalTime.HOURS[_hour] || _assertThisInitialized(_this);
9138
- }
9139
- _this._hour = _hour;
9140
- _this._minute = _minute;
9141
- _this._second = _second;
9142
- _this._nano = _nanoOfSecond;
9143
- return _this;
9144
- }
9145
9127
  LocalTime._validate = function _validate(hour, minute, second, nanoOfSecond) {
9146
9128
  ChronoField.HOUR_OF_DAY.checkValidValue(hour);
9147
9129
  ChronoField.MINUTE_OF_HOUR.checkValidValue(minute);
@@ -9566,6 +9548,14 @@
9566
9548
 
9567
9549
  var NANOS_PER_MILLI = 1000000;
9568
9550
  var Instant = function (_Temporal) {
9551
+ function Instant(seconds, nanoOfSecond) {
9552
+ var _this;
9553
+ _this = _Temporal.call(this) || this;
9554
+ Instant._validate(seconds, nanoOfSecond);
9555
+ _this._seconds = MathUtil.safeToInt(seconds);
9556
+ _this._nanos = MathUtil.safeToInt(nanoOfSecond);
9557
+ return _this;
9558
+ }
9569
9559
  _inheritsLoose(Instant, _Temporal);
9570
9560
  Instant.now = function now(clock) {
9571
9561
  if (clock === void 0) {
@@ -9617,14 +9607,6 @@
9617
9607
  throw new DateTimeException('Instant exceeds minimum or maximum instant');
9618
9608
  }
9619
9609
  };
9620
- function Instant(seconds, nanoOfSecond) {
9621
- var _this;
9622
- _this = _Temporal.call(this) || this;
9623
- Instant._validate(seconds, nanoOfSecond);
9624
- _this._seconds = MathUtil.safeToInt(seconds);
9625
- _this._nanos = MathUtil.safeToInt(nanoOfSecond);
9626
- return _this;
9627
- }
9628
9610
  var _proto = Instant.prototype;
9629
9611
  _proto.isSupported = function isSupported(fieldOrUnit) {
9630
9612
  if (fieldOrUnit instanceof ChronoField) {
@@ -9917,7 +9899,6 @@
9917
9899
  return Clock;
9918
9900
  }();
9919
9901
  var SystemClock = function (_Clock) {
9920
- _inheritsLoose(SystemClock, _Clock);
9921
9902
  function SystemClock(zone) {
9922
9903
  var _this;
9923
9904
  requireNonNull(zone, 'zone');
@@ -9925,6 +9906,7 @@
9925
9906
  _this._zone = zone;
9926
9907
  return _this;
9927
9908
  }
9909
+ _inheritsLoose(SystemClock, _Clock);
9928
9910
  var _proto2 = SystemClock.prototype;
9929
9911
  _proto2.zone = function zone() {
9930
9912
  return this._zone;
@@ -9953,7 +9935,6 @@
9953
9935
  return SystemClock;
9954
9936
  }(Clock);
9955
9937
  var FixedClock = function (_Clock2) {
9956
- _inheritsLoose(FixedClock, _Clock2);
9957
9938
  function FixedClock(fixedInstant, zoneId) {
9958
9939
  var _this2;
9959
9940
  _this2 = _Clock2.call(this) || this;
@@ -9961,6 +9942,7 @@
9961
9942
  _this2._zoneId = zoneId;
9962
9943
  return _this2;
9963
9944
  }
9945
+ _inheritsLoose(FixedClock, _Clock2);
9964
9946
  var _proto3 = FixedClock.prototype;
9965
9947
  _proto3.instant = function instant() {
9966
9948
  return this._instant;
@@ -9989,7 +9971,6 @@
9989
9971
  return FixedClock;
9990
9972
  }(Clock);
9991
9973
  var OffsetClock = function (_Clock3) {
9992
- _inheritsLoose(OffsetClock, _Clock3);
9993
9974
  function OffsetClock(baseClock, offset) {
9994
9975
  var _this3;
9995
9976
  _this3 = _Clock3.call(this) || this;
@@ -9997,6 +9978,7 @@
9997
9978
  _this3._offset = offset;
9998
9979
  return _this3;
9999
9980
  }
9981
+ _inheritsLoose(OffsetClock, _Clock3);
10000
9982
  var _proto4 = OffsetClock.prototype;
10001
9983
  _proto4.zone = function zone() {
10002
9984
  return this._baseClock.zone();
@@ -10032,9 +10014,6 @@
10032
10014
  */
10033
10015
 
10034
10016
  var ZoneOffsetTransition = function () {
10035
- ZoneOffsetTransition.of = function of(transition, offsetBefore, offsetAfter) {
10036
- return new ZoneOffsetTransition(transition, offsetBefore, offsetAfter);
10037
- };
10038
10017
  function ZoneOffsetTransition(transition, offsetBefore, offsetAfter) {
10039
10018
  requireNonNull(transition, 'transition');
10040
10019
  requireNonNull(offsetBefore, 'offsetBefore');
@@ -10053,6 +10032,9 @@
10053
10032
  this._offsetBefore = offsetBefore;
10054
10033
  this._offsetAfter = offsetAfter;
10055
10034
  }
10035
+ ZoneOffsetTransition.of = function of(transition, offsetBefore, offsetAfter) {
10036
+ return new ZoneOffsetTransition(transition, offsetBefore, offsetAfter);
10037
+ };
10056
10038
  var _proto = ZoneOffsetTransition.prototype;
10057
10039
  _proto.instant = function instant() {
10058
10040
  return this._transition.toInstant(this._offsetBefore);
@@ -10157,10 +10139,10 @@
10157
10139
  }
10158
10140
 
10159
10141
  var SystemDefaultZoneRules = function (_ZoneRules) {
10160
- _inheritsLoose(SystemDefaultZoneRules, _ZoneRules);
10161
10142
  function SystemDefaultZoneRules() {
10162
10143
  return _ZoneRules.apply(this, arguments) || this;
10163
10144
  }
10145
+ _inheritsLoose(SystemDefaultZoneRules, _ZoneRules);
10164
10146
  var _proto = SystemDefaultZoneRules.prototype;
10165
10147
  _proto.isFixedOffset = function isFixedOffset() {
10166
10148
  return false;
@@ -10227,13 +10209,13 @@
10227
10209
  }(ZoneRules);
10228
10210
 
10229
10211
  var SystemDefaultZoneId = function (_ZoneId) {
10230
- _inheritsLoose(SystemDefaultZoneId, _ZoneId);
10231
10212
  function SystemDefaultZoneId() {
10232
10213
  var _this;
10233
10214
  _this = _ZoneId.call(this) || this;
10234
10215
  _this._rules = new SystemDefaultZoneRules();
10235
10216
  return _this;
10236
10217
  }
10218
+ _inheritsLoose(SystemDefaultZoneId, _ZoneId);
10237
10219
  var _proto = SystemDefaultZoneId.prototype;
10238
10220
  _proto.rules = function rules() {
10239
10221
  return this._rules;
@@ -10424,12 +10406,7 @@
10424
10406
  }
10425
10407
  requireNonNull(date, 'date');
10426
10408
  requireNonNull(zone, 'zone');
10427
- if (date instanceof Date) {
10428
- return Instant.ofEpochMilli(date.getTime()).atZone(zone);
10429
- } else if (typeof date.toDate === 'function' && date.toDate() instanceof Date) {
10430
- return Instant.ofEpochMilli(date.toDate().getTime()).atZone(zone);
10431
- }
10432
- throw new IllegalArgumentException('date must be a javascript Date or a moment instance');
10409
+ return Instant.ofEpochMilli(date.valueOf()).atZone(zone);
10433
10410
  }
10434
10411
 
10435
10412
  function bindUse(jsJoda) {