@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.
@@ -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)
@@ -72,23 +72,17 @@ function messageForDateTimeParseException(message, text, index, cause) {
72
72
  };
73
73
  }
74
74
 
75
- function _inheritsLoose(subClass, superClass) {
76
- subClass.prototype = Object.create(superClass.prototype);
77
- subClass.prototype.constructor = subClass;
78
- _setPrototypeOf(subClass, superClass);
75
+ function _assertThisInitialized(e) {
76
+ if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
77
+ return e;
79
78
  }
80
- function _setPrototypeOf(o, p) {
81
- _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
82
- o.__proto__ = p;
83
- return o;
84
- };
85
- return _setPrototypeOf(o, p);
79
+ function _inheritsLoose(t, o) {
80
+ t.prototype = Object.create(o.prototype), t.prototype.constructor = t, _setPrototypeOf(t, o);
86
81
  }
87
- function _assertThisInitialized(self) {
88
- if (self === void 0) {
89
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
90
- }
91
- return self;
82
+ function _setPrototypeOf(t, e) {
83
+ return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) {
84
+ return t.__proto__ = e, t;
85
+ }, _setPrototypeOf(t, e);
92
86
  }
93
87
 
94
88
  /**
@@ -207,18 +201,10 @@ var MathUtil = function () {
207
201
  }
208
202
  return r;
209
203
  };
210
- MathUtil.parseInt = function (_parseInt) {
211
- function parseInt(_x) {
212
- return _parseInt.apply(this, arguments);
213
- }
214
- parseInt.toString = function () {
215
- return _parseInt.toString();
216
- };
217
- return parseInt;
218
- }(function (value) {
204
+ MathUtil.parseInt = function (value) {
219
205
  var r = parseInt(value);
220
206
  return MathUtil.safeToInt(r);
221
- });
207
+ };
222
208
  MathUtil.safeToInt = function safeToInt(value) {
223
209
  MathUtil.verifyInt(value);
224
210
  return MathUtil.safeZero(value);
@@ -230,11 +216,7 @@ var MathUtil = function () {
230
216
  if (isNaN(value)) {
231
217
  throw new ArithmeticException('Invalid int value, using NaN as argument');
232
218
  }
233
- if (Number.isInteger) {
234
- if (!Number.isInteger(Number(value))) {
235
- throw new ArithmeticException("Invalid value: '" + value + "' is a float");
236
- }
237
- } else if (value % 1 !== 0) {
219
+ if (!Number.isInteger(Number(value))) {
238
220
  throw new ArithmeticException("Invalid value: '" + value + "' is a float");
239
221
  }
240
222
  if (value > MAX_SAFE_INTEGER || value < MIN_SAFE_INTEGER) {
@@ -369,7 +351,6 @@ var TemporalUnit = function () {
369
351
  }();
370
352
 
371
353
  var Duration = function (_TemporalAmount) {
372
- _inheritsLoose(Duration, _TemporalAmount);
373
354
  function Duration(seconds, nanos) {
374
355
  var _this;
375
356
  _this = _TemporalAmount.call(this) || this;
@@ -377,6 +358,7 @@ var Duration = function (_TemporalAmount) {
377
358
  _this._nanos = MathUtil.safeToInt(nanos);
378
359
  return _this;
379
360
  }
361
+ _inheritsLoose(Duration, _TemporalAmount);
380
362
  Duration.ofDays = function ofDays(days) {
381
363
  return Duration._create(MathUtil.safeMultiply(days, LocalTime.SECONDS_PER_DAY), 0);
382
364
  };
@@ -825,7 +807,6 @@ function _init$m() {
825
807
  }
826
808
 
827
809
  var ChronoUnit = function (_TemporalUnit) {
828
- _inheritsLoose(ChronoUnit, _TemporalUnit);
829
810
  function ChronoUnit(name, estimatedDuration) {
830
811
  var _this;
831
812
  _this = _TemporalUnit.call(this) || this;
@@ -833,6 +814,7 @@ var ChronoUnit = function (_TemporalUnit) {
833
814
  _this._duration = estimatedDuration;
834
815
  return _this;
835
816
  }
817
+ _inheritsLoose(ChronoUnit, _TemporalUnit);
836
818
  var _proto = ChronoUnit.prototype;
837
819
  _proto.duration = function duration() {
838
820
  return this._duration;
@@ -1034,6 +1016,15 @@ var ValueRange = function () {
1034
1016
  }();
1035
1017
 
1036
1018
  var ChronoField = function (_TemporalField) {
1019
+ function ChronoField(name, baseUnit, rangeUnit, range) {
1020
+ var _this;
1021
+ _this = _TemporalField.call(this) || this;
1022
+ _this._name = name;
1023
+ _this._baseUnit = baseUnit;
1024
+ _this._rangeUnit = rangeUnit;
1025
+ _this._range = range;
1026
+ return _this;
1027
+ }
1037
1028
  _inheritsLoose(ChronoField, _TemporalField);
1038
1029
  ChronoField.byName = function byName(fieldName) {
1039
1030
  for (var prop in ChronoField) {
@@ -1044,15 +1035,6 @@ var ChronoField = function (_TemporalField) {
1044
1035
  }
1045
1036
  }
1046
1037
  };
1047
- function ChronoField(name, baseUnit, rangeUnit, range) {
1048
- var _this;
1049
- _this = _TemporalField.call(this) || this;
1050
- _this._name = name;
1051
- _this._baseUnit = baseUnit;
1052
- _this._rangeUnit = rangeUnit;
1053
- _this._range = range;
1054
- return _this;
1055
- }
1056
1038
  var _proto = ChronoField.prototype;
1057
1039
  _proto.name = function name() {
1058
1040
  return this._name;
@@ -1203,10 +1185,10 @@ var TemporalAccessor = function () {
1203
1185
  }();
1204
1186
 
1205
1187
  var TemporalQuery = function (_Enum) {
1206
- _inheritsLoose(TemporalQuery, _Enum);
1207
1188
  function TemporalQuery() {
1208
1189
  return _Enum.apply(this, arguments) || this;
1209
1190
  }
1191
+ _inheritsLoose(TemporalQuery, _Enum);
1210
1192
  var _proto = TemporalQuery.prototype;
1211
1193
  _proto.queryFrom = function queryFrom(temporal) {
1212
1194
  abstractMethodFail('queryFrom');
@@ -1215,10 +1197,10 @@ var TemporalQuery = function (_Enum) {
1215
1197
  }(Enum);
1216
1198
  function createTemporalQuery(name, queryFromFunction) {
1217
1199
  var ExtendedTemporalQuery = function (_TemporalQuery) {
1218
- _inheritsLoose(ExtendedTemporalQuery, _TemporalQuery);
1219
1200
  function ExtendedTemporalQuery() {
1220
1201
  return _TemporalQuery.apply(this, arguments) || this;
1221
1202
  }
1203
+ _inheritsLoose(ExtendedTemporalQuery, _TemporalQuery);
1222
1204
  return ExtendedTemporalQuery;
1223
1205
  }(TemporalQuery);
1224
1206
  ExtendedTemporalQuery.prototype.queryFrom = queryFromFunction;
@@ -1226,7 +1208,6 @@ function createTemporalQuery(name, queryFromFunction) {
1226
1208
  }
1227
1209
 
1228
1210
  var DayOfWeek = function (_TemporalAccessor) {
1229
- _inheritsLoose(DayOfWeek, _TemporalAccessor);
1230
1211
  function DayOfWeek(ordinal, name) {
1231
1212
  var _this;
1232
1213
  _this = _TemporalAccessor.call(this) || this;
@@ -1234,6 +1215,7 @@ var DayOfWeek = function (_TemporalAccessor) {
1234
1215
  _this._name = name;
1235
1216
  return _this;
1236
1217
  }
1218
+ _inheritsLoose(DayOfWeek, _TemporalAccessor);
1237
1219
  var _proto = DayOfWeek.prototype;
1238
1220
  _proto.ordinal = function ordinal() {
1239
1221
  return this._ordinal;
@@ -1360,7 +1342,6 @@ function _init$j() {
1360
1342
  }
1361
1343
 
1362
1344
  var Month = function (_TemporalAccessor) {
1363
- _inheritsLoose(Month, _TemporalAccessor);
1364
1345
  function Month(value, name) {
1365
1346
  var _this;
1366
1347
  _this = _TemporalAccessor.call(this) || this;
@@ -1368,6 +1349,7 @@ var Month = function (_TemporalAccessor) {
1368
1349
  _this._name = name;
1369
1350
  return _this;
1370
1351
  }
1352
+ _inheritsLoose(Month, _TemporalAccessor);
1371
1353
  var _proto = Month.prototype;
1372
1354
  _proto.value = function value() {
1373
1355
  return this._value;
@@ -1605,7 +1587,6 @@ function _init$i() {
1605
1587
 
1606
1588
  var PATTERN = /([-+]?)P(?:([-+]?[0-9]+)Y)?(?:([-+]?[0-9]+)M)?(?:([-+]?[0-9]+)W)?(?:([-+]?[0-9]+)D)?/;
1607
1589
  var Period = function (_TemporalAmount) {
1608
- _inheritsLoose(Period, _TemporalAmount);
1609
1590
  function Period(years, months, days) {
1610
1591
  var _this;
1611
1592
  _this = _TemporalAmount.call(this) || this;
@@ -1617,7 +1598,7 @@ var Period = function (_TemporalAmount) {
1617
1598
  _this._years = _years;
1618
1599
  _this._months = _months;
1619
1600
  _this._days = _days;
1620
- Period.ZERO = _assertThisInitialized(_this);
1601
+ Period.ZERO = _this;
1621
1602
  }
1622
1603
  return Period.ZERO || _assertThisInitialized(_this);
1623
1604
  }
@@ -1626,6 +1607,7 @@ var Period = function (_TemporalAmount) {
1626
1607
  _this._days = _days;
1627
1608
  return _this;
1628
1609
  }
1610
+ _inheritsLoose(Period, _TemporalAmount);
1629
1611
  Period.ofYears = function ofYears(years) {
1630
1612
  return Period.create(years, 0, 0);
1631
1613
  };
@@ -1969,10 +1951,10 @@ function _init$h() {
1969
1951
  }();
1970
1952
 
1971
1953
  var ResolverStyle = function (_Enum) {
1972
- _inheritsLoose(ResolverStyle, _Enum);
1973
1954
  function ResolverStyle() {
1974
1955
  return _Enum.apply(this, arguments) || this;
1975
1956
  }
1957
+ _inheritsLoose(ResolverStyle, _Enum);
1976
1958
  return ResolverStyle;
1977
1959
  }(Enum);
1978
1960
  ResolverStyle.STRICT = new ResolverStyle('STRICT');
@@ -1980,10 +1962,10 @@ ResolverStyle.SMART = new ResolverStyle('SMART');
1980
1962
  ResolverStyle.LENIENT = new ResolverStyle('LENIENT');
1981
1963
 
1982
1964
  var Temporal = function (_TemporalAccessor) {
1983
- _inheritsLoose(Temporal, _TemporalAccessor);
1984
1965
  function Temporal() {
1985
1966
  return _TemporalAccessor.apply(this, arguments) || this;
1986
1967
  }
1968
+ _inheritsLoose(Temporal, _TemporalAccessor);
1987
1969
  var _proto = Temporal.prototype;
1988
1970
  _proto.isSupported = function isSupported(fieldOrUnit) {
1989
1971
  abstractMethodFail('isSupported');
@@ -2051,10 +2033,10 @@ if (typeof Symbol !== 'undefined' && Symbol.toPrimitive) {
2051
2033
  }
2052
2034
 
2053
2035
  var ChronoLocalDate = function (_Temporal) {
2054
- _inheritsLoose(ChronoLocalDate, _Temporal);
2055
2036
  function ChronoLocalDate() {
2056
2037
  return _Temporal.apply(this, arguments) || this;
2057
2038
  }
2039
+ _inheritsLoose(ChronoLocalDate, _Temporal);
2058
2040
  var _proto = ChronoLocalDate.prototype;
2059
2041
  _proto.isSupported = function isSupported(fieldOrUnit) {
2060
2042
  if (fieldOrUnit instanceof ChronoField) {
@@ -2236,13 +2218,13 @@ var ZoneRules = function () {
2236
2218
  return ZoneRules;
2237
2219
  }();
2238
2220
  var Fixed = function (_ZoneRules) {
2239
- _inheritsLoose(Fixed, _ZoneRules);
2240
2221
  function Fixed(offset) {
2241
2222
  var _this;
2242
2223
  _this = _ZoneRules.call(this) || this;
2243
2224
  _this._offset = offset;
2244
2225
  return _this;
2245
2226
  }
2227
+ _inheritsLoose(Fixed, _ZoneRules);
2246
2228
  var _proto2 = Fixed.prototype;
2247
2229
  _proto2.isFixedOffset = function isFixedOffset() {
2248
2230
  return true;
@@ -2304,16 +2286,16 @@ var Fixed = function (_ZoneRules) {
2304
2286
  var SECONDS_CACHE = {};
2305
2287
  var ID_CACHE = {};
2306
2288
  var ZoneOffset = function (_ZoneId) {
2307
- _inheritsLoose(ZoneOffset, _ZoneId);
2308
2289
  function ZoneOffset(totalSeconds) {
2309
2290
  var _this;
2310
2291
  _this = _ZoneId.call(this) || this;
2311
2292
  ZoneOffset._validateTotalSeconds(totalSeconds);
2312
2293
  _this._totalSeconds = MathUtil.safeToInt(totalSeconds);
2313
- _this._rules = ZoneRules.of(_assertThisInitialized(_this));
2294
+ _this._rules = ZoneRules.of(_this);
2314
2295
  _this._id = ZoneOffset._buildId(totalSeconds);
2315
2296
  return _this;
2316
2297
  }
2298
+ _inheritsLoose(ZoneOffset, _ZoneId);
2317
2299
  var _proto = ZoneOffset.prototype;
2318
2300
  _proto.totalSeconds = function totalSeconds() {
2319
2301
  return this._totalSeconds;
@@ -2509,12 +2491,6 @@ function _init$g() {
2509
2491
  }
2510
2492
 
2511
2493
  var DateTimeBuilder = function (_TemporalAccessor) {
2512
- _inheritsLoose(DateTimeBuilder, _TemporalAccessor);
2513
- DateTimeBuilder.create = function create(field, value) {
2514
- var dtb = new DateTimeBuilder();
2515
- dtb._addFieldValue(field, value);
2516
- return dtb;
2517
- };
2518
2494
  function DateTimeBuilder() {
2519
2495
  var _this;
2520
2496
  _this = _TemporalAccessor.call(this) || this;
@@ -2527,6 +2503,12 @@ var DateTimeBuilder = function (_TemporalAccessor) {
2527
2503
  _this.excessDays = null;
2528
2504
  return _this;
2529
2505
  }
2506
+ _inheritsLoose(DateTimeBuilder, _TemporalAccessor);
2507
+ DateTimeBuilder.create = function create(field, value) {
2508
+ var dtb = new DateTimeBuilder();
2509
+ dtb._addFieldValue(field, value);
2510
+ return dtb;
2511
+ };
2530
2512
  var _proto = DateTimeBuilder.prototype;
2531
2513
  _proto.getFieldValue0 = function getFieldValue0(field) {
2532
2514
  return this.fieldValues.get(field);
@@ -2964,7 +2946,6 @@ var DateTimeParseContext = function () {
2964
2946
  return DateTimeParseContext;
2965
2947
  }();
2966
2948
  var Parsed = function (_Temporal) {
2967
- _inheritsLoose(Parsed, _Temporal);
2968
2949
  function Parsed(dateTimeParseContext) {
2969
2950
  var _this;
2970
2951
  _this = _Temporal.call(this) || this;
@@ -2975,6 +2956,7 @@ var Parsed = function (_Temporal) {
2975
2956
  _this.dateTimeParseContext = dateTimeParseContext;
2976
2957
  return _this;
2977
2958
  }
2959
+ _inheritsLoose(Parsed, _Temporal);
2978
2960
  var _proto2 = Parsed.prototype;
2979
2961
  _proto2.copy = function copy() {
2980
2962
  var cloned = new Parsed();
@@ -3088,10 +3070,10 @@ var DateTimePrintContext = function () {
3088
3070
  var IsoFields = {};
3089
3071
  var QUARTER_DAYS = [0, 90, 181, 273, 0, 91, 182, 274];
3090
3072
  var Field = function (_TemporalField) {
3091
- _inheritsLoose(Field, _TemporalField);
3092
3073
  function Field() {
3093
3074
  return _TemporalField.apply(this, arguments) || this;
3094
3075
  }
3076
+ _inheritsLoose(Field, _TemporalField);
3095
3077
  var _proto = Field.prototype;
3096
3078
  _proto.isDateBased = function isDateBased() {
3097
3079
  return true;
@@ -3163,10 +3145,10 @@ var Field = function (_TemporalField) {
3163
3145
  return Field;
3164
3146
  }(TemporalField);
3165
3147
  var DAY_OF_QUARTER_FIELD = function (_Field) {
3166
- _inheritsLoose(DAY_OF_QUARTER_FIELD, _Field);
3167
3148
  function DAY_OF_QUARTER_FIELD() {
3168
3149
  return _Field.apply(this, arguments) || this;
3169
3150
  }
3151
+ _inheritsLoose(DAY_OF_QUARTER_FIELD, _Field);
3170
3152
  var _proto2 = DAY_OF_QUARTER_FIELD.prototype;
3171
3153
  _proto2.toString = function toString() {
3172
3154
  return 'DayOfQuarter';
@@ -3249,10 +3231,10 @@ var DAY_OF_QUARTER_FIELD = function (_Field) {
3249
3231
  return DAY_OF_QUARTER_FIELD;
3250
3232
  }(Field);
3251
3233
  var QUARTER_OF_YEAR_FIELD = function (_Field2) {
3252
- _inheritsLoose(QUARTER_OF_YEAR_FIELD, _Field2);
3253
3234
  function QUARTER_OF_YEAR_FIELD() {
3254
3235
  return _Field2.apply(this, arguments) || this;
3255
3236
  }
3237
+ _inheritsLoose(QUARTER_OF_YEAR_FIELD, _Field2);
3256
3238
  var _proto3 = QUARTER_OF_YEAR_FIELD.prototype;
3257
3239
  _proto3.toString = function toString() {
3258
3240
  return 'QuarterOfYear';
@@ -3287,10 +3269,10 @@ var QUARTER_OF_YEAR_FIELD = function (_Field2) {
3287
3269
  return QUARTER_OF_YEAR_FIELD;
3288
3270
  }(Field);
3289
3271
  var WEEK_OF_WEEK_BASED_YEAR_FIELD = function (_Field3) {
3290
- _inheritsLoose(WEEK_OF_WEEK_BASED_YEAR_FIELD, _Field3);
3291
3272
  function WEEK_OF_WEEK_BASED_YEAR_FIELD() {
3292
3273
  return _Field3.apply(this, arguments) || this;
3293
3274
  }
3275
+ _inheritsLoose(WEEK_OF_WEEK_BASED_YEAR_FIELD, _Field3);
3294
3276
  var _proto4 = WEEK_OF_WEEK_BASED_YEAR_FIELD.prototype;
3295
3277
  _proto4.toString = function toString() {
3296
3278
  return 'WeekOfWeekBasedYear';
@@ -3365,10 +3347,10 @@ var WEEK_OF_WEEK_BASED_YEAR_FIELD = function (_Field3) {
3365
3347
  return WEEK_OF_WEEK_BASED_YEAR_FIELD;
3366
3348
  }(Field);
3367
3349
  var WEEK_BASED_YEAR_FIELD = function (_Field4) {
3368
- _inheritsLoose(WEEK_BASED_YEAR_FIELD, _Field4);
3369
3350
  function WEEK_BASED_YEAR_FIELD() {
3370
3351
  return _Field4.apply(this, arguments) || this;
3371
3352
  }
3353
+ _inheritsLoose(WEEK_BASED_YEAR_FIELD, _Field4);
3372
3354
  var _proto5 = WEEK_BASED_YEAR_FIELD.prototype;
3373
3355
  _proto5.toString = function toString() {
3374
3356
  return 'WeekBasedYear';
@@ -3413,7 +3395,6 @@ var WEEK_BASED_YEAR_FIELD = function (_Field4) {
3413
3395
  return WEEK_BASED_YEAR_FIELD;
3414
3396
  }(Field);
3415
3397
  var Unit = function (_TemporalUnit) {
3416
- _inheritsLoose(Unit, _TemporalUnit);
3417
3398
  function Unit(name, estimatedDuration) {
3418
3399
  var _this;
3419
3400
  _this = _TemporalUnit.call(this) || this;
@@ -3421,6 +3402,7 @@ var Unit = function (_TemporalUnit) {
3421
3402
  _this._duration = estimatedDuration;
3422
3403
  return _this;
3423
3404
  }
3405
+ _inheritsLoose(Unit, _TemporalUnit);
3424
3406
  var _proto6 = Unit.prototype;
3425
3407
  _proto6.duration = function duration() {
3426
3408
  return this._duration;
@@ -3584,10 +3566,10 @@ var DecimalStyle = function () {
3584
3566
  DecimalStyle.STANDARD = new DecimalStyle('0', '+', '-', '.');
3585
3567
 
3586
3568
  var SignStyle = function (_Enum) {
3587
- _inheritsLoose(SignStyle, _Enum);
3588
3569
  function SignStyle() {
3589
3570
  return _Enum.apply(this, arguments) || this;
3590
3571
  }
3572
+ _inheritsLoose(SignStyle, _Enum);
3591
3573
  var _proto = SignStyle.prototype;
3592
3574
  _proto.parse = function parse(positive, strict, fixedWidth) {
3593
3575
  switch (this) {
@@ -3609,10 +3591,10 @@ SignStyle.EXCEEDS_PAD = new SignStyle('EXCEEDS_PAD');
3609
3591
  SignStyle.NOT_NEGATIVE = new SignStyle('NOT_NEGATIVE');
3610
3592
 
3611
3593
  var TextStyle = function (_Enum) {
3612
- _inheritsLoose(TextStyle, _Enum);
3613
3594
  function TextStyle() {
3614
3595
  return _Enum.apply(this, arguments) || this;
3615
3596
  }
3597
+ _inheritsLoose(TextStyle, _Enum);
3616
3598
  var _proto = TextStyle.prototype;
3617
3599
  _proto.isStandalone = function isStandalone() {
3618
3600
  switch (this) {
@@ -4073,7 +4055,6 @@ var NumberPrinterParser = function () {
4073
4055
  return NumberPrinterParser;
4074
4056
  }();
4075
4057
  var ReducedPrinterParser = function (_NumberPrinterParser) {
4076
- _inheritsLoose(ReducedPrinterParser, _NumberPrinterParser);
4077
4058
  function ReducedPrinterParser(field, width, maxWidth, baseValue, baseDate) {
4078
4059
  var _this;
4079
4060
  _this = _NumberPrinterParser.call(this, field, width, maxWidth, SignStyle.NOT_NEGATIVE) || this;
@@ -4098,6 +4079,7 @@ var ReducedPrinterParser = function (_NumberPrinterParser) {
4098
4079
  _this._baseDate = baseDate;
4099
4080
  return _this;
4100
4081
  }
4082
+ _inheritsLoose(ReducedPrinterParser, _NumberPrinterParser);
4101
4083
  var _proto2 = ReducedPrinterParser.prototype;
4102
4084
  _proto2._getValue = function _getValue(context, value) {
4103
4085
  var absValue = Math.abs(value);
@@ -4334,10 +4316,10 @@ var PadPrinterParserDecorator = function () {
4334
4316
  }();
4335
4317
 
4336
4318
  var SettingsParser = function (_Enum) {
4337
- _inheritsLoose(SettingsParser, _Enum);
4338
4319
  function SettingsParser() {
4339
4320
  return _Enum.apply(this, arguments) || this;
4340
4321
  }
4322
+ _inheritsLoose(SettingsParser, _Enum);
4341
4323
  var _proto = SettingsParser.prototype;
4342
4324
  _proto.print = function print() {
4343
4325
  return true;
@@ -4426,11 +4408,6 @@ var ZoneRulesProvider = function () {
4426
4408
  }();
4427
4409
 
4428
4410
  var ZoneRegion = function (_ZoneId) {
4429
- _inheritsLoose(ZoneRegion, _ZoneId);
4430
- ZoneRegion.ofId = function ofId(zoneId) {
4431
- var rules = ZoneRulesProvider.getRules(zoneId);
4432
- return new ZoneRegion(zoneId, rules);
4433
- };
4434
4411
  function ZoneRegion(id, rules) {
4435
4412
  var _this;
4436
4413
  _this = _ZoneId.call(this) || this;
@@ -4438,6 +4415,11 @@ var ZoneRegion = function (_ZoneId) {
4438
4415
  _this._rules = rules;
4439
4416
  return _this;
4440
4417
  }
4418
+ _inheritsLoose(ZoneRegion, _ZoneId);
4419
+ ZoneRegion.ofId = function ofId(zoneId) {
4420
+ var rules = ZoneRulesProvider.getRules(zoneId);
4421
+ return new ZoneRegion(zoneId, rules);
4422
+ };
4441
4423
  var _proto = ZoneRegion.prototype;
4442
4424
  _proto.id = function id() {
4443
4425
  return this._id;
@@ -4551,6 +4533,10 @@ var ZoneIdPrinterParser = function () {
4551
4533
  return ZoneIdPrinterParser;
4552
4534
  }();
4553
4535
  var ZoneIdTree = function () {
4536
+ function ZoneIdTree(size, treeMap) {
4537
+ this.size = size;
4538
+ this.treeMap = treeMap;
4539
+ }
4554
4540
  ZoneIdTree.createTreeMap = function createTreeMap(availableZoneIds) {
4555
4541
  var sortedZoneIds = availableZoneIds.sort(function (a, b) {
4556
4542
  return a.length - b.length;
@@ -4561,10 +4547,6 @@ var ZoneIdTree = function () {
4561
4547
  }
4562
4548
  return new ZoneIdTree(sortedZoneIds.length, treeMap);
4563
4549
  };
4564
- function ZoneIdTree(size, treeMap) {
4565
- this.size = size;
4566
- this.treeMap = treeMap;
4567
- }
4568
4550
  return ZoneIdTree;
4569
4551
  }();
4570
4552
  var ZoneIdTreeMap = function () {
@@ -5365,15 +5347,6 @@ function _init$e() {
5365
5347
  */
5366
5348
 
5367
5349
  var DateTimeFormatter = function () {
5368
- DateTimeFormatter.parsedExcessDays = function parsedExcessDays() {
5369
- return DateTimeFormatter.PARSED_EXCESS_DAYS;
5370
- };
5371
- DateTimeFormatter.parsedLeapSecond = function parsedLeapSecond() {
5372
- return DateTimeFormatter.PARSED_LEAP_SECOND;
5373
- };
5374
- DateTimeFormatter.ofPattern = function ofPattern(pattern) {
5375
- return new DateTimeFormatterBuilder().appendPattern(pattern).toFormatter();
5376
- };
5377
5350
  function DateTimeFormatter(printerParser, locale, decimalStyle, resolverStyle, resolverFields, chrono, zone) {
5378
5351
  if (chrono === void 0) {
5379
5352
  chrono = IsoChronology.INSTANCE;
@@ -5389,6 +5362,15 @@ var DateTimeFormatter = function () {
5389
5362
  this._chrono = chrono;
5390
5363
  this._zone = zone;
5391
5364
  }
5365
+ DateTimeFormatter.parsedExcessDays = function parsedExcessDays() {
5366
+ return DateTimeFormatter.PARSED_EXCESS_DAYS;
5367
+ };
5368
+ DateTimeFormatter.parsedLeapSecond = function parsedLeapSecond() {
5369
+ return DateTimeFormatter.PARSED_LEAP_SECOND;
5370
+ };
5371
+ DateTimeFormatter.ofPattern = function ofPattern(pattern) {
5372
+ return new DateTimeFormatterBuilder().appendPattern(pattern).toFormatter();
5373
+ };
5392
5374
  var _proto = DateTimeFormatter.prototype;
5393
5375
  _proto.locale = function locale() {
5394
5376
  return this._locale;
@@ -5543,6 +5525,13 @@ function _init$d() {
5543
5525
  }
5544
5526
 
5545
5527
  var MonthDay = function (_TemporalAccessor) {
5528
+ function MonthDay(month, dayOfMonth) {
5529
+ var _this;
5530
+ _this = _TemporalAccessor.call(this) || this;
5531
+ _this._month = MathUtil.safeToInt(month);
5532
+ _this._day = MathUtil.safeToInt(dayOfMonth);
5533
+ return _this;
5534
+ }
5546
5535
  _inheritsLoose(MonthDay, _TemporalAccessor);
5547
5536
  MonthDay.now = function now(zoneIdOrClock) {
5548
5537
  if (arguments.length === 0) {
@@ -5613,13 +5602,6 @@ var MonthDay = function (_TemporalAccessor) {
5613
5602
  requireInstance(formatter, DateTimeFormatter, 'formatter');
5614
5603
  return formatter.parse(text, MonthDay.FROM);
5615
5604
  };
5616
- function MonthDay(month, dayOfMonth) {
5617
- var _this;
5618
- _this = _TemporalAccessor.call(this) || this;
5619
- _this._month = MathUtil.safeToInt(month);
5620
- _this._day = MathUtil.safeToInt(dayOfMonth);
5621
- return _this;
5622
- }
5623
5605
  var _proto = MonthDay.prototype;
5624
5606
  _proto.monthValue = function monthValue() {
5625
5607
  return this._month;
@@ -5747,6 +5729,13 @@ function _init$c() {
5747
5729
  }
5748
5730
 
5749
5731
  var YearMonth = function (_Temporal) {
5732
+ function YearMonth(year, month) {
5733
+ var _this;
5734
+ _this = _Temporal.call(this) || this;
5735
+ _this._year = MathUtil.safeToInt(year);
5736
+ _this._month = MathUtil.safeToInt(month);
5737
+ return _this;
5738
+ }
5750
5739
  _inheritsLoose(YearMonth, _Temporal);
5751
5740
  YearMonth.now = function now(zoneIdOrClock) {
5752
5741
  if (arguments.length === 0) {
@@ -5811,13 +5800,6 @@ var YearMonth = function (_Temporal) {
5811
5800
  requireNonNull(formatter, 'formatter');
5812
5801
  return formatter.parse(text, YearMonth.FROM);
5813
5802
  };
5814
- function YearMonth(year, month) {
5815
- var _this;
5816
- _this = _Temporal.call(this) || this;
5817
- _this._year = MathUtil.safeToInt(year);
5818
- _this._month = MathUtil.safeToInt(month);
5819
- return _this;
5820
- }
5821
5803
  var _proto = YearMonth.prototype;
5822
5804
  _proto.isSupported = function isSupported(fieldOrUnit) {
5823
5805
  if (arguments.length === 1 && fieldOrUnit instanceof TemporalField) {
@@ -6071,13 +6053,13 @@ function _init$b() {
6071
6053
  }
6072
6054
 
6073
6055
  var Year = function (_Temporal) {
6074
- _inheritsLoose(Year, _Temporal);
6075
6056
  function Year(value) {
6076
6057
  var _this;
6077
6058
  _this = _Temporal.call(this) || this;
6078
6059
  _this._year = MathUtil.safeToInt(value);
6079
6060
  return _this;
6080
6061
  }
6062
+ _inheritsLoose(Year, _Temporal);
6081
6063
  var _proto = Year.prototype;
6082
6064
  _proto.value = function value() {
6083
6065
  return this._year;
@@ -6418,13 +6400,13 @@ var TemporalAdjusters = function () {
6418
6400
  return TemporalAdjusters;
6419
6401
  }();
6420
6402
  var Impl = function (_TemporalAdjuster) {
6421
- _inheritsLoose(Impl, _TemporalAdjuster);
6422
6403
  function Impl(ordinal) {
6423
6404
  var _this;
6424
6405
  _this = _TemporalAdjuster.call(this) || this;
6425
6406
  _this._ordinal = ordinal;
6426
6407
  return _this;
6427
6408
  }
6409
+ _inheritsLoose(Impl, _TemporalAdjuster);
6428
6410
  var _proto = Impl.prototype;
6429
6411
  _proto.adjustInto = function adjustInto(temporal) {
6430
6412
  switch (this._ordinal) {
@@ -6452,7 +6434,6 @@ Impl.FIRST_DAY_OF_YEAR = new Impl(3);
6452
6434
  Impl.LAST_DAY_OF_YEAR = new Impl(4);
6453
6435
  Impl.FIRST_DAY_OF_NEXT_YEAR = new Impl(5);
6454
6436
  var DayOfWeekInMonth = function (_TemporalAdjuster2) {
6455
- _inheritsLoose(DayOfWeekInMonth, _TemporalAdjuster2);
6456
6437
  function DayOfWeekInMonth(ordinal, dow) {
6457
6438
  var _this2;
6458
6439
  _this2 = _TemporalAdjuster2.call(this) || this;
@@ -6460,6 +6441,7 @@ var DayOfWeekInMonth = function (_TemporalAdjuster2) {
6460
6441
  _this2._dowValue = dow.value();
6461
6442
  return _this2;
6462
6443
  }
6444
+ _inheritsLoose(DayOfWeekInMonth, _TemporalAdjuster2);
6463
6445
  var _proto2 = DayOfWeekInMonth.prototype;
6464
6446
  _proto2.adjustInto = function adjustInto(temporal) {
6465
6447
  if (this._ordinal >= 0) {
@@ -6480,7 +6462,6 @@ var DayOfWeekInMonth = function (_TemporalAdjuster2) {
6480
6462
  return DayOfWeekInMonth;
6481
6463
  }(TemporalAdjuster);
6482
6464
  var RelativeDayOfWeek = function (_TemporalAdjuster3) {
6483
- _inheritsLoose(RelativeDayOfWeek, _TemporalAdjuster3);
6484
6465
  function RelativeDayOfWeek(relative, dayOfWeek) {
6485
6466
  var _this3;
6486
6467
  _this3 = _TemporalAdjuster3.call(this) || this;
@@ -6489,6 +6470,7 @@ var RelativeDayOfWeek = function (_TemporalAdjuster3) {
6489
6470
  _this3._dowValue = dayOfWeek.value();
6490
6471
  return _this3;
6491
6472
  }
6473
+ _inheritsLoose(RelativeDayOfWeek, _TemporalAdjuster3);
6492
6474
  var _proto3 = RelativeDayOfWeek.prototype;
6493
6475
  _proto3.adjustInto = function adjustInto(temporal) {
6494
6476
  var calDow = temporal.get(ChronoField.DAY_OF_WEEK);
@@ -6507,10 +6489,10 @@ var RelativeDayOfWeek = function (_TemporalAdjuster3) {
6507
6489
  }(TemporalAdjuster);
6508
6490
 
6509
6491
  var IsoChronology = function (_Enum) {
6510
- _inheritsLoose(IsoChronology, _Enum);
6511
6492
  function IsoChronology() {
6512
6493
  return _Enum.apply(this, arguments) || this;
6513
6494
  }
6495
+ _inheritsLoose(IsoChronology, _Enum);
6514
6496
  IsoChronology.isLeapYear = function isLeapYear(prolepticYear) {
6515
6497
  return (prolepticYear & 3) === 0 && (prolepticYear % 100 !== 0 || prolepticYear % 400 === 0);
6516
6498
  };
@@ -6640,6 +6622,17 @@ function _init$9() {
6640
6622
  }
6641
6623
 
6642
6624
  var OffsetTime = function (_Temporal) {
6625
+ function OffsetTime(time, offset) {
6626
+ var _this;
6627
+ _this = _Temporal.call(this) || this;
6628
+ requireNonNull(time, 'time');
6629
+ requireInstance(time, LocalTime, 'time');
6630
+ requireNonNull(offset, 'offset');
6631
+ requireInstance(offset, ZoneOffset, 'offset');
6632
+ _this._time = time;
6633
+ _this._offset = offset;
6634
+ return _this;
6635
+ }
6643
6636
  _inheritsLoose(OffsetTime, _Temporal);
6644
6637
  OffsetTime.from = function from(temporal) {
6645
6638
  requireNonNull(temporal, 'temporal');
@@ -6706,17 +6699,6 @@ var OffsetTime = function (_Temporal) {
6706
6699
  requireNonNull(formatter, 'formatter');
6707
6700
  return formatter.parse(text, OffsetTime.FROM);
6708
6701
  };
6709
- function OffsetTime(time, offset) {
6710
- var _this;
6711
- _this = _Temporal.call(this) || this;
6712
- requireNonNull(time, 'time');
6713
- requireInstance(time, LocalTime, 'time');
6714
- requireNonNull(offset, 'offset');
6715
- requireInstance(offset, ZoneOffset, 'offset');
6716
- _this._time = time;
6717
- _this._offset = offset;
6718
- return _this;
6719
- }
6720
6702
  var _proto = OffsetTime.prototype;
6721
6703
  _proto.adjustInto = function adjustInto(temporal) {
6722
6704
  return temporal.with(ChronoField.NANO_OF_DAY, this._time.toNanoOfDay()).with(ChronoField.OFFSET_SECONDS, this.offset().totalSeconds());
@@ -6967,10 +6949,10 @@ function _init$8() {
6967
6949
  }
6968
6950
 
6969
6951
  var ChronoZonedDateTime = function (_Temporal) {
6970
- _inheritsLoose(ChronoZonedDateTime, _Temporal);
6971
6952
  function ChronoZonedDateTime() {
6972
6953
  return _Temporal.apply(this, arguments) || this;
6973
6954
  }
6955
+ _inheritsLoose(ChronoZonedDateTime, _Temporal);
6974
6956
  var _proto = ChronoZonedDateTime.prototype;
6975
6957
  _proto.query = function query(_query) {
6976
6958
  if (_query === TemporalQueries.zoneId() || _query === TemporalQueries.zone()) {
@@ -7053,6 +7035,17 @@ function strcmp(a, b) {
7053
7035
  }
7054
7036
 
7055
7037
  var ZonedDateTime = function (_ChronoZonedDateTime) {
7038
+ function ZonedDateTime(dateTime, offset, zone) {
7039
+ var _this;
7040
+ requireNonNull(dateTime, 'dateTime');
7041
+ requireNonNull(offset, 'offset');
7042
+ requireNonNull(zone, 'zone');
7043
+ _this = _ChronoZonedDateTime.call(this) || this;
7044
+ _this._dateTime = dateTime;
7045
+ _this._offset = offset;
7046
+ _this._zone = zone;
7047
+ return _this;
7048
+ }
7056
7049
  _inheritsLoose(ZonedDateTime, _ChronoZonedDateTime);
7057
7050
  ZonedDateTime.now = function now(clockOrZone) {
7058
7051
  var clock;
@@ -7188,17 +7181,6 @@ var ZonedDateTime = function (_ChronoZonedDateTime) {
7188
7181
  requireNonNull(formatter, 'formatter');
7189
7182
  return formatter.parse(text, ZonedDateTime.FROM);
7190
7183
  };
7191
- function ZonedDateTime(dateTime, offset, zone) {
7192
- var _this;
7193
- requireNonNull(dateTime, 'dateTime');
7194
- requireNonNull(offset, 'offset');
7195
- requireNonNull(zone, 'zone');
7196
- _this = _ChronoZonedDateTime.call(this) || this;
7197
- _this._dateTime = dateTime;
7198
- _this._offset = offset;
7199
- _this._zone = zone;
7200
- return _this;
7201
- }
7202
7184
  var _proto = ZonedDateTime.prototype;
7203
7185
  _proto._resolveLocal = function _resolveLocal(newDateTime) {
7204
7186
  requireNonNull(newDateTime, 'newDateTime');
@@ -7499,6 +7481,17 @@ function _init$7() {
7499
7481
  }
7500
7482
 
7501
7483
  var OffsetDateTime = function (_Temporal) {
7484
+ function OffsetDateTime(dateTime, offset) {
7485
+ var _this;
7486
+ _this = _Temporal.call(this) || this;
7487
+ requireNonNull(dateTime, 'dateTime');
7488
+ requireInstance(dateTime, LocalDateTime, 'dateTime');
7489
+ requireNonNull(offset, 'offset');
7490
+ requireInstance(offset, ZoneOffset, 'offset');
7491
+ _this._dateTime = dateTime;
7492
+ _this._offset = offset;
7493
+ return _this;
7494
+ }
7502
7495
  _inheritsLoose(OffsetDateTime, _Temporal);
7503
7496
  OffsetDateTime.from = function from(temporal) {
7504
7497
  requireNonNull(temporal, 'temporal');
@@ -7526,8 +7519,8 @@ var OffsetDateTime = function (_Temporal) {
7526
7519
  if (clockOrZone instanceof ZoneId) {
7527
7520
  return OffsetDateTime.now(Clock.system(clockOrZone));
7528
7521
  } else if (clockOrZone instanceof Clock) {
7529
- var now = clockOrZone.instant();
7530
- return OffsetDateTime.ofInstant(now, clockOrZone.zone().rules().offset(now));
7522
+ var _now = clockOrZone.instant();
7523
+ return OffsetDateTime.ofInstant(_now, clockOrZone.zone().rules().offset(_now));
7531
7524
  } else {
7532
7525
  throw new IllegalArgumentException('clockOrZone must be an instance of ZoneId or Clock');
7533
7526
  }
@@ -7580,17 +7573,6 @@ var OffsetDateTime = function (_Temporal) {
7580
7573
  requireNonNull(formatter, 'formatter');
7581
7574
  return formatter.parse(text, OffsetDateTime.FROM);
7582
7575
  };
7583
- function OffsetDateTime(dateTime, offset) {
7584
- var _this;
7585
- _this = _Temporal.call(this) || this;
7586
- requireNonNull(dateTime, 'dateTime');
7587
- requireInstance(dateTime, LocalDateTime, 'dateTime');
7588
- requireNonNull(offset, 'offset');
7589
- requireInstance(offset, ZoneOffset, 'offset');
7590
- _this._dateTime = dateTime;
7591
- _this._offset = offset;
7592
- return _this;
7593
- }
7594
7576
  var _proto = OffsetDateTime.prototype;
7595
7577
  _proto.adjustInto = function adjustInto(temporal) {
7596
7578
  return temporal.with(ChronoField.EPOCH_DAY, this.toLocalDate().toEpochDay()).with(ChronoField.NANO_OF_DAY, this.toLocalTime().toNanoOfDay()).with(ChronoField.OFFSET_SECONDS, this.offset().totalSeconds());
@@ -7928,6 +7910,21 @@ function _init$6() {
7928
7910
  var DAYS_PER_CYCLE = 146097;
7929
7911
  var DAYS_0000_TO_1970 = DAYS_PER_CYCLE * 5 - (30 * 365 + 7);
7930
7912
  var LocalDate = function (_ChronoLocalDate) {
7913
+ function LocalDate(year, month, dayOfMonth) {
7914
+ var _this;
7915
+ _this = _ChronoLocalDate.call(this) || this;
7916
+ requireNonNull(year, 'year');
7917
+ requireNonNull(month, 'month');
7918
+ requireNonNull(dayOfMonth, 'dayOfMonth');
7919
+ if (month instanceof Month) {
7920
+ month = month.value();
7921
+ }
7922
+ _this._year = MathUtil.safeToInt(year);
7923
+ _this._month = MathUtil.safeToInt(month);
7924
+ _this._day = MathUtil.safeToInt(dayOfMonth);
7925
+ LocalDate._validate(_this._year, _this._month, _this._day);
7926
+ return _this;
7927
+ }
7931
7928
  _inheritsLoose(LocalDate, _ChronoLocalDate);
7932
7929
  LocalDate.now = function now(clockOrZone) {
7933
7930
  var clock;
@@ -8024,21 +8021,6 @@ var LocalDate = function (_ChronoLocalDate) {
8024
8021
  }
8025
8022
  return LocalDate.of(year, month, day);
8026
8023
  };
8027
- function LocalDate(year, month, dayOfMonth) {
8028
- var _this;
8029
- _this = _ChronoLocalDate.call(this) || this;
8030
- requireNonNull(year, 'year');
8031
- requireNonNull(month, 'month');
8032
- requireNonNull(dayOfMonth, 'dayOfMonth');
8033
- if (month instanceof Month) {
8034
- month = month.value();
8035
- }
8036
- _this._year = MathUtil.safeToInt(year);
8037
- _this._month = MathUtil.safeToInt(month);
8038
- _this._day = MathUtil.safeToInt(dayOfMonth);
8039
- LocalDate._validate(_this._year, _this._month, _this._day);
8040
- return _this;
8041
- }
8042
8024
  LocalDate._validate = function _validate(year, month, dayOfMonth) {
8043
8025
  var dom;
8044
8026
  ChronoField.YEAR.checkValidValue(year);
@@ -8537,10 +8519,10 @@ function _init$5() {
8537
8519
  }
8538
8520
 
8539
8521
  var ChronoLocalDateTime = function (_Temporal) {
8540
- _inheritsLoose(ChronoLocalDateTime, _Temporal);
8541
8522
  function ChronoLocalDateTime() {
8542
8523
  return _Temporal.apply(this, arguments) || this;
8543
8524
  }
8525
+ _inheritsLoose(ChronoLocalDateTime, _Temporal);
8544
8526
  var _proto = ChronoLocalDateTime.prototype;
8545
8527
  _proto.chronology = function chronology() {
8546
8528
  return this.toLocalDate().chronology();
@@ -8577,6 +8559,15 @@ var ChronoLocalDateTime = function (_Temporal) {
8577
8559
  }(Temporal);
8578
8560
 
8579
8561
  var LocalDateTime = function (_ChronoLocalDateTime) {
8562
+ function LocalDateTime(date, time) {
8563
+ var _this;
8564
+ _this = _ChronoLocalDateTime.call(this) || this;
8565
+ requireInstance(date, LocalDate, 'date');
8566
+ requireInstance(time, LocalTime, 'time');
8567
+ _this._date = date;
8568
+ _this._time = time;
8569
+ return _this;
8570
+ }
8580
8571
  _inheritsLoose(LocalDateTime, _ChronoLocalDateTime);
8581
8572
  LocalDateTime.now = function now(clockOrZone) {
8582
8573
  if (clockOrZone == null) {
@@ -8680,15 +8671,6 @@ var LocalDateTime = function (_ChronoLocalDateTime) {
8680
8671
  requireNonNull(formatter, 'formatter');
8681
8672
  return formatter.parse(text, LocalDateTime.FROM);
8682
8673
  };
8683
- function LocalDateTime(date, time) {
8684
- var _this;
8685
- _this = _ChronoLocalDateTime.call(this) || this;
8686
- requireInstance(date, LocalDate, 'date');
8687
- requireInstance(time, LocalTime, 'time');
8688
- _this._date = date;
8689
- _this._time = time;
8690
- return _this;
8691
- }
8692
8674
  var _proto = LocalDateTime.prototype;
8693
8675
  _proto._withDateTime = function _withDateTime(newDate, newTime) {
8694
8676
  if (this._date.equals(newDate) && this._time.equals(newTime)) {
@@ -9027,6 +9009,42 @@ function _init$4() {
9027
9009
  }
9028
9010
 
9029
9011
  var LocalTime = function (_Temporal) {
9012
+ function LocalTime(hour, minute, second, nanoOfSecond) {
9013
+ var _this;
9014
+ if (hour === void 0) {
9015
+ hour = 0;
9016
+ }
9017
+ if (minute === void 0) {
9018
+ minute = 0;
9019
+ }
9020
+ if (second === void 0) {
9021
+ second = 0;
9022
+ }
9023
+ if (nanoOfSecond === void 0) {
9024
+ nanoOfSecond = 0;
9025
+ }
9026
+ _this = _Temporal.call(this) || this;
9027
+ var _hour = MathUtil.safeToInt(hour);
9028
+ var _minute = MathUtil.safeToInt(minute);
9029
+ var _second = MathUtil.safeToInt(second);
9030
+ var _nanoOfSecond = MathUtil.safeToInt(nanoOfSecond);
9031
+ LocalTime._validate(_hour, _minute, _second, _nanoOfSecond);
9032
+ if (_minute === 0 && _second === 0 && _nanoOfSecond === 0) {
9033
+ if (!LocalTime.HOURS[_hour]) {
9034
+ _this._hour = _hour;
9035
+ _this._minute = _minute;
9036
+ _this._second = _second;
9037
+ _this._nano = _nanoOfSecond;
9038
+ LocalTime.HOURS[_hour] = _this;
9039
+ }
9040
+ return LocalTime.HOURS[_hour] || _assertThisInitialized(_this);
9041
+ }
9042
+ _this._hour = _hour;
9043
+ _this._minute = _minute;
9044
+ _this._second = _second;
9045
+ _this._nano = _nanoOfSecond;
9046
+ return _this;
9047
+ }
9030
9048
  _inheritsLoose(LocalTime, _Temporal);
9031
9049
  LocalTime.now = function now(clockOrZone) {
9032
9050
  if (clockOrZone == null) {
@@ -9102,42 +9120,6 @@ var LocalTime = function (_Temporal) {
9102
9120
  requireNonNull(formatter, 'formatter');
9103
9121
  return formatter.parse(text, LocalTime.FROM);
9104
9122
  };
9105
- function LocalTime(hour, minute, second, nanoOfSecond) {
9106
- var _this;
9107
- if (hour === void 0) {
9108
- hour = 0;
9109
- }
9110
- if (minute === void 0) {
9111
- minute = 0;
9112
- }
9113
- if (second === void 0) {
9114
- second = 0;
9115
- }
9116
- if (nanoOfSecond === void 0) {
9117
- nanoOfSecond = 0;
9118
- }
9119
- _this = _Temporal.call(this) || this;
9120
- var _hour = MathUtil.safeToInt(hour);
9121
- var _minute = MathUtil.safeToInt(minute);
9122
- var _second = MathUtil.safeToInt(second);
9123
- var _nanoOfSecond = MathUtil.safeToInt(nanoOfSecond);
9124
- LocalTime._validate(_hour, _minute, _second, _nanoOfSecond);
9125
- if (_minute === 0 && _second === 0 && _nanoOfSecond === 0) {
9126
- if (!LocalTime.HOURS[_hour]) {
9127
- _this._hour = _hour;
9128
- _this._minute = _minute;
9129
- _this._second = _second;
9130
- _this._nano = _nanoOfSecond;
9131
- LocalTime.HOURS[_hour] = _assertThisInitialized(_this);
9132
- }
9133
- return LocalTime.HOURS[_hour] || _assertThisInitialized(_this);
9134
- }
9135
- _this._hour = _hour;
9136
- _this._minute = _minute;
9137
- _this._second = _second;
9138
- _this._nano = _nanoOfSecond;
9139
- return _this;
9140
- }
9141
9123
  LocalTime._validate = function _validate(hour, minute, second, nanoOfSecond) {
9142
9124
  ChronoField.HOUR_OF_DAY.checkValidValue(hour);
9143
9125
  ChronoField.MINUTE_OF_HOUR.checkValidValue(minute);
@@ -9562,6 +9544,14 @@ LocalTime.NANOS_PER_DAY = LocalTime.NANOS_PER_HOUR * LocalTime.HOURS_PER_DAY;
9562
9544
 
9563
9545
  var NANOS_PER_MILLI = 1000000;
9564
9546
  var Instant = function (_Temporal) {
9547
+ function Instant(seconds, nanoOfSecond) {
9548
+ var _this;
9549
+ _this = _Temporal.call(this) || this;
9550
+ Instant._validate(seconds, nanoOfSecond);
9551
+ _this._seconds = MathUtil.safeToInt(seconds);
9552
+ _this._nanos = MathUtil.safeToInt(nanoOfSecond);
9553
+ return _this;
9554
+ }
9565
9555
  _inheritsLoose(Instant, _Temporal);
9566
9556
  Instant.now = function now(clock) {
9567
9557
  if (clock === void 0) {
@@ -9613,14 +9603,6 @@ var Instant = function (_Temporal) {
9613
9603
  throw new DateTimeException('Instant exceeds minimum or maximum instant');
9614
9604
  }
9615
9605
  };
9616
- function Instant(seconds, nanoOfSecond) {
9617
- var _this;
9618
- _this = _Temporal.call(this) || this;
9619
- Instant._validate(seconds, nanoOfSecond);
9620
- _this._seconds = MathUtil.safeToInt(seconds);
9621
- _this._nanos = MathUtil.safeToInt(nanoOfSecond);
9622
- return _this;
9623
- }
9624
9606
  var _proto = Instant.prototype;
9625
9607
  _proto.isSupported = function isSupported(fieldOrUnit) {
9626
9608
  if (fieldOrUnit instanceof ChronoField) {
@@ -9913,7 +9895,6 @@ var Clock = function () {
9913
9895
  return Clock;
9914
9896
  }();
9915
9897
  var SystemClock = function (_Clock) {
9916
- _inheritsLoose(SystemClock, _Clock);
9917
9898
  function SystemClock(zone) {
9918
9899
  var _this;
9919
9900
  requireNonNull(zone, 'zone');
@@ -9921,6 +9902,7 @@ var SystemClock = function (_Clock) {
9921
9902
  _this._zone = zone;
9922
9903
  return _this;
9923
9904
  }
9905
+ _inheritsLoose(SystemClock, _Clock);
9924
9906
  var _proto2 = SystemClock.prototype;
9925
9907
  _proto2.zone = function zone() {
9926
9908
  return this._zone;
@@ -9949,7 +9931,6 @@ var SystemClock = function (_Clock) {
9949
9931
  return SystemClock;
9950
9932
  }(Clock);
9951
9933
  var FixedClock = function (_Clock2) {
9952
- _inheritsLoose(FixedClock, _Clock2);
9953
9934
  function FixedClock(fixedInstant, zoneId) {
9954
9935
  var _this2;
9955
9936
  _this2 = _Clock2.call(this) || this;
@@ -9957,6 +9938,7 @@ var FixedClock = function (_Clock2) {
9957
9938
  _this2._zoneId = zoneId;
9958
9939
  return _this2;
9959
9940
  }
9941
+ _inheritsLoose(FixedClock, _Clock2);
9960
9942
  var _proto3 = FixedClock.prototype;
9961
9943
  _proto3.instant = function instant() {
9962
9944
  return this._instant;
@@ -9985,7 +9967,6 @@ var FixedClock = function (_Clock2) {
9985
9967
  return FixedClock;
9986
9968
  }(Clock);
9987
9969
  var OffsetClock = function (_Clock3) {
9988
- _inheritsLoose(OffsetClock, _Clock3);
9989
9970
  function OffsetClock(baseClock, offset) {
9990
9971
  var _this3;
9991
9972
  _this3 = _Clock3.call(this) || this;
@@ -9993,6 +9974,7 @@ var OffsetClock = function (_Clock3) {
9993
9974
  _this3._offset = offset;
9994
9975
  return _this3;
9995
9976
  }
9977
+ _inheritsLoose(OffsetClock, _Clock3);
9996
9978
  var _proto4 = OffsetClock.prototype;
9997
9979
  _proto4.zone = function zone() {
9998
9980
  return this._baseClock.zone();
@@ -10028,9 +10010,6 @@ var OffsetClock = function (_Clock3) {
10028
10010
  */
10029
10011
 
10030
10012
  var ZoneOffsetTransition = function () {
10031
- ZoneOffsetTransition.of = function of(transition, offsetBefore, offsetAfter) {
10032
- return new ZoneOffsetTransition(transition, offsetBefore, offsetAfter);
10033
- };
10034
10013
  function ZoneOffsetTransition(transition, offsetBefore, offsetAfter) {
10035
10014
  requireNonNull(transition, 'transition');
10036
10015
  requireNonNull(offsetBefore, 'offsetBefore');
@@ -10049,6 +10028,9 @@ var ZoneOffsetTransition = function () {
10049
10028
  this._offsetBefore = offsetBefore;
10050
10029
  this._offsetAfter = offsetAfter;
10051
10030
  }
10031
+ ZoneOffsetTransition.of = function of(transition, offsetBefore, offsetAfter) {
10032
+ return new ZoneOffsetTransition(transition, offsetBefore, offsetAfter);
10033
+ };
10052
10034
  var _proto = ZoneOffsetTransition.prototype;
10053
10035
  _proto.instant = function instant() {
10054
10036
  return this._transition.toInstant(this._offsetBefore);
@@ -10153,10 +10135,10 @@ function _init$1() {
10153
10135
  }
10154
10136
 
10155
10137
  var SystemDefaultZoneRules = function (_ZoneRules) {
10156
- _inheritsLoose(SystemDefaultZoneRules, _ZoneRules);
10157
10138
  function SystemDefaultZoneRules() {
10158
10139
  return _ZoneRules.apply(this, arguments) || this;
10159
10140
  }
10141
+ _inheritsLoose(SystemDefaultZoneRules, _ZoneRules);
10160
10142
  var _proto = SystemDefaultZoneRules.prototype;
10161
10143
  _proto.isFixedOffset = function isFixedOffset() {
10162
10144
  return false;
@@ -10223,13 +10205,13 @@ var SystemDefaultZoneRules = function (_ZoneRules) {
10223
10205
  }(ZoneRules);
10224
10206
 
10225
10207
  var SystemDefaultZoneId = function (_ZoneId) {
10226
- _inheritsLoose(SystemDefaultZoneId, _ZoneId);
10227
10208
  function SystemDefaultZoneId() {
10228
10209
  var _this;
10229
10210
  _this = _ZoneId.call(this) || this;
10230
10211
  _this._rules = new SystemDefaultZoneRules();
10231
10212
  return _this;
10232
10213
  }
10214
+ _inheritsLoose(SystemDefaultZoneId, _ZoneId);
10233
10215
  var _proto = SystemDefaultZoneId.prototype;
10234
10216
  _proto.rules = function rules() {
10235
10217
  return this._rules;
@@ -10420,12 +10402,7 @@ function nativeJs(date, zone) {
10420
10402
  }
10421
10403
  requireNonNull(date, 'date');
10422
10404
  requireNonNull(zone, 'zone');
10423
- if (date instanceof Date) {
10424
- return Instant.ofEpochMilli(date.getTime()).atZone(zone);
10425
- } else if (typeof date.toDate === 'function' && date.toDate() instanceof Date) {
10426
- return Instant.ofEpochMilli(date.toDate().getTime()).atZone(zone);
10427
- }
10428
- throw new IllegalArgumentException('date must be a javascript Date or a moment instance');
10405
+ return Instant.ofEpochMilli(date.valueOf()).atZone(zone);
10429
10406
  }
10430
10407
 
10431
10408
  function bindUse(jsJoda) {