@blackglory/structures 0.2.6 → 0.3.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/CHANGELOG.md +32 -0
- package/README.md +50 -13
- package/dist/es2015/index.min.mjs +16 -2
- package/dist/es2015/index.min.mjs.map +1 -1
- package/dist/es2015/index.mjs +1479 -319
- package/dist/es2015/index.mjs.map +1 -1
- package/dist/es2015/index.umd.js +1482 -318
- package/dist/es2015/index.umd.js.map +1 -1
- package/dist/es2015/index.umd.min.js +15 -2
- package/dist/es2015/index.umd.min.js.map +1 -1
- package/dist/es2018/index.min.mjs +16 -2
- package/dist/es2018/index.min.mjs.map +1 -1
- package/dist/es2018/index.mjs +1479 -319
- package/dist/es2018/index.mjs.map +1 -1
- package/dist/es2018/index.umd.js +1482 -318
- package/dist/es2018/index.umd.js.map +1 -1
- package/dist/es2018/index.umd.min.js +15 -2
- package/dist/es2018/index.umd.min.js.map +1 -1
- package/lib/es2015/box.d.ts +6 -0
- package/lib/es2015/box.js +30 -0
- package/lib/es2015/box.js.map +1 -0
- package/lib/es2015/finite-state-machine.d.ts +13 -0
- package/lib/es2015/finite-state-machine.js +46 -0
- package/lib/es2015/finite-state-machine.js.map +1 -0
- package/lib/es2015/index.d.ts +3 -0
- package/lib/es2015/index.js +3 -0
- package/lib/es2015/index.js.map +1 -1
- package/lib/es2015/observable-finite-state-machine.d.ts +13 -0
- package/lib/es2015/observable-finite-state-machine.js +28 -0
- package/lib/es2015/observable-finite-state-machine.js.map +1 -0
- package/lib/es2018/box.d.ts +6 -0
- package/lib/es2018/box.js +30 -0
- package/lib/es2018/box.js.map +1 -0
- package/lib/es2018/finite-state-machine.d.ts +13 -0
- package/lib/es2018/finite-state-machine.js +46 -0
- package/lib/es2018/finite-state-machine.js.map +1 -0
- package/lib/es2018/index.d.ts +3 -0
- package/lib/es2018/index.js +3 -0
- package/lib/es2018/index.js.map +1 -1
- package/lib/es2018/observable-finite-state-machine.d.ts +13 -0
- package/lib/es2018/observable-finite-state-machine.js +28 -0
- package/lib/es2018/observable-finite-state-machine.js.map +1 -0
- package/package.json +25 -23
package/dist/es2018/index.umd.js
CHANGED
|
@@ -4,15 +4,6 @@
|
|
|
4
4
|
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.Structures = {}));
|
|
5
5
|
})(this, (function (exports) { 'use strict';
|
|
6
6
|
|
|
7
|
-
function convertConsToArray([value, next]) {
|
|
8
|
-
if (next === null)
|
|
9
|
-
return [value];
|
|
10
|
-
return [value, ...convertConsToArray(next)];
|
|
11
|
-
}
|
|
12
|
-
function convertArrayToCons([value, ...next]) {
|
|
13
|
-
return [value, next.length ? convertArrayToCons(next) : null];
|
|
14
|
-
}
|
|
15
|
-
|
|
16
7
|
/*! *****************************************************************************
|
|
17
8
|
Copyright (c) Microsoft Corporation.
|
|
18
9
|
|
|
@@ -41,6 +32,30 @@
|
|
|
41
32
|
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
|
42
33
|
}
|
|
43
34
|
|
|
35
|
+
var _Box_value;
|
|
36
|
+
class Box {
|
|
37
|
+
constructor(value) {
|
|
38
|
+
_Box_value.set(this, void 0);
|
|
39
|
+
__classPrivateFieldSet(this, _Box_value, value, "f");
|
|
40
|
+
}
|
|
41
|
+
set(value) {
|
|
42
|
+
__classPrivateFieldSet(this, _Box_value, value, "f");
|
|
43
|
+
}
|
|
44
|
+
get() {
|
|
45
|
+
return __classPrivateFieldGet(this, _Box_value, "f");
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
_Box_value = new WeakMap();
|
|
49
|
+
|
|
50
|
+
function convertConsToArray([value, next]) {
|
|
51
|
+
if (next === null)
|
|
52
|
+
return [value];
|
|
53
|
+
return [value, ...convertConsToArray(next)];
|
|
54
|
+
}
|
|
55
|
+
function convertArrayToCons([value, ...next]) {
|
|
56
|
+
return [value, next.length ? convertArrayToCons(next) : null];
|
|
57
|
+
}
|
|
58
|
+
|
|
44
59
|
var _Emitter_map;
|
|
45
60
|
class Emitter {
|
|
46
61
|
constructor() {
|
|
@@ -169,7 +184,7 @@
|
|
|
169
184
|
|
|
170
185
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
171
186
|
|
|
172
|
-
var es2018$
|
|
187
|
+
var es2018$6 = {};
|
|
173
188
|
|
|
174
189
|
var customError = {};
|
|
175
190
|
|
|
@@ -247,15 +262,15 @@
|
|
|
247
262
|
__exportStar(refute$1, exports);
|
|
248
263
|
__exportStar(assert$1, exports);
|
|
249
264
|
|
|
250
|
-
}(es2018$
|
|
265
|
+
}(es2018$6));
|
|
251
266
|
|
|
252
|
-
var es2018$
|
|
267
|
+
var es2018$5 = {};
|
|
253
268
|
|
|
254
269
|
var middleware = {};
|
|
255
270
|
|
|
256
271
|
var chunkAsync$1 = {};
|
|
257
272
|
|
|
258
|
-
var es2018$
|
|
273
|
+
var es2018$4 = {};
|
|
259
274
|
|
|
260
275
|
var go$1 = {};
|
|
261
276
|
|
|
@@ -277,11 +292,11 @@
|
|
|
277
292
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
278
293
|
};__exportStar(go$1, exports);
|
|
279
294
|
|
|
280
|
-
}(es2018$
|
|
295
|
+
}(es2018$4));
|
|
281
296
|
|
|
282
297
|
chunkAsync$1.chunkAsync = void 0;
|
|
283
|
-
const go_1$f = es2018$
|
|
284
|
-
const errors_1$f = es2018$
|
|
298
|
+
const go_1$f = es2018$4;
|
|
299
|
+
const errors_1$f = es2018$6;
|
|
285
300
|
function chunkAsync(iterable, size) {
|
|
286
301
|
(0, errors_1$f.assert)(Number.isInteger(size), 'The parameter size must be an integer');
|
|
287
302
|
(0, errors_1$f.assert)(size > 0, 'The parameter size must be greater than 0');
|
|
@@ -302,297 +317,297 @@
|
|
|
302
317
|
|
|
303
318
|
var chunkByAsync$1 = {};
|
|
304
319
|
|
|
305
|
-
var es2018$
|
|
320
|
+
var es2018$3 = {};
|
|
306
321
|
|
|
307
|
-
var array = {};
|
|
322
|
+
var array$1 = {};
|
|
308
323
|
|
|
309
|
-
array.isntEmptyArray = array.isEmptyArray = array.isntArray = array.isArray = void 0;
|
|
310
|
-
function isArray(val) {
|
|
324
|
+
array$1.isntEmptyArray = array$1.isEmptyArray = array$1.isntArray = array$1.isArray = void 0;
|
|
325
|
+
function isArray$1(val) {
|
|
311
326
|
return Array.isArray(val);
|
|
312
327
|
}
|
|
313
|
-
array.isArray = isArray;
|
|
314
|
-
function isntArray(val) {
|
|
315
|
-
return !isArray(val);
|
|
328
|
+
array$1.isArray = isArray$1;
|
|
329
|
+
function isntArray$1(val) {
|
|
330
|
+
return !isArray$1(val);
|
|
316
331
|
}
|
|
317
|
-
array.isntArray = isntArray;
|
|
318
|
-
function isEmptyArray(val) {
|
|
332
|
+
array$1.isntArray = isntArray$1;
|
|
333
|
+
function isEmptyArray$1(val) {
|
|
319
334
|
return val.length === 0;
|
|
320
335
|
}
|
|
321
|
-
array.isEmptyArray = isEmptyArray;
|
|
322
|
-
function isntEmptyArray(val) {
|
|
336
|
+
array$1.isEmptyArray = isEmptyArray$1;
|
|
337
|
+
function isntEmptyArray$1(val) {
|
|
323
338
|
return val.length !== 0;
|
|
324
339
|
}
|
|
325
|
-
array.isntEmptyArray = isntEmptyArray;
|
|
340
|
+
array$1.isntEmptyArray = isntEmptyArray$1;
|
|
326
341
|
|
|
327
|
-
var asyncIterable = {};
|
|
342
|
+
var asyncIterable$1 = {};
|
|
328
343
|
|
|
329
|
-
var _null = {};
|
|
344
|
+
var _null$1 = {};
|
|
330
345
|
|
|
331
|
-
_null.isntNull = _null.isNull = void 0;
|
|
332
|
-
function isNull(val) {
|
|
346
|
+
_null$1.isntNull = _null$1.isNull = void 0;
|
|
347
|
+
function isNull$1(val) {
|
|
333
348
|
return val === null;
|
|
334
349
|
}
|
|
335
|
-
_null.isNull = isNull;
|
|
336
|
-
function isntNull(val) {
|
|
337
|
-
return !isNull(val);
|
|
350
|
+
_null$1.isNull = isNull$1;
|
|
351
|
+
function isntNull$1(val) {
|
|
352
|
+
return !isNull$1(val);
|
|
338
353
|
}
|
|
339
|
-
_null.isntNull = isntNull;
|
|
354
|
+
_null$1.isntNull = isntNull$1;
|
|
340
355
|
|
|
341
|
-
var _undefined = {};
|
|
356
|
+
var _undefined$1 = {};
|
|
342
357
|
|
|
343
|
-
_undefined.isntUndefined = _undefined.isUndefined = void 0;
|
|
344
|
-
function isUndefined(val) {
|
|
358
|
+
_undefined$1.isntUndefined = _undefined$1.isUndefined = void 0;
|
|
359
|
+
function isUndefined$1(val) {
|
|
345
360
|
return val === undefined;
|
|
346
361
|
}
|
|
347
|
-
_undefined.isUndefined = isUndefined;
|
|
348
|
-
function isntUndefined(val) {
|
|
349
|
-
return !isUndefined(val);
|
|
362
|
+
_undefined$1.isUndefined = isUndefined$1;
|
|
363
|
+
function isntUndefined$1(val) {
|
|
364
|
+
return !isUndefined$1(val);
|
|
350
365
|
}
|
|
351
|
-
_undefined.isntUndefined = isntUndefined;
|
|
366
|
+
_undefined$1.isntUndefined = isntUndefined$1;
|
|
352
367
|
|
|
353
|
-
asyncIterable.isntAsyncIterable = asyncIterable.isAsyncIterable = void 0;
|
|
354
|
-
const null_1$
|
|
355
|
-
const undefined_1$
|
|
356
|
-
function isAsyncIterable(val) {
|
|
357
|
-
return (0, null_1$
|
|
358
|
-
&& (0, undefined_1$
|
|
368
|
+
asyncIterable$1.isntAsyncIterable = asyncIterable$1.isAsyncIterable = void 0;
|
|
369
|
+
const null_1$3 = _null$1;
|
|
370
|
+
const undefined_1$5 = _undefined$1;
|
|
371
|
+
function isAsyncIterable$1(val) {
|
|
372
|
+
return (0, null_1$3.isntNull)(val)
|
|
373
|
+
&& (0, undefined_1$5.isntUndefined)(val)
|
|
359
374
|
&& typeof val[Symbol.asyncIterator] === 'function';
|
|
360
375
|
}
|
|
361
|
-
asyncIterable.isAsyncIterable = isAsyncIterable;
|
|
362
|
-
function isntAsyncIterable(val) {
|
|
363
|
-
return !isAsyncIterable(val);
|
|
376
|
+
asyncIterable$1.isAsyncIterable = isAsyncIterable$1;
|
|
377
|
+
function isntAsyncIterable$1(val) {
|
|
378
|
+
return !isAsyncIterable$1(val);
|
|
364
379
|
}
|
|
365
|
-
asyncIterable.isntAsyncIterable = isntAsyncIterable;
|
|
380
|
+
asyncIterable$1.isntAsyncIterable = isntAsyncIterable$1;
|
|
366
381
|
|
|
367
|
-
var bigint = {};
|
|
382
|
+
var bigint$1 = {};
|
|
368
383
|
|
|
369
|
-
bigint.isntBigInt = bigint.isBigInt = void 0;
|
|
370
|
-
function isBigInt(val) {
|
|
384
|
+
bigint$1.isntBigInt = bigint$1.isBigInt = void 0;
|
|
385
|
+
function isBigInt$1(val) {
|
|
371
386
|
return typeof val === 'bigint';
|
|
372
387
|
}
|
|
373
|
-
bigint.isBigInt = isBigInt;
|
|
374
|
-
function isntBigInt(val) {
|
|
375
|
-
return !isBigInt(val);
|
|
388
|
+
bigint$1.isBigInt = isBigInt$1;
|
|
389
|
+
function isntBigInt$1(val) {
|
|
390
|
+
return !isBigInt$1(val);
|
|
376
391
|
}
|
|
377
|
-
bigint.isntBigInt = isntBigInt;
|
|
392
|
+
bigint$1.isntBigInt = isntBigInt$1;
|
|
378
393
|
|
|
379
|
-
var boolean = {};
|
|
394
|
+
var boolean$1 = {};
|
|
380
395
|
|
|
381
|
-
boolean.isntBoolean = boolean.isBoolean = void 0;
|
|
382
|
-
function isBoolean(val) {
|
|
396
|
+
boolean$1.isntBoolean = boolean$1.isBoolean = void 0;
|
|
397
|
+
function isBoolean$1(val) {
|
|
383
398
|
return typeof val === 'boolean';
|
|
384
399
|
}
|
|
385
|
-
boolean.isBoolean = isBoolean;
|
|
386
|
-
function isntBoolean(val) {
|
|
387
|
-
return !isBoolean(val);
|
|
400
|
+
boolean$1.isBoolean = isBoolean$1;
|
|
401
|
+
function isntBoolean$1(val) {
|
|
402
|
+
return !isBoolean$1(val);
|
|
388
403
|
}
|
|
389
|
-
boolean.isntBoolean = isntBoolean;
|
|
404
|
+
boolean$1.isntBoolean = isntBoolean$1;
|
|
390
405
|
|
|
391
|
-
var char = {};
|
|
406
|
+
var char$1 = {};
|
|
392
407
|
|
|
393
|
-
var string = {};
|
|
408
|
+
var string$1 = {};
|
|
394
409
|
|
|
395
|
-
string.isntString = string.isString = void 0;
|
|
396
|
-
function isString(val) {
|
|
410
|
+
string$1.isntString = string$1.isString = void 0;
|
|
411
|
+
function isString$1(val) {
|
|
397
412
|
return typeof val === 'string';
|
|
398
413
|
}
|
|
399
|
-
string.isString = isString;
|
|
400
|
-
function isntString(val) {
|
|
401
|
-
return !isString(val);
|
|
414
|
+
string$1.isString = isString$1;
|
|
415
|
+
function isntString$1(val) {
|
|
416
|
+
return !isString$1(val);
|
|
402
417
|
}
|
|
403
|
-
string.isntString = isntString;
|
|
418
|
+
string$1.isntString = isntString$1;
|
|
404
419
|
|
|
405
|
-
char.isntChar = char.isChar = void 0;
|
|
406
|
-
const string_1$
|
|
407
|
-
function isChar(val) {
|
|
408
|
-
return (0, string_1$
|
|
420
|
+
char$1.isntChar = char$1.isChar = void 0;
|
|
421
|
+
const string_1$3 = string$1;
|
|
422
|
+
function isChar$1(val) {
|
|
423
|
+
return (0, string_1$3.isString)(val)
|
|
409
424
|
&& val.length === 1;
|
|
410
425
|
}
|
|
411
|
-
char.isChar = isChar;
|
|
412
|
-
function isntChar(val) {
|
|
413
|
-
return !isChar(val);
|
|
426
|
+
char$1.isChar = isChar$1;
|
|
427
|
+
function isntChar$1(val) {
|
|
428
|
+
return !isChar$1(val);
|
|
414
429
|
}
|
|
415
|
-
char.isntChar = isntChar;
|
|
430
|
+
char$1.isntChar = isntChar$1;
|
|
416
431
|
|
|
417
|
-
var date = {};
|
|
432
|
+
var date$1 = {};
|
|
418
433
|
|
|
419
|
-
date.isntDate = date.isDate = void 0;
|
|
420
|
-
function isDate(val) {
|
|
434
|
+
date$1.isntDate = date$1.isDate = void 0;
|
|
435
|
+
function isDate$1(val) {
|
|
421
436
|
return val instanceof Date;
|
|
422
437
|
}
|
|
423
|
-
date.isDate = isDate;
|
|
424
|
-
function isntDate(val) {
|
|
425
|
-
return !isDate(val);
|
|
438
|
+
date$1.isDate = isDate$1;
|
|
439
|
+
function isntDate$1(val) {
|
|
440
|
+
return !isDate$1(val);
|
|
426
441
|
}
|
|
427
|
-
date.isntDate = isntDate;
|
|
442
|
+
date$1.isntDate = isntDate$1;
|
|
428
443
|
|
|
429
|
-
var _enum = {};
|
|
444
|
+
var _enum$1 = {};
|
|
430
445
|
|
|
431
|
-
_enum.inEnum = void 0;
|
|
432
|
-
function inEnum(val, _enum) {
|
|
446
|
+
_enum$1.inEnum = void 0;
|
|
447
|
+
function inEnum$1(val, _enum) {
|
|
433
448
|
return Object.values(_enum).includes(val);
|
|
434
449
|
}
|
|
435
|
-
_enum.inEnum = inEnum;
|
|
450
|
+
_enum$1.inEnum = inEnum$1;
|
|
436
451
|
|
|
437
|
-
var error = {};
|
|
452
|
+
var error$1 = {};
|
|
438
453
|
|
|
439
|
-
error.isntError = error.isError = void 0;
|
|
440
|
-
function isError(val) {
|
|
454
|
+
error$1.isntError = error$1.isError = void 0;
|
|
455
|
+
function isError$1(val) {
|
|
441
456
|
return val instanceof Error;
|
|
442
457
|
}
|
|
443
|
-
error.isError = isError;
|
|
444
|
-
function isntError(val) {
|
|
445
|
-
return !isError(val);
|
|
458
|
+
error$1.isError = isError$1;
|
|
459
|
+
function isntError$1(val) {
|
|
460
|
+
return !isError$1(val);
|
|
446
461
|
}
|
|
447
|
-
error.isntError = isntError;
|
|
462
|
+
error$1.isntError = isntError$1;
|
|
448
463
|
|
|
449
|
-
var falsy = {};
|
|
464
|
+
var falsy$1 = {};
|
|
450
465
|
|
|
451
|
-
falsy.isntFalsy = falsy.isFalsy = void 0;
|
|
452
|
-
function isFalsy(val) {
|
|
466
|
+
falsy$1.isntFalsy = falsy$1.isFalsy = void 0;
|
|
467
|
+
function isFalsy$1(val) {
|
|
453
468
|
return !val;
|
|
454
469
|
}
|
|
455
|
-
falsy.isFalsy = isFalsy;
|
|
456
|
-
function isntFalsy(val) {
|
|
457
|
-
return !isFalsy(val);
|
|
470
|
+
falsy$1.isFalsy = isFalsy$1;
|
|
471
|
+
function isntFalsy$1(val) {
|
|
472
|
+
return !isFalsy$1(val);
|
|
458
473
|
}
|
|
459
|
-
falsy.isntFalsy = isntFalsy;
|
|
474
|
+
falsy$1.isntFalsy = isntFalsy$1;
|
|
460
475
|
|
|
461
|
-
var _function = {};
|
|
476
|
+
var _function$1 = {};
|
|
462
477
|
|
|
463
|
-
_function.isntFunction = _function.isFunction = void 0;
|
|
464
|
-
function isFunction(val) {
|
|
478
|
+
_function$1.isntFunction = _function$1.isFunction = void 0;
|
|
479
|
+
function isFunction$2(val) {
|
|
465
480
|
return typeof val === 'function';
|
|
466
481
|
}
|
|
467
|
-
_function.isFunction = isFunction;
|
|
468
|
-
function isntFunction(val) {
|
|
469
|
-
return !isFunction(val);
|
|
482
|
+
_function$1.isFunction = isFunction$2;
|
|
483
|
+
function isntFunction$1(val) {
|
|
484
|
+
return !isFunction$2(val);
|
|
470
485
|
}
|
|
471
|
-
_function.isntFunction = isntFunction;
|
|
486
|
+
_function$1.isntFunction = isntFunction$1;
|
|
472
487
|
|
|
473
|
-
var iterable = {};
|
|
488
|
+
var iterable$1 = {};
|
|
474
489
|
|
|
475
|
-
iterable.isntIterable = iterable.isIterable = void 0;
|
|
476
|
-
const null_1 = _null;
|
|
477
|
-
const undefined_1$
|
|
478
|
-
function isIterable(val) {
|
|
479
|
-
return (0, null_1.isntNull)(val)
|
|
480
|
-
&& (0, undefined_1$
|
|
490
|
+
iterable$1.isntIterable = iterable$1.isIterable = void 0;
|
|
491
|
+
const null_1$2 = _null$1;
|
|
492
|
+
const undefined_1$4 = _undefined$1;
|
|
493
|
+
function isIterable$1(val) {
|
|
494
|
+
return (0, null_1$2.isntNull)(val)
|
|
495
|
+
&& (0, undefined_1$4.isntUndefined)(val)
|
|
481
496
|
&& typeof val[Symbol.iterator] === 'function';
|
|
482
497
|
}
|
|
483
|
-
iterable.isIterable = isIterable;
|
|
484
|
-
function isntIterable(val) {
|
|
485
|
-
return !isIterable(val);
|
|
498
|
+
iterable$1.isIterable = isIterable$1;
|
|
499
|
+
function isntIterable$1(val) {
|
|
500
|
+
return !isIterable$1(val);
|
|
486
501
|
}
|
|
487
|
-
iterable.isntIterable = isntIterable;
|
|
502
|
+
iterable$1.isntIterable = isntIterable$1;
|
|
488
503
|
|
|
489
|
-
var jsonRpc = {};
|
|
504
|
+
var jsonRpc$1 = {};
|
|
490
505
|
|
|
491
|
-
var object = {};
|
|
506
|
+
var object$1 = {};
|
|
492
507
|
|
|
493
|
-
object.isntEmptyObject = object.isEmptyObject = object.isRecord = object.isntObject = object.isObject = void 0;
|
|
494
|
-
function isObject(val) {
|
|
508
|
+
object$1.isntEmptyObject = object$1.isEmptyObject = object$1.isRecord = object$1.isntObject = object$1.isObject = void 0;
|
|
509
|
+
function isObject$1(val) {
|
|
495
510
|
return val !== null && typeof val === 'object';
|
|
496
511
|
}
|
|
497
|
-
object.isObject = isObject;
|
|
498
|
-
function isntObject(val) {
|
|
499
|
-
return !isObject(val);
|
|
512
|
+
object$1.isObject = isObject$1;
|
|
513
|
+
function isntObject$1(val) {
|
|
514
|
+
return !isObject$1(val);
|
|
500
515
|
}
|
|
501
|
-
object.isntObject = isntObject;
|
|
502
|
-
function isRecord(val) {
|
|
503
|
-
return isObject(val);
|
|
516
|
+
object$1.isntObject = isntObject$1;
|
|
517
|
+
function isRecord$1(val) {
|
|
518
|
+
return isObject$1(val);
|
|
504
519
|
}
|
|
505
|
-
object.isRecord = isRecord;
|
|
506
|
-
function isEmptyObject(val) {
|
|
520
|
+
object$1.isRecord = isRecord$1;
|
|
521
|
+
function isEmptyObject$1(val) {
|
|
507
522
|
return Object.keys(val).length === 0;
|
|
508
523
|
}
|
|
509
|
-
object.isEmptyObject = isEmptyObject;
|
|
510
|
-
function isntEmptyObject(val) {
|
|
524
|
+
object$1.isEmptyObject = isEmptyObject$1;
|
|
525
|
+
function isntEmptyObject$1(val) {
|
|
511
526
|
return Object.keys(val).length !== 0;
|
|
512
527
|
}
|
|
513
|
-
object.isntEmptyObject = isntEmptyObject;
|
|
528
|
+
object$1.isntEmptyObject = isntEmptyObject$1;
|
|
514
529
|
|
|
515
|
-
var number = {};
|
|
530
|
+
var number$1 = {};
|
|
516
531
|
|
|
517
|
-
number.isntNumber = number.isNumber = void 0;
|
|
518
|
-
function isNumber(val) {
|
|
532
|
+
number$1.isntNumber = number$1.isNumber = void 0;
|
|
533
|
+
function isNumber$1(val) {
|
|
519
534
|
return typeof val === 'number';
|
|
520
535
|
}
|
|
521
|
-
number.isNumber = isNumber;
|
|
522
|
-
function isntNumber(val) {
|
|
523
|
-
return !isNumber(val);
|
|
524
|
-
}
|
|
525
|
-
number.isntNumber = isntNumber;
|
|
526
|
-
|
|
527
|
-
jsonRpc.isntJsonRpcError = jsonRpc.isJsonRpcError = jsonRpc.isntJsonRpcSuccess = jsonRpc.isJsonRpcSuccess = jsonRpc.isntJsonRpcRequest = jsonRpc.isJsonRpcRequest = jsonRpc.isntJsonRpcNotification = jsonRpc.isJsonRpcNotification = void 0;
|
|
528
|
-
const array_1 = array;
|
|
529
|
-
const object_1 = object;
|
|
530
|
-
const string_1 = string;
|
|
531
|
-
const number_1 = number;
|
|
532
|
-
const undefined_1 = _undefined;
|
|
533
|
-
function isJsonRpcId(val) {
|
|
534
|
-
return (0, string_1.isString)(val) || (0, number_1.isNumber)(val);
|
|
535
|
-
}
|
|
536
|
-
function isJsonRpcParams(val) {
|
|
537
|
-
return (0, array_1.isArray)(val) || (0, object_1.isObject)(val);
|
|
538
|
-
}
|
|
539
|
-
function isJsonRpcNotification(val) {
|
|
540
|
-
return (0, object_1.isRecord)(val)
|
|
541
|
-
&& (0, string_1.isString)(val.jsonrpc)
|
|
542
|
-
&& (0, string_1.isString)(val.method)
|
|
543
|
-
&& (0, undefined_1.isUndefined)(val.id)
|
|
544
|
-
&& isJsonRpcParams(val.params);
|
|
545
|
-
}
|
|
546
|
-
jsonRpc.isJsonRpcNotification = isJsonRpcNotification;
|
|
547
|
-
function isntJsonRpcNotification(val) {
|
|
548
|
-
return !isJsonRpcNotification(val);
|
|
549
|
-
}
|
|
550
|
-
jsonRpc.isntJsonRpcNotification = isntJsonRpcNotification;
|
|
551
|
-
function isJsonRpcRequest(val) {
|
|
552
|
-
return (0, object_1.isRecord)(val)
|
|
553
|
-
&& (0, string_1.isString)(val.jsonrpc)
|
|
554
|
-
&& (0, string_1.isString)(val.method)
|
|
555
|
-
&& isJsonRpcId(val.id)
|
|
556
|
-
&& isJsonRpcParams(val.params);
|
|
557
|
-
}
|
|
558
|
-
jsonRpc.isJsonRpcRequest = isJsonRpcRequest;
|
|
559
|
-
function isntJsonRpcRequest(val) {
|
|
560
|
-
return !isJsonRpcRequest(val);
|
|
561
|
-
}
|
|
562
|
-
jsonRpc.isntJsonRpcRequest = isntJsonRpcRequest;
|
|
563
|
-
function isJsonRpcSuccess(val) {
|
|
564
|
-
return (0, object_1.isRecord)(val)
|
|
565
|
-
&& (0, string_1.isString)(val.jsonrpc)
|
|
566
|
-
&& (0, string_1.isString)(val.id)
|
|
567
|
-
&& (0, undefined_1.isntUndefined)(val.result);
|
|
568
|
-
}
|
|
569
|
-
jsonRpc.isJsonRpcSuccess = isJsonRpcSuccess;
|
|
570
|
-
function isntJsonRpcSuccess(val) {
|
|
571
|
-
return !isJsonRpcSuccess(val);
|
|
572
|
-
}
|
|
573
|
-
jsonRpc.isntJsonRpcSuccess = isntJsonRpcSuccess;
|
|
574
|
-
function isJsonRpcError(val) {
|
|
575
|
-
return (0, object_1.isRecord)(val)
|
|
576
|
-
&& (0, string_1.isString)(val.jsonrpc)
|
|
577
|
-
&& isJsonRpcId(val.id)
|
|
578
|
-
&& isJsonRpcErrorObject(val.error);
|
|
579
|
-
}
|
|
580
|
-
jsonRpc.isJsonRpcError = isJsonRpcError;
|
|
581
|
-
function isntJsonRpcError(val) {
|
|
582
|
-
return !isJsonRpcError(val);
|
|
583
|
-
}
|
|
584
|
-
jsonRpc.isntJsonRpcError = isntJsonRpcError;
|
|
585
|
-
function isJsonRpcErrorObject(val) {
|
|
586
|
-
return (0, object_1.isRecord)(val)
|
|
587
|
-
&& (0, number_1.isNumber)(val.code)
|
|
588
|
-
&& (0, string_1.isString)(val.message)
|
|
589
|
-
&& ((0, undefined_1.isUndefined)(val.data) || (0, object_1.isObject)(val.data));
|
|
590
|
-
}
|
|
591
|
-
|
|
592
|
-
var json = {};
|
|
593
|
-
|
|
594
|
-
json.isntJson = json.isJson = void 0;
|
|
595
|
-
function isJson(val) {
|
|
536
|
+
number$1.isNumber = isNumber$1;
|
|
537
|
+
function isntNumber$1(val) {
|
|
538
|
+
return !isNumber$1(val);
|
|
539
|
+
}
|
|
540
|
+
number$1.isntNumber = isntNumber$1;
|
|
541
|
+
|
|
542
|
+
jsonRpc$1.isntJsonRpcError = jsonRpc$1.isJsonRpcError = jsonRpc$1.isntJsonRpcSuccess = jsonRpc$1.isJsonRpcSuccess = jsonRpc$1.isntJsonRpcRequest = jsonRpc$1.isJsonRpcRequest = jsonRpc$1.isntJsonRpcNotification = jsonRpc$1.isJsonRpcNotification = void 0;
|
|
543
|
+
const array_1$1 = array$1;
|
|
544
|
+
const object_1$1 = object$1;
|
|
545
|
+
const string_1$2 = string$1;
|
|
546
|
+
const number_1$1 = number$1;
|
|
547
|
+
const undefined_1$3 = _undefined$1;
|
|
548
|
+
function isJsonRpcId$1(val) {
|
|
549
|
+
return (0, string_1$2.isString)(val) || (0, number_1$1.isNumber)(val);
|
|
550
|
+
}
|
|
551
|
+
function isJsonRpcParams$1(val) {
|
|
552
|
+
return (0, array_1$1.isArray)(val) || (0, object_1$1.isObject)(val);
|
|
553
|
+
}
|
|
554
|
+
function isJsonRpcNotification$1(val) {
|
|
555
|
+
return (0, object_1$1.isRecord)(val)
|
|
556
|
+
&& (0, string_1$2.isString)(val.jsonrpc)
|
|
557
|
+
&& (0, string_1$2.isString)(val.method)
|
|
558
|
+
&& (0, undefined_1$3.isUndefined)(val.id)
|
|
559
|
+
&& isJsonRpcParams$1(val.params);
|
|
560
|
+
}
|
|
561
|
+
jsonRpc$1.isJsonRpcNotification = isJsonRpcNotification$1;
|
|
562
|
+
function isntJsonRpcNotification$1(val) {
|
|
563
|
+
return !isJsonRpcNotification$1(val);
|
|
564
|
+
}
|
|
565
|
+
jsonRpc$1.isntJsonRpcNotification = isntJsonRpcNotification$1;
|
|
566
|
+
function isJsonRpcRequest$1(val) {
|
|
567
|
+
return (0, object_1$1.isRecord)(val)
|
|
568
|
+
&& (0, string_1$2.isString)(val.jsonrpc)
|
|
569
|
+
&& (0, string_1$2.isString)(val.method)
|
|
570
|
+
&& isJsonRpcId$1(val.id)
|
|
571
|
+
&& isJsonRpcParams$1(val.params);
|
|
572
|
+
}
|
|
573
|
+
jsonRpc$1.isJsonRpcRequest = isJsonRpcRequest$1;
|
|
574
|
+
function isntJsonRpcRequest$1(val) {
|
|
575
|
+
return !isJsonRpcRequest$1(val);
|
|
576
|
+
}
|
|
577
|
+
jsonRpc$1.isntJsonRpcRequest = isntJsonRpcRequest$1;
|
|
578
|
+
function isJsonRpcSuccess$1(val) {
|
|
579
|
+
return (0, object_1$1.isRecord)(val)
|
|
580
|
+
&& (0, string_1$2.isString)(val.jsonrpc)
|
|
581
|
+
&& (0, string_1$2.isString)(val.id)
|
|
582
|
+
&& (0, undefined_1$3.isntUndefined)(val.result);
|
|
583
|
+
}
|
|
584
|
+
jsonRpc$1.isJsonRpcSuccess = isJsonRpcSuccess$1;
|
|
585
|
+
function isntJsonRpcSuccess$1(val) {
|
|
586
|
+
return !isJsonRpcSuccess$1(val);
|
|
587
|
+
}
|
|
588
|
+
jsonRpc$1.isntJsonRpcSuccess = isntJsonRpcSuccess$1;
|
|
589
|
+
function isJsonRpcError$1(val) {
|
|
590
|
+
return (0, object_1$1.isRecord)(val)
|
|
591
|
+
&& (0, string_1$2.isString)(val.jsonrpc)
|
|
592
|
+
&& isJsonRpcId$1(val.id)
|
|
593
|
+
&& isJsonRpcErrorObject$1(val.error);
|
|
594
|
+
}
|
|
595
|
+
jsonRpc$1.isJsonRpcError = isJsonRpcError$1;
|
|
596
|
+
function isntJsonRpcError$1(val) {
|
|
597
|
+
return !isJsonRpcError$1(val);
|
|
598
|
+
}
|
|
599
|
+
jsonRpc$1.isntJsonRpcError = isntJsonRpcError$1;
|
|
600
|
+
function isJsonRpcErrorObject$1(val) {
|
|
601
|
+
return (0, object_1$1.isRecord)(val)
|
|
602
|
+
&& (0, number_1$1.isNumber)(val.code)
|
|
603
|
+
&& (0, string_1$2.isString)(val.message)
|
|
604
|
+
&& ((0, undefined_1$3.isUndefined)(val.data) || (0, object_1$1.isObject)(val.data));
|
|
605
|
+
}
|
|
606
|
+
|
|
607
|
+
var json$1 = {};
|
|
608
|
+
|
|
609
|
+
json$1.isntJson = json$1.isJson = void 0;
|
|
610
|
+
function isJson$1(val) {
|
|
596
611
|
try {
|
|
597
612
|
JSON.stringify(val);
|
|
598
613
|
return true;
|
|
@@ -601,16 +616,16 @@
|
|
|
601
616
|
return false;
|
|
602
617
|
}
|
|
603
618
|
}
|
|
604
|
-
json.isJson = isJson;
|
|
605
|
-
function isntJson(val) {
|
|
606
|
-
return !isntJson();
|
|
619
|
+
json$1.isJson = isJson$1;
|
|
620
|
+
function isntJson$1(val) {
|
|
621
|
+
return !isntJson$1();
|
|
607
622
|
}
|
|
608
|
-
json.isntJson = isntJson;
|
|
623
|
+
json$1.isntJson = isntJson$1;
|
|
609
624
|
|
|
610
|
-
var url = {};
|
|
625
|
+
var url$1 = {};
|
|
611
626
|
|
|
612
|
-
url.isAbsoluteURL = void 0;
|
|
613
|
-
function isAbsoluteURL(str) {
|
|
627
|
+
url$1.isAbsoluteURL = void 0;
|
|
628
|
+
function isAbsoluteURL$1(str) {
|
|
614
629
|
try {
|
|
615
630
|
new URL(str);
|
|
616
631
|
return true;
|
|
@@ -619,7 +634,7 @@
|
|
|
619
634
|
return false;
|
|
620
635
|
}
|
|
621
636
|
}
|
|
622
|
-
url.isAbsoluteURL = isAbsoluteURL;
|
|
637
|
+
url$1.isAbsoluteURL = isAbsoluteURL$1;
|
|
623
638
|
|
|
624
639
|
(function (exports) {
|
|
625
640
|
var __createBinding = (commonjsGlobal && commonjsGlobal.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
@@ -631,30 +646,30 @@
|
|
|
631
646
|
}));
|
|
632
647
|
var __exportStar = (commonjsGlobal && commonjsGlobal.__exportStar) || function(m, exports) {
|
|
633
648
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
634
|
-
};__exportStar(array, exports);
|
|
635
|
-
__exportStar(asyncIterable, exports);
|
|
636
|
-
__exportStar(bigint, exports);
|
|
637
|
-
__exportStar(boolean, exports);
|
|
638
|
-
__exportStar(char, exports);
|
|
639
|
-
__exportStar(date, exports);
|
|
640
|
-
__exportStar(_enum, exports);
|
|
641
|
-
__exportStar(error, exports);
|
|
642
|
-
__exportStar(falsy, exports);
|
|
643
|
-
__exportStar(_function, exports);
|
|
644
|
-
__exportStar(iterable, exports);
|
|
645
|
-
__exportStar(jsonRpc, exports);
|
|
646
|
-
__exportStar(json, exports);
|
|
647
|
-
__exportStar(_null, exports);
|
|
648
|
-
__exportStar(number, exports);
|
|
649
|
-
__exportStar(object, exports);
|
|
650
|
-
__exportStar(string, exports);
|
|
651
|
-
__exportStar(_undefined, exports);
|
|
652
|
-
__exportStar(url, exports);
|
|
649
|
+
};__exportStar(array$1, exports);
|
|
650
|
+
__exportStar(asyncIterable$1, exports);
|
|
651
|
+
__exportStar(bigint$1, exports);
|
|
652
|
+
__exportStar(boolean$1, exports);
|
|
653
|
+
__exportStar(char$1, exports);
|
|
654
|
+
__exportStar(date$1, exports);
|
|
655
|
+
__exportStar(_enum$1, exports);
|
|
656
|
+
__exportStar(error$1, exports);
|
|
657
|
+
__exportStar(falsy$1, exports);
|
|
658
|
+
__exportStar(_function$1, exports);
|
|
659
|
+
__exportStar(iterable$1, exports);
|
|
660
|
+
__exportStar(jsonRpc$1, exports);
|
|
661
|
+
__exportStar(json$1, exports);
|
|
662
|
+
__exportStar(_null$1, exports);
|
|
663
|
+
__exportStar(number$1, exports);
|
|
664
|
+
__exportStar(object$1, exports);
|
|
665
|
+
__exportStar(string$1, exports);
|
|
666
|
+
__exportStar(_undefined$1, exports);
|
|
667
|
+
__exportStar(url$1, exports);
|
|
653
668
|
|
|
654
|
-
}(es2018$
|
|
669
|
+
}(es2018$3));
|
|
655
670
|
|
|
656
671
|
chunkByAsync$1.chunkByAsync = void 0;
|
|
657
|
-
const types_1$h = es2018$
|
|
672
|
+
const types_1$h = es2018$3;
|
|
658
673
|
function chunkByAsync(iterable, predicate) {
|
|
659
674
|
if ((0, types_1$h.isAsyncIterable)(iterable)) {
|
|
660
675
|
return chunkByAsyncIterable(iterable);
|
|
@@ -715,8 +730,8 @@
|
|
|
715
730
|
var chunk$1 = {};
|
|
716
731
|
|
|
717
732
|
chunk$1.chunk = void 0;
|
|
718
|
-
const go_1$e = es2018$
|
|
719
|
-
const errors_1$e = es2018$
|
|
733
|
+
const go_1$e = es2018$4;
|
|
734
|
+
const errors_1$e = es2018$6;
|
|
720
735
|
function chunk(iterable, size) {
|
|
721
736
|
(0, errors_1$e.assert)(Number.isInteger(size), 'The parameter size must be an integer');
|
|
722
737
|
(0, errors_1$e.assert)(size > 0, 'The parameter size must be greater than 0');
|
|
@@ -738,8 +753,8 @@
|
|
|
738
753
|
var concatAsync$1 = {};
|
|
739
754
|
|
|
740
755
|
concatAsync$1.concatAsync = void 0;
|
|
741
|
-
const types_1$g = es2018$
|
|
742
|
-
const go_1$d = es2018$
|
|
756
|
+
const types_1$g = es2018$3;
|
|
757
|
+
const go_1$d = es2018$4;
|
|
743
758
|
function concatAsync(iterable, ...otherIterables) {
|
|
744
759
|
return (0, go_1$d.go)(async function* () {
|
|
745
760
|
for (const iter of [iterable, ...otherIterables]) {
|
|
@@ -761,7 +776,7 @@
|
|
|
761
776
|
var concat$1 = {};
|
|
762
777
|
|
|
763
778
|
concat$1.concat = void 0;
|
|
764
|
-
const go_1$c = es2018$
|
|
779
|
+
const go_1$c = es2018$4;
|
|
765
780
|
function concat(iterable, ...otherIterables) {
|
|
766
781
|
return (0, go_1$c.go)(function* () {
|
|
767
782
|
for (const iter of [iterable, ...otherIterables]) {
|
|
@@ -790,9 +805,9 @@
|
|
|
790
805
|
utils.copyIterable = copyIterable;
|
|
791
806
|
|
|
792
807
|
dropAsync$1.dropAsync = void 0;
|
|
793
|
-
const go_1$b = es2018$
|
|
808
|
+
const go_1$b = es2018$4;
|
|
794
809
|
const utils_1$3 = utils;
|
|
795
|
-
const errors_1$d = es2018$
|
|
810
|
+
const errors_1$d = es2018$6;
|
|
796
811
|
function dropAsync(iterable, count) {
|
|
797
812
|
(0, errors_1$d.assert)(Number.isInteger(count), 'The parameter count must be an integer');
|
|
798
813
|
(0, errors_1$d.assert)(count >= 0, 'The parameter count must be greater than or equal to 0');
|
|
@@ -825,9 +840,9 @@
|
|
|
825
840
|
var dropRightAsync$1 = {};
|
|
826
841
|
|
|
827
842
|
dropRightAsync$1.dropRightAsync = void 0;
|
|
828
|
-
const go_1$a = es2018$
|
|
843
|
+
const go_1$a = es2018$4;
|
|
829
844
|
const utils_1$2 = utils;
|
|
830
|
-
const errors_1$c = es2018$
|
|
845
|
+
const errors_1$c = es2018$6;
|
|
831
846
|
function dropRightAsync(iterable, count) {
|
|
832
847
|
(0, errors_1$c.assert)(Number.isInteger(count), 'The parameter count must be an integer');
|
|
833
848
|
(0, errors_1$c.assert)(count >= 0, 'The parameter count must be greater than or equal to 0');
|
|
@@ -853,9 +868,9 @@
|
|
|
853
868
|
var dropRight$1 = {};
|
|
854
869
|
|
|
855
870
|
dropRight$1.dropRight = void 0;
|
|
856
|
-
const go_1$9 = es2018$
|
|
871
|
+
const go_1$9 = es2018$4;
|
|
857
872
|
const utils_1$1 = utils;
|
|
858
|
-
const errors_1$b = es2018$
|
|
873
|
+
const errors_1$b = es2018$6;
|
|
859
874
|
function dropRight(iterable, count) {
|
|
860
875
|
(0, errors_1$b.assert)(Number.isInteger(count), 'The parameter count must be an integer');
|
|
861
876
|
(0, errors_1$b.assert)(count >= 0, 'The parameter count must be greater than or equal to 0');
|
|
@@ -871,7 +886,7 @@
|
|
|
871
886
|
var dropUntilAsync$1 = {};
|
|
872
887
|
|
|
873
888
|
dropUntilAsync$1.dropUntilAsync = void 0;
|
|
874
|
-
const types_1$f = es2018$
|
|
889
|
+
const types_1$f = es2018$3;
|
|
875
890
|
function dropUntilAsync(iterable, predicate) {
|
|
876
891
|
if ((0, types_1$f.isAsyncIterable)(iterable)) {
|
|
877
892
|
return dropUntilAsyncIterable(iterable);
|
|
@@ -953,9 +968,9 @@
|
|
|
953
968
|
var drop$1 = {};
|
|
954
969
|
|
|
955
970
|
drop$1.drop = void 0;
|
|
956
|
-
const go_1$8 = es2018$
|
|
971
|
+
const go_1$8 = es2018$4;
|
|
957
972
|
const utils_1 = utils;
|
|
958
|
-
const errors_1$a = es2018$
|
|
973
|
+
const errors_1$a = es2018$6;
|
|
959
974
|
function drop(iterable, count) {
|
|
960
975
|
(0, errors_1$a.assert)(Number.isInteger(count), 'The parameter count must be an integer');
|
|
961
976
|
(0, errors_1$a.assert)(count >= 0, 'The parameter count must be greater than or equal to 0');
|
|
@@ -988,7 +1003,7 @@
|
|
|
988
1003
|
var filterAsync$1 = {};
|
|
989
1004
|
|
|
990
1005
|
filterAsync$1.filterAsync = void 0;
|
|
991
|
-
const types_1$e = es2018$
|
|
1006
|
+
const types_1$e = es2018$3;
|
|
992
1007
|
function filterAsync(iterable, predicate) {
|
|
993
1008
|
if ((0, types_1$e.isAsyncIterable)(iterable)) {
|
|
994
1009
|
return filterAsyncIterable(iterable);
|
|
@@ -1035,7 +1050,7 @@
|
|
|
1035
1050
|
var flattenByAsync$1 = {};
|
|
1036
1051
|
|
|
1037
1052
|
flattenByAsync$1.flattenByAsync = void 0;
|
|
1038
|
-
const types_1$d = es2018$
|
|
1053
|
+
const types_1$d = es2018$3;
|
|
1039
1054
|
function flattenByAsync(iterable, predicate) {
|
|
1040
1055
|
if ((0, types_1$d.isAsyncIterable)(iterable)) {
|
|
1041
1056
|
return flattenByAsyncIterable(iterable);
|
|
@@ -1075,7 +1090,7 @@
|
|
|
1075
1090
|
|
|
1076
1091
|
flattenDeepAsync$1.flattenDeepAsync = void 0;
|
|
1077
1092
|
const flatten_by_async_1 = flattenByAsync$1;
|
|
1078
|
-
const errors_1$9 = es2018$
|
|
1093
|
+
const errors_1$9 = es2018$6;
|
|
1079
1094
|
function flattenDeepAsync(iterable, depth = Infinity) {
|
|
1080
1095
|
(0, errors_1$9.assert)(depth === Infinity || Number.isInteger(depth), 'The parameter depth must be an integer');
|
|
1081
1096
|
(0, errors_1$9.assert)(depth >= 0, 'The parameter depth must be greater than or equal to 0');
|
|
@@ -1093,7 +1108,7 @@
|
|
|
1093
1108
|
var flattenBy$1 = {};
|
|
1094
1109
|
|
|
1095
1110
|
flattenBy$1.flattenBy = void 0;
|
|
1096
|
-
const types_1$c = es2018$
|
|
1111
|
+
const types_1$c = es2018$3;
|
|
1097
1112
|
function flattenBy(iterable, predicate) {
|
|
1098
1113
|
return flatten(iterable, 1);
|
|
1099
1114
|
function* flatten(iterable, level) {
|
|
@@ -1116,7 +1131,7 @@
|
|
|
1116
1131
|
|
|
1117
1132
|
flattenDeep$1.flattenDeep = void 0;
|
|
1118
1133
|
const flatten_by_1 = flattenBy$1;
|
|
1119
|
-
const errors_1$8 = es2018$
|
|
1134
|
+
const errors_1$8 = es2018$6;
|
|
1120
1135
|
function flattenDeep(iterable, depth = Infinity) {
|
|
1121
1136
|
(0, errors_1$8.assert)(depth === Infinity || Number.isInteger(depth), 'The parameter depth must be an integer');
|
|
1122
1137
|
(0, errors_1$8.assert)(depth >= 0, 'The parameter depth must be greater than or equal to 0');
|
|
@@ -1136,7 +1151,7 @@
|
|
|
1136
1151
|
var mapAsync$1 = {};
|
|
1137
1152
|
|
|
1138
1153
|
mapAsync$1.mapAsync = void 0;
|
|
1139
|
-
const types_1$b = es2018$
|
|
1154
|
+
const types_1$b = es2018$3;
|
|
1140
1155
|
function mapAsync(iterable, fn) {
|
|
1141
1156
|
if ((0, types_1$b.isAsyncIterable)(iterable)) {
|
|
1142
1157
|
return mapAsyncIterable(iterable);
|
|
@@ -1176,8 +1191,8 @@
|
|
|
1176
1191
|
var repeatAsync$1 = {};
|
|
1177
1192
|
|
|
1178
1193
|
repeatAsync$1.repeatAsync = void 0;
|
|
1179
|
-
const go_1$7 = es2018$
|
|
1180
|
-
const errors_1$7 = es2018$
|
|
1194
|
+
const go_1$7 = es2018$4;
|
|
1195
|
+
const errors_1$7 = es2018$6;
|
|
1181
1196
|
function repeatAsync(iterable, times) {
|
|
1182
1197
|
(0, errors_1$7.assert)(times === Infinity || Number.isInteger(times), 'The parameter times must be an integer');
|
|
1183
1198
|
(0, errors_1$7.assert)(times >= 0, 'The parameter times must be greater than or equal to 0');
|
|
@@ -1211,8 +1226,8 @@
|
|
|
1211
1226
|
var repeat$1 = {};
|
|
1212
1227
|
|
|
1213
1228
|
repeat$1.repeat = void 0;
|
|
1214
|
-
const go_1$6 = es2018$
|
|
1215
|
-
const errors_1$6 = es2018$
|
|
1229
|
+
const go_1$6 = es2018$4;
|
|
1230
|
+
const errors_1$6 = es2018$6;
|
|
1216
1231
|
function repeat(iterable, times) {
|
|
1217
1232
|
(0, errors_1$6.assert)(times === Infinity || Number.isInteger(times), 'The parameter times must be an integer');
|
|
1218
1233
|
(0, errors_1$6.assert)(times >= 0, 'The parameter times must be greater than or equal to 0');
|
|
@@ -1246,8 +1261,8 @@
|
|
|
1246
1261
|
var sliceAsync$1 = {};
|
|
1247
1262
|
|
|
1248
1263
|
sliceAsync$1.sliceAsync = void 0;
|
|
1249
|
-
const go_1$5 = es2018$
|
|
1250
|
-
const errors_1$5 = es2018$
|
|
1264
|
+
const go_1$5 = es2018$4;
|
|
1265
|
+
const errors_1$5 = es2018$6;
|
|
1251
1266
|
function sliceAsync(iterable, start, end = Infinity) {
|
|
1252
1267
|
(0, errors_1$5.assert)(Number.isInteger(start), 'The parameter start must be an integer');
|
|
1253
1268
|
(0, errors_1$5.assert)(start >= 0, 'The parameter start must be greater than or equal to 0');
|
|
@@ -1269,8 +1284,8 @@
|
|
|
1269
1284
|
var slice$1 = {};
|
|
1270
1285
|
|
|
1271
1286
|
slice$1.slice = void 0;
|
|
1272
|
-
const go_1$4 = es2018$
|
|
1273
|
-
const errors_1$4 = es2018$
|
|
1287
|
+
const go_1$4 = es2018$4;
|
|
1288
|
+
const errors_1$4 = es2018$6;
|
|
1274
1289
|
function slice(iterable, start, end = Infinity) {
|
|
1275
1290
|
(0, errors_1$4.assert)(Number.isInteger(start), 'The parameter start must be an integer');
|
|
1276
1291
|
(0, errors_1$4.assert)(start >= 0, 'The parameter start must be greater than or equal to 0');
|
|
@@ -1310,7 +1325,7 @@
|
|
|
1310
1325
|
var splitByAsync$1 = {};
|
|
1311
1326
|
|
|
1312
1327
|
splitByAsync$1.splitByAsync = void 0;
|
|
1313
|
-
const types_1$a = es2018$
|
|
1328
|
+
const types_1$a = es2018$3;
|
|
1314
1329
|
function splitByAsync(iterable, predicate) {
|
|
1315
1330
|
if ((0, types_1$a.isAsyncIterable)(iterable)) {
|
|
1316
1331
|
return splitByAsyncIterable(iterable);
|
|
@@ -1392,8 +1407,8 @@
|
|
|
1392
1407
|
var takeAsync$1 = {};
|
|
1393
1408
|
|
|
1394
1409
|
takeAsync$1.takeAsync = void 0;
|
|
1395
|
-
const go_1$3 = es2018$
|
|
1396
|
-
const errors_1$3 = es2018$
|
|
1410
|
+
const go_1$3 = es2018$4;
|
|
1411
|
+
const errors_1$3 = es2018$6;
|
|
1397
1412
|
function takeAsync(iterable, count) {
|
|
1398
1413
|
(0, errors_1$3.assert)(Number.isInteger(count), 'The parameter count must be an integer');
|
|
1399
1414
|
(0, errors_1$3.assert)(count >= 0, 'The parameter count must be greater than or equal to 0');
|
|
@@ -1413,8 +1428,8 @@
|
|
|
1413
1428
|
var takeRightAsync$1 = {};
|
|
1414
1429
|
|
|
1415
1430
|
takeRightAsync$1.takeRightAsync = void 0;
|
|
1416
|
-
const go_1$2 = es2018$
|
|
1417
|
-
const errors_1$2 = es2018$
|
|
1431
|
+
const go_1$2 = es2018$4;
|
|
1432
|
+
const errors_1$2 = es2018$6;
|
|
1418
1433
|
function takeRightAsync(iterable, count) {
|
|
1419
1434
|
(0, errors_1$2.assert)(Number.isInteger(count), 'The parameter count must be an integer');
|
|
1420
1435
|
(0, errors_1$2.assert)(count >= 0, 'The parameter count must be greater than or equal to 0');
|
|
@@ -1443,8 +1458,8 @@
|
|
|
1443
1458
|
var takeRight$1 = {};
|
|
1444
1459
|
|
|
1445
1460
|
takeRight$1.takeRight = void 0;
|
|
1446
|
-
const go_1$1 = es2018$
|
|
1447
|
-
const errors_1$1 = es2018$
|
|
1461
|
+
const go_1$1 = es2018$4;
|
|
1462
|
+
const errors_1$1 = es2018$6;
|
|
1448
1463
|
function takeRight(iterable, count) {
|
|
1449
1464
|
(0, errors_1$1.assert)(Number.isInteger(count), 'The parameter count must be an integer');
|
|
1450
1465
|
(0, errors_1$1.assert)(count >= 0, 'The parameter count must be greater than or equal to 0');
|
|
@@ -1473,7 +1488,7 @@
|
|
|
1473
1488
|
var takeUntilAsync$1 = {};
|
|
1474
1489
|
|
|
1475
1490
|
takeUntilAsync$1.takeUntilAsync = void 0;
|
|
1476
|
-
const types_1$9 = es2018$
|
|
1491
|
+
const types_1$9 = es2018$3;
|
|
1477
1492
|
function takeUntilAsync(iterable, predicate) {
|
|
1478
1493
|
if ((0, types_1$9.isAsyncIterable)(iterable)) {
|
|
1479
1494
|
return takeUntilAsyncIterable(iterable);
|
|
@@ -1519,8 +1534,8 @@
|
|
|
1519
1534
|
var take$1 = {};
|
|
1520
1535
|
|
|
1521
1536
|
take$1.take = void 0;
|
|
1522
|
-
const go_1 = es2018$
|
|
1523
|
-
const errors_1 = es2018$
|
|
1537
|
+
const go_1 = es2018$4;
|
|
1538
|
+
const errors_1 = es2018$6;
|
|
1524
1539
|
function take(iterable, count) {
|
|
1525
1540
|
(0, errors_1.assert)(Number.isInteger(count), 'The parameter count must be an integer');
|
|
1526
1541
|
(0, errors_1.assert)(count >= 0, 'The parameter count must be greater than or equal to 0');
|
|
@@ -1540,7 +1555,7 @@
|
|
|
1540
1555
|
var tapAsync$1 = {};
|
|
1541
1556
|
|
|
1542
1557
|
tapAsync$1.tapAsync = void 0;
|
|
1543
|
-
const types_1$8 = es2018$
|
|
1558
|
+
const types_1$8 = es2018$3;
|
|
1544
1559
|
function tapAsync(iterable, fn) {
|
|
1545
1560
|
if ((0, types_1$8.isAsyncIterable)(iterable)) {
|
|
1546
1561
|
return tapAsyncIterable(iterable);
|
|
@@ -1623,7 +1638,7 @@
|
|
|
1623
1638
|
var uniqByAsync$1 = {};
|
|
1624
1639
|
|
|
1625
1640
|
uniqByAsync$1.uniqByAsync = void 0;
|
|
1626
|
-
const types_1$7 = es2018$
|
|
1641
|
+
const types_1$7 = es2018$3;
|
|
1627
1642
|
function uniqByAsync(iterable, fn) {
|
|
1628
1643
|
if ((0, types_1$7.isAsyncIterable)(iterable)) {
|
|
1629
1644
|
return uniqByAsyncIterable(iterable);
|
|
@@ -1692,7 +1707,7 @@
|
|
|
1692
1707
|
var zipAsync$1 = {};
|
|
1693
1708
|
|
|
1694
1709
|
zipAsync$1.zipAsync = void 0;
|
|
1695
|
-
const types_1$6 = es2018$
|
|
1710
|
+
const types_1$6 = es2018$3;
|
|
1696
1711
|
var Kind;
|
|
1697
1712
|
(function (Kind) {
|
|
1698
1713
|
Kind[Kind["Sync"] = 0] = "Sync";
|
|
@@ -1852,7 +1867,7 @@
|
|
|
1852
1867
|
var eachAsync$1 = {};
|
|
1853
1868
|
|
|
1854
1869
|
eachAsync$1.eachAsync = void 0;
|
|
1855
|
-
const types_1$5 = es2018$
|
|
1870
|
+
const types_1$5 = es2018$3;
|
|
1856
1871
|
function eachAsync(iterable, fn) {
|
|
1857
1872
|
if ((0, types_1$5.isAsyncIterable)(iterable)) {
|
|
1858
1873
|
return eachAsyncIterable(iterable);
|
|
@@ -1892,7 +1907,7 @@
|
|
|
1892
1907
|
var everyAsync$1 = {};
|
|
1893
1908
|
|
|
1894
1909
|
everyAsync$1.everyAsync = void 0;
|
|
1895
|
-
const types_1$4 = es2018$
|
|
1910
|
+
const types_1$4 = es2018$3;
|
|
1896
1911
|
function everyAsync(iterable, predicate) {
|
|
1897
1912
|
if ((0, types_1$4.isAsyncIterable)(iterable)) {
|
|
1898
1913
|
return everyAsyncIterable(iterable);
|
|
@@ -1938,7 +1953,7 @@
|
|
|
1938
1953
|
var findAsync$1 = {};
|
|
1939
1954
|
|
|
1940
1955
|
findAsync$1.findAsync = void 0;
|
|
1941
|
-
const types_1$3 = es2018$
|
|
1956
|
+
const types_1$3 = es2018$3;
|
|
1942
1957
|
function findAsync(iterable, predicate) {
|
|
1943
1958
|
if ((0, types_1$3.isAsyncIterable)(iterable)) {
|
|
1944
1959
|
return findAsyncIterable(iterable);
|
|
@@ -2062,7 +2077,7 @@
|
|
|
2062
2077
|
var reduceAsync$1 = {};
|
|
2063
2078
|
|
|
2064
2079
|
reduceAsync$1.reduceAsync = void 0;
|
|
2065
|
-
const types_1$2 = es2018$
|
|
2080
|
+
const types_1$2 = es2018$3;
|
|
2066
2081
|
function reduceAsync(iterable, fn, initialValue) {
|
|
2067
2082
|
if ((0, types_1$2.isUndefined)(initialValue)) {
|
|
2068
2083
|
return reduceAsyncWithoutInitialValue(iterable, fn);
|
|
@@ -2158,7 +2173,7 @@
|
|
|
2158
2173
|
var reduce$1 = {};
|
|
2159
2174
|
|
|
2160
2175
|
reduce$1.reduce = void 0;
|
|
2161
|
-
const types_1$1 = es2018$
|
|
2176
|
+
const types_1$1 = es2018$3;
|
|
2162
2177
|
function reduce(iterable, fn, initialValue) {
|
|
2163
2178
|
if ((0, types_1$1.isUndefined)(initialValue)) {
|
|
2164
2179
|
return reduceWithoutInitialValue(iterable, fn);
|
|
@@ -2205,7 +2220,7 @@
|
|
|
2205
2220
|
var someAsync$1 = {};
|
|
2206
2221
|
|
|
2207
2222
|
someAsync$1.someAsync = void 0;
|
|
2208
|
-
const types_1 = es2018$
|
|
2223
|
+
const types_1 = es2018$3;
|
|
2209
2224
|
function someAsync(iterable, predicate) {
|
|
2210
2225
|
if ((0, types_1.isAsyncIterable)(iterable)) {
|
|
2211
2226
|
return someAsyncIterable(iterable);
|
|
@@ -2389,15 +2404,15 @@
|
|
|
2389
2404
|
};__exportStar(middleware, exports);
|
|
2390
2405
|
__exportStar(output, exports);
|
|
2391
2406
|
|
|
2392
|
-
}(es2018$
|
|
2407
|
+
}(es2018$5));
|
|
2393
2408
|
|
|
2394
2409
|
var _LRUMap_limit, _LRUMap_map;
|
|
2395
2410
|
class LRUMap {
|
|
2396
2411
|
constructor(limit) {
|
|
2397
2412
|
_LRUMap_limit.set(this, void 0);
|
|
2398
2413
|
_LRUMap_map.set(this, new Map());
|
|
2399
|
-
es2018$
|
|
2400
|
-
es2018$
|
|
2414
|
+
es2018$6.assert(Number.isInteger(limit), 'The parameter limit must be an integer');
|
|
2415
|
+
es2018$6.assert(limit > 0, 'The parameter limit must be a positive value');
|
|
2401
2416
|
__classPrivateFieldSet(this, _LRUMap_limit, limit, "f");
|
|
2402
2417
|
}
|
|
2403
2418
|
get [(_LRUMap_limit = new WeakMap(), _LRUMap_map = new WeakMap(), Symbol.toStringTag)]() {
|
|
@@ -2445,25 +2460,86 @@
|
|
|
2445
2460
|
* Return the earliest key inserted in the Map
|
|
2446
2461
|
*/
|
|
2447
2462
|
getColdestKey() {
|
|
2448
|
-
return es2018$
|
|
2463
|
+
return es2018$5.first(__classPrivateFieldGet(this, _LRUMap_map, "f").keys());
|
|
2449
2464
|
}
|
|
2450
2465
|
}
|
|
2451
2466
|
|
|
2452
|
-
var es2018 = {};
|
|
2467
|
+
var es2018$2 = {};
|
|
2468
|
+
|
|
2469
|
+
var exponentialBackoff = {};
|
|
2470
|
+
|
|
2471
|
+
var es2018$1 = {};
|
|
2472
|
+
|
|
2473
|
+
var random$1 = {};
|
|
2474
|
+
|
|
2475
|
+
random$1.random = void 0;
|
|
2476
|
+
function random(min, max) {
|
|
2477
|
+
return Math.random() * (max - min) + min;
|
|
2478
|
+
}
|
|
2479
|
+
random$1.random = random;
|
|
2480
|
+
|
|
2481
|
+
var randomInt$1 = {};
|
|
2482
|
+
|
|
2483
|
+
randomInt$1.randomInt = void 0;
|
|
2484
|
+
function randomInt(min, max) {
|
|
2485
|
+
min = Math.ceil(min);
|
|
2486
|
+
max = Math.floor(max);
|
|
2487
|
+
return Math.floor(Math.random() * (max - min)) + min;
|
|
2488
|
+
}
|
|
2489
|
+
randomInt$1.randomInt = randomInt;
|
|
2490
|
+
|
|
2491
|
+
var randomIntInclusive$1 = {};
|
|
2492
|
+
|
|
2493
|
+
randomIntInclusive$1.randomIntInclusive = void 0;
|
|
2494
|
+
function randomIntInclusive(min, max) {
|
|
2495
|
+
min = Math.ceil(min);
|
|
2496
|
+
max = Math.floor(max);
|
|
2497
|
+
return Math.floor(Math.random() * (max - min + 1)) + min;
|
|
2498
|
+
}
|
|
2499
|
+
randomIntInclusive$1.randomIntInclusive = randomIntInclusive;
|
|
2500
|
+
|
|
2501
|
+
(function (exports) {
|
|
2502
|
+
var __createBinding = (commonjsGlobal && commonjsGlobal.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
2503
|
+
if (k2 === undefined) k2 = k;
|
|
2504
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
2505
|
+
}) : (function(o, m, k, k2) {
|
|
2506
|
+
if (k2 === undefined) k2 = k;
|
|
2507
|
+
o[k2] = m[k];
|
|
2508
|
+
}));
|
|
2509
|
+
var __exportStar = (commonjsGlobal && commonjsGlobal.__exportStar) || function(m, exports) {
|
|
2510
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
2511
|
+
};__exportStar(random$1, exports);
|
|
2512
|
+
__exportStar(randomInt$1, exports);
|
|
2513
|
+
__exportStar(randomIntInclusive$1, exports);
|
|
2514
|
+
|
|
2515
|
+
}(es2018$1));
|
|
2516
|
+
|
|
2517
|
+
exponentialBackoff.calculateExponentialBackoffTimeout = void 0;
|
|
2518
|
+
const extra_rand_1 = es2018$1;
|
|
2519
|
+
function calculateExponentialBackoffTimeout({ baseTimeout, retries, maxTimeout = Infinity, factor = 2, jitter = true }) {
|
|
2520
|
+
const timeout = Math.min(factor ** retries * baseTimeout, maxTimeout);
|
|
2521
|
+
if (jitter) {
|
|
2522
|
+
return (0, extra_rand_1.randomIntInclusive)(0, timeout);
|
|
2523
|
+
}
|
|
2524
|
+
else {
|
|
2525
|
+
return timeout;
|
|
2526
|
+
}
|
|
2527
|
+
}
|
|
2528
|
+
exponentialBackoff.calculateExponentialBackoffTimeout = calculateExponentialBackoffTimeout;
|
|
2453
2529
|
|
|
2454
|
-
var setTimeout$
|
|
2530
|
+
var setTimeout$2 = {};
|
|
2455
2531
|
|
|
2456
|
-
setTimeout$
|
|
2457
|
-
function setTimeout(timeout, cb) {
|
|
2532
|
+
setTimeout$2.setTimeout = void 0;
|
|
2533
|
+
function setTimeout$1(timeout, cb) {
|
|
2458
2534
|
const timer = globalThis.setTimeout(cb, timeout);
|
|
2459
2535
|
return () => clearTimeout(timer);
|
|
2460
2536
|
}
|
|
2461
|
-
setTimeout$
|
|
2537
|
+
setTimeout$2.setTimeout = setTimeout$1;
|
|
2462
2538
|
|
|
2463
2539
|
var setSchedule$1 = {};
|
|
2464
2540
|
|
|
2465
2541
|
setSchedule$1.setSchedule = void 0;
|
|
2466
|
-
const set_timeout_1$3 = setTimeout$
|
|
2542
|
+
const set_timeout_1$3 = setTimeout$2;
|
|
2467
2543
|
function setSchedule(timestamp, cb) {
|
|
2468
2544
|
const timeout = timestamp - Date.now();
|
|
2469
2545
|
return (0, set_timeout_1$3.setTimeout)(timeout, cb);
|
|
@@ -2482,7 +2558,7 @@
|
|
|
2482
2558
|
var setImmediate$1 = {};
|
|
2483
2559
|
|
|
2484
2560
|
setImmediate$1.setImmediate = void 0;
|
|
2485
|
-
const set_timeout_1$2 = setTimeout$
|
|
2561
|
+
const set_timeout_1$2 = setTimeout$2;
|
|
2486
2562
|
function setImmediate(cb) {
|
|
2487
2563
|
if (globalThis.setImmediate) {
|
|
2488
2564
|
const timer = globalThis.setImmediate(cb);
|
|
@@ -2497,7 +2573,7 @@
|
|
|
2497
2573
|
var setTimeoutLoop$1 = {};
|
|
2498
2574
|
|
|
2499
2575
|
setTimeoutLoop$1.setTimeoutLoop = void 0;
|
|
2500
|
-
const set_timeout_1$1 = setTimeout$
|
|
2576
|
+
const set_timeout_1$1 = setTimeout$2;
|
|
2501
2577
|
function setTimeoutLoop(timeout, cb) {
|
|
2502
2578
|
let isCancelled = false;
|
|
2503
2579
|
let cancel = (0, set_timeout_1$1.setTimeout)(timeout, loop);
|
|
@@ -2507,8 +2583,9 @@
|
|
|
2507
2583
|
};
|
|
2508
2584
|
async function loop() {
|
|
2509
2585
|
await cb();
|
|
2510
|
-
if (!isCancelled)
|
|
2586
|
+
if (!isCancelled) {
|
|
2511
2587
|
cancel = (0, set_timeout_1$1.setTimeout)(timeout, loop);
|
|
2588
|
+
}
|
|
2512
2589
|
}
|
|
2513
2590
|
}
|
|
2514
2591
|
setTimeoutLoop$1.setTimeoutLoop = setTimeoutLoop;
|
|
@@ -2516,7 +2593,7 @@
|
|
|
2516
2593
|
var setDynamicTimeoutLoop$1 = {};
|
|
2517
2594
|
|
|
2518
2595
|
setDynamicTimeoutLoop$1.setDynamicTimeoutLoop = void 0;
|
|
2519
|
-
const set_timeout_1 = setTimeout$
|
|
2596
|
+
const set_timeout_1 = setTimeout$2;
|
|
2520
2597
|
function setDynamicTimeoutLoop(timeout, cb) {
|
|
2521
2598
|
let isCancelled = false;
|
|
2522
2599
|
let cancel = (0, set_timeout_1.setTimeout)(timeout, loop);
|
|
@@ -2528,8 +2605,9 @@
|
|
|
2528
2605
|
const start = Date.now();
|
|
2529
2606
|
await cb();
|
|
2530
2607
|
const elapsed = Date.now() - start;
|
|
2531
|
-
if (!isCancelled)
|
|
2608
|
+
if (!isCancelled) {
|
|
2532
2609
|
cancel = (0, set_timeout_1.setTimeout)(Math.max(timeout - elapsed, 0), loop);
|
|
2610
|
+
}
|
|
2533
2611
|
}
|
|
2534
2612
|
}
|
|
2535
2613
|
setDynamicTimeoutLoop$1.setDynamicTimeoutLoop = setDynamicTimeoutLoop;
|
|
@@ -2544,14 +2622,15 @@
|
|
|
2544
2622
|
}));
|
|
2545
2623
|
var __exportStar = (commonjsGlobal && commonjsGlobal.__exportStar) || function(m, exports) {
|
|
2546
2624
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
2547
|
-
};__exportStar(
|
|
2625
|
+
};__exportStar(exponentialBackoff, exports);
|
|
2626
|
+
__exportStar(setTimeout$2, exports);
|
|
2548
2627
|
__exportStar(setSchedule$1, exports);
|
|
2549
2628
|
__exportStar(setInterval$1, exports);
|
|
2550
2629
|
__exportStar(setImmediate$1, exports);
|
|
2551
2630
|
__exportStar(setTimeoutLoop$1, exports);
|
|
2552
2631
|
__exportStar(setDynamicTimeoutLoop$1, exports);
|
|
2553
2632
|
|
|
2554
|
-
}(es2018));
|
|
2633
|
+
}(es2018$2));
|
|
2555
2634
|
|
|
2556
2635
|
var _ExpirableMap_map, _ExpirableMap_cancelClearTimeout;
|
|
2557
2636
|
class ExpirableMap {
|
|
@@ -2641,7 +2720,7 @@
|
|
|
2641
2720
|
if (this.itemMetadataSortedByExpirationTime.length > 0) {
|
|
2642
2721
|
const item = this.itemMetadataSortedByExpirationTime[0];
|
|
2643
2722
|
if (Number.isFinite(item.expirationTime)) {
|
|
2644
|
-
const cancel = es2018.setSchedule(item.expirationTime, () => {
|
|
2723
|
+
const cancel = es2018$2.setSchedule(item.expirationTime, () => {
|
|
2645
2724
|
this.clearExpiredItems(Date.now());
|
|
2646
2725
|
this.rescheduleClearTimeout();
|
|
2647
2726
|
});
|
|
@@ -2667,8 +2746,8 @@
|
|
|
2667
2746
|
* 按过期时间升序排列所有项目的元数据
|
|
2668
2747
|
*/
|
|
2669
2748
|
this.itemMetadataSortedByExpirationTime = [];
|
|
2670
|
-
es2018$
|
|
2671
|
-
es2018$
|
|
2749
|
+
es2018$6.assert(Number.isInteger(limit), 'The parameter limit must be an integer');
|
|
2750
|
+
es2018$6.assert(limit > 0, 'The parameter limit must be a positive value');
|
|
2672
2751
|
__classPrivateFieldSet(this, _TLRUMap_limit, limit, "f");
|
|
2673
2752
|
}
|
|
2674
2753
|
get [(_TLRUMap_limit = new WeakMap(), _TLRUMap_map = new WeakMap(), _TLRUMap_cancelClearTimeout = new WeakMap(), Symbol.toStringTag)]() {
|
|
@@ -2772,7 +2851,7 @@
|
|
|
2772
2851
|
if (this.itemMetadataSortedByExpirationTime.length > 0) {
|
|
2773
2852
|
const item = this.itemMetadataSortedByExpirationTime[0];
|
|
2774
2853
|
if (Number.isFinite(item.expirationTime)) {
|
|
2775
|
-
const cancel = es2018.setSchedule(item.expirationTime, () => {
|
|
2854
|
+
const cancel = es2018$2.setSchedule(item.expirationTime, () => {
|
|
2776
2855
|
this.clearExpiredItems(Date.now());
|
|
2777
2856
|
this.rescheduleClearTimeout();
|
|
2778
2857
|
});
|
|
@@ -2787,7 +2866,7 @@
|
|
|
2787
2866
|
* Return the earliest key inserted in the Map
|
|
2788
2867
|
*/
|
|
2789
2868
|
getColdestKey() {
|
|
2790
|
-
return es2018$
|
|
2869
|
+
return es2018$5.first(__classPrivateFieldGet(this, _TLRUMap_map, "f").keys());
|
|
2791
2870
|
}
|
|
2792
2871
|
}
|
|
2793
2872
|
|
|
@@ -2855,7 +2934,7 @@
|
|
|
2855
2934
|
delete node.value;
|
|
2856
2935
|
// 如果节点没有后缀, 则代表这是末端节点, 往前删除其前缀
|
|
2857
2936
|
if (node.children.size === 0) {
|
|
2858
|
-
for (const [part, parentNode] of es2018$
|
|
2937
|
+
for (const [part, parentNode] of es2018$5.toArray(es2018$5.zip(key, parentNodes)).reverse()) {
|
|
2859
2938
|
parentNode.children.delete(part);
|
|
2860
2939
|
if (parentNode.children.size !== 0)
|
|
2861
2940
|
break;
|
|
@@ -2865,11 +2944,1096 @@
|
|
|
2865
2944
|
}
|
|
2866
2945
|
}
|
|
2867
2946
|
|
|
2947
|
+
var _FiniteStateMachine_state;
|
|
2948
|
+
class FiniteStateMachine {
|
|
2949
|
+
constructor(schema, initialState) {
|
|
2950
|
+
this.schema = schema;
|
|
2951
|
+
_FiniteStateMachine_state.set(this, void 0);
|
|
2952
|
+
__classPrivateFieldSet(this, _FiniteStateMachine_state, initialState, "f");
|
|
2953
|
+
}
|
|
2954
|
+
get state() {
|
|
2955
|
+
return __classPrivateFieldGet(this, _FiniteStateMachine_state, "f");
|
|
2956
|
+
}
|
|
2957
|
+
matches(state) {
|
|
2958
|
+
return __classPrivateFieldGet(this, _FiniteStateMachine_state, "f") === state;
|
|
2959
|
+
}
|
|
2960
|
+
/**
|
|
2961
|
+
* @throws {BadEventError}
|
|
2962
|
+
*/
|
|
2963
|
+
send(event) {
|
|
2964
|
+
if (event in this.schema[this.state]) {
|
|
2965
|
+
__classPrivateFieldSet(this, _FiniteStateMachine_state, this.schema[this.state][event], "f");
|
|
2966
|
+
}
|
|
2967
|
+
else {
|
|
2968
|
+
throw new BadEventError(this.state, event);
|
|
2969
|
+
}
|
|
2970
|
+
}
|
|
2971
|
+
}
|
|
2972
|
+
_FiniteStateMachine_state = new WeakMap();
|
|
2973
|
+
class BadEventError extends es2018$6.CustomError {
|
|
2974
|
+
constructor(state, event) {
|
|
2975
|
+
super(`State ${state} cannot react to event ${event}`);
|
|
2976
|
+
}
|
|
2977
|
+
}
|
|
2978
|
+
|
|
2979
|
+
/*! *****************************************************************************
|
|
2980
|
+
Copyright (c) Microsoft Corporation.
|
|
2981
|
+
|
|
2982
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
2983
|
+
purpose with or without fee is hereby granted.
|
|
2984
|
+
|
|
2985
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
2986
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
2987
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
2988
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
2989
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
2990
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
2991
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
2992
|
+
***************************************************************************** */
|
|
2993
|
+
/* global Reflect, Promise */
|
|
2994
|
+
|
|
2995
|
+
var extendStatics = function(d, b) {
|
|
2996
|
+
extendStatics = Object.setPrototypeOf ||
|
|
2997
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
2998
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
2999
|
+
return extendStatics(d, b);
|
|
3000
|
+
};
|
|
3001
|
+
|
|
3002
|
+
function __extends(d, b) {
|
|
3003
|
+
if (typeof b !== "function" && b !== null)
|
|
3004
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
3005
|
+
extendStatics(d, b);
|
|
3006
|
+
function __() { this.constructor = d; }
|
|
3007
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
3008
|
+
}
|
|
3009
|
+
|
|
3010
|
+
function __values(o) {
|
|
3011
|
+
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
|
|
3012
|
+
if (m) return m.call(o);
|
|
3013
|
+
if (o && typeof o.length === "number") return {
|
|
3014
|
+
next: function () {
|
|
3015
|
+
if (o && i >= o.length) o = void 0;
|
|
3016
|
+
return { value: o && o[i++], done: !o };
|
|
3017
|
+
}
|
|
3018
|
+
};
|
|
3019
|
+
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
|
|
3020
|
+
}
|
|
3021
|
+
|
|
3022
|
+
function __read(o, n) {
|
|
3023
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
3024
|
+
if (!m) return o;
|
|
3025
|
+
var i = m.call(o), r, ar = [], e;
|
|
3026
|
+
try {
|
|
3027
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
3028
|
+
}
|
|
3029
|
+
catch (error) { e = { error: error }; }
|
|
3030
|
+
finally {
|
|
3031
|
+
try {
|
|
3032
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
3033
|
+
}
|
|
3034
|
+
finally { if (e) throw e.error; }
|
|
3035
|
+
}
|
|
3036
|
+
return ar;
|
|
3037
|
+
}
|
|
3038
|
+
|
|
3039
|
+
function __spreadArray(to, from) {
|
|
3040
|
+
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
3041
|
+
to[j] = from[i];
|
|
3042
|
+
return to;
|
|
3043
|
+
}
|
|
3044
|
+
|
|
3045
|
+
function isFunction$1(value) {
|
|
3046
|
+
return typeof value === 'function';
|
|
3047
|
+
}
|
|
3048
|
+
|
|
3049
|
+
function createErrorClass(createImpl) {
|
|
3050
|
+
var _super = function (instance) {
|
|
3051
|
+
Error.call(instance);
|
|
3052
|
+
instance.stack = new Error().stack;
|
|
3053
|
+
};
|
|
3054
|
+
var ctorFunc = createImpl(_super);
|
|
3055
|
+
ctorFunc.prototype = Object.create(Error.prototype);
|
|
3056
|
+
ctorFunc.prototype.constructor = ctorFunc;
|
|
3057
|
+
return ctorFunc;
|
|
3058
|
+
}
|
|
3059
|
+
|
|
3060
|
+
var UnsubscriptionError = createErrorClass(function (_super) {
|
|
3061
|
+
return function UnsubscriptionErrorImpl(errors) {
|
|
3062
|
+
_super(this);
|
|
3063
|
+
this.message = errors
|
|
3064
|
+
? errors.length + " errors occurred during unsubscription:\n" + errors.map(function (err, i) { return i + 1 + ") " + err.toString(); }).join('\n ')
|
|
3065
|
+
: '';
|
|
3066
|
+
this.name = 'UnsubscriptionError';
|
|
3067
|
+
this.errors = errors;
|
|
3068
|
+
};
|
|
3069
|
+
});
|
|
3070
|
+
|
|
3071
|
+
function arrRemove(arr, item) {
|
|
3072
|
+
if (arr) {
|
|
3073
|
+
var index = arr.indexOf(item);
|
|
3074
|
+
0 <= index && arr.splice(index, 1);
|
|
3075
|
+
}
|
|
3076
|
+
}
|
|
3077
|
+
|
|
3078
|
+
var Subscription = (function () {
|
|
3079
|
+
function Subscription(initialTeardown) {
|
|
3080
|
+
this.initialTeardown = initialTeardown;
|
|
3081
|
+
this.closed = false;
|
|
3082
|
+
this._parentage = null;
|
|
3083
|
+
this._teardowns = null;
|
|
3084
|
+
}
|
|
3085
|
+
Subscription.prototype.unsubscribe = function () {
|
|
3086
|
+
var e_1, _a, e_2, _b;
|
|
3087
|
+
var errors;
|
|
3088
|
+
if (!this.closed) {
|
|
3089
|
+
this.closed = true;
|
|
3090
|
+
var _parentage = this._parentage;
|
|
3091
|
+
if (_parentage) {
|
|
3092
|
+
this._parentage = null;
|
|
3093
|
+
if (Array.isArray(_parentage)) {
|
|
3094
|
+
try {
|
|
3095
|
+
for (var _parentage_1 = __values(_parentage), _parentage_1_1 = _parentage_1.next(); !_parentage_1_1.done; _parentage_1_1 = _parentage_1.next()) {
|
|
3096
|
+
var parent_1 = _parentage_1_1.value;
|
|
3097
|
+
parent_1.remove(this);
|
|
3098
|
+
}
|
|
3099
|
+
}
|
|
3100
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
3101
|
+
finally {
|
|
3102
|
+
try {
|
|
3103
|
+
if (_parentage_1_1 && !_parentage_1_1.done && (_a = _parentage_1.return)) _a.call(_parentage_1);
|
|
3104
|
+
}
|
|
3105
|
+
finally { if (e_1) throw e_1.error; }
|
|
3106
|
+
}
|
|
3107
|
+
}
|
|
3108
|
+
else {
|
|
3109
|
+
_parentage.remove(this);
|
|
3110
|
+
}
|
|
3111
|
+
}
|
|
3112
|
+
var initialTeardown = this.initialTeardown;
|
|
3113
|
+
if (isFunction$1(initialTeardown)) {
|
|
3114
|
+
try {
|
|
3115
|
+
initialTeardown();
|
|
3116
|
+
}
|
|
3117
|
+
catch (e) {
|
|
3118
|
+
errors = e instanceof UnsubscriptionError ? e.errors : [e];
|
|
3119
|
+
}
|
|
3120
|
+
}
|
|
3121
|
+
var _teardowns = this._teardowns;
|
|
3122
|
+
if (_teardowns) {
|
|
3123
|
+
this._teardowns = null;
|
|
3124
|
+
try {
|
|
3125
|
+
for (var _teardowns_1 = __values(_teardowns), _teardowns_1_1 = _teardowns_1.next(); !_teardowns_1_1.done; _teardowns_1_1 = _teardowns_1.next()) {
|
|
3126
|
+
var teardown_1 = _teardowns_1_1.value;
|
|
3127
|
+
try {
|
|
3128
|
+
execTeardown(teardown_1);
|
|
3129
|
+
}
|
|
3130
|
+
catch (err) {
|
|
3131
|
+
errors = errors !== null && errors !== void 0 ? errors : [];
|
|
3132
|
+
if (err instanceof UnsubscriptionError) {
|
|
3133
|
+
errors = __spreadArray(__spreadArray([], __read(errors)), __read(err.errors));
|
|
3134
|
+
}
|
|
3135
|
+
else {
|
|
3136
|
+
errors.push(err);
|
|
3137
|
+
}
|
|
3138
|
+
}
|
|
3139
|
+
}
|
|
3140
|
+
}
|
|
3141
|
+
catch (e_2_1) { e_2 = { error: e_2_1 }; }
|
|
3142
|
+
finally {
|
|
3143
|
+
try {
|
|
3144
|
+
if (_teardowns_1_1 && !_teardowns_1_1.done && (_b = _teardowns_1.return)) _b.call(_teardowns_1);
|
|
3145
|
+
}
|
|
3146
|
+
finally { if (e_2) throw e_2.error; }
|
|
3147
|
+
}
|
|
3148
|
+
}
|
|
3149
|
+
if (errors) {
|
|
3150
|
+
throw new UnsubscriptionError(errors);
|
|
3151
|
+
}
|
|
3152
|
+
}
|
|
3153
|
+
};
|
|
3154
|
+
Subscription.prototype.add = function (teardown) {
|
|
3155
|
+
var _a;
|
|
3156
|
+
if (teardown && teardown !== this) {
|
|
3157
|
+
if (this.closed) {
|
|
3158
|
+
execTeardown(teardown);
|
|
3159
|
+
}
|
|
3160
|
+
else {
|
|
3161
|
+
if (teardown instanceof Subscription) {
|
|
3162
|
+
if (teardown.closed || teardown._hasParent(this)) {
|
|
3163
|
+
return;
|
|
3164
|
+
}
|
|
3165
|
+
teardown._addParent(this);
|
|
3166
|
+
}
|
|
3167
|
+
(this._teardowns = (_a = this._teardowns) !== null && _a !== void 0 ? _a : []).push(teardown);
|
|
3168
|
+
}
|
|
3169
|
+
}
|
|
3170
|
+
};
|
|
3171
|
+
Subscription.prototype._hasParent = function (parent) {
|
|
3172
|
+
var _parentage = this._parentage;
|
|
3173
|
+
return _parentage === parent || (Array.isArray(_parentage) && _parentage.includes(parent));
|
|
3174
|
+
};
|
|
3175
|
+
Subscription.prototype._addParent = function (parent) {
|
|
3176
|
+
var _parentage = this._parentage;
|
|
3177
|
+
this._parentage = Array.isArray(_parentage) ? (_parentage.push(parent), _parentage) : _parentage ? [_parentage, parent] : parent;
|
|
3178
|
+
};
|
|
3179
|
+
Subscription.prototype._removeParent = function (parent) {
|
|
3180
|
+
var _parentage = this._parentage;
|
|
3181
|
+
if (_parentage === parent) {
|
|
3182
|
+
this._parentage = null;
|
|
3183
|
+
}
|
|
3184
|
+
else if (Array.isArray(_parentage)) {
|
|
3185
|
+
arrRemove(_parentage, parent);
|
|
3186
|
+
}
|
|
3187
|
+
};
|
|
3188
|
+
Subscription.prototype.remove = function (teardown) {
|
|
3189
|
+
var _teardowns = this._teardowns;
|
|
3190
|
+
_teardowns && arrRemove(_teardowns, teardown);
|
|
3191
|
+
if (teardown instanceof Subscription) {
|
|
3192
|
+
teardown._removeParent(this);
|
|
3193
|
+
}
|
|
3194
|
+
};
|
|
3195
|
+
Subscription.EMPTY = (function () {
|
|
3196
|
+
var empty = new Subscription();
|
|
3197
|
+
empty.closed = true;
|
|
3198
|
+
return empty;
|
|
3199
|
+
})();
|
|
3200
|
+
return Subscription;
|
|
3201
|
+
}());
|
|
3202
|
+
var EMPTY_SUBSCRIPTION = Subscription.EMPTY;
|
|
3203
|
+
function isSubscription(value) {
|
|
3204
|
+
return (value instanceof Subscription ||
|
|
3205
|
+
(value && 'closed' in value && isFunction$1(value.remove) && isFunction$1(value.add) && isFunction$1(value.unsubscribe)));
|
|
3206
|
+
}
|
|
3207
|
+
function execTeardown(teardown) {
|
|
3208
|
+
if (isFunction$1(teardown)) {
|
|
3209
|
+
teardown();
|
|
3210
|
+
}
|
|
3211
|
+
else {
|
|
3212
|
+
teardown.unsubscribe();
|
|
3213
|
+
}
|
|
3214
|
+
}
|
|
3215
|
+
|
|
3216
|
+
var config = {
|
|
3217
|
+
onUnhandledError: null,
|
|
3218
|
+
onStoppedNotification: null,
|
|
3219
|
+
Promise: undefined,
|
|
3220
|
+
useDeprecatedSynchronousErrorHandling: false,
|
|
3221
|
+
useDeprecatedNextContext: false,
|
|
3222
|
+
};
|
|
3223
|
+
|
|
3224
|
+
var timeoutProvider = {
|
|
3225
|
+
setTimeout: function () {
|
|
3226
|
+
var args = [];
|
|
3227
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
3228
|
+
args[_i] = arguments[_i];
|
|
3229
|
+
}
|
|
3230
|
+
var delegate = timeoutProvider.delegate;
|
|
3231
|
+
return ((delegate === null || delegate === void 0 ? void 0 : delegate.setTimeout) || setTimeout).apply(void 0, __spreadArray([], __read(args)));
|
|
3232
|
+
},
|
|
3233
|
+
clearTimeout: function (handle) {
|
|
3234
|
+
var delegate = timeoutProvider.delegate;
|
|
3235
|
+
return ((delegate === null || delegate === void 0 ? void 0 : delegate.clearTimeout) || clearTimeout)(handle);
|
|
3236
|
+
},
|
|
3237
|
+
delegate: undefined,
|
|
3238
|
+
};
|
|
3239
|
+
|
|
3240
|
+
function reportUnhandledError(err) {
|
|
3241
|
+
timeoutProvider.setTimeout(function () {
|
|
3242
|
+
{
|
|
3243
|
+
throw err;
|
|
3244
|
+
}
|
|
3245
|
+
});
|
|
3246
|
+
}
|
|
3247
|
+
|
|
3248
|
+
function noop() { }
|
|
3249
|
+
|
|
3250
|
+
var context = null;
|
|
3251
|
+
function errorContext(cb) {
|
|
3252
|
+
if (config.useDeprecatedSynchronousErrorHandling) {
|
|
3253
|
+
var isRoot = !context;
|
|
3254
|
+
if (isRoot) {
|
|
3255
|
+
context = { errorThrown: false, error: null };
|
|
3256
|
+
}
|
|
3257
|
+
cb();
|
|
3258
|
+
if (isRoot) {
|
|
3259
|
+
var _a = context, errorThrown = _a.errorThrown, error = _a.error;
|
|
3260
|
+
context = null;
|
|
3261
|
+
if (errorThrown) {
|
|
3262
|
+
throw error;
|
|
3263
|
+
}
|
|
3264
|
+
}
|
|
3265
|
+
}
|
|
3266
|
+
else {
|
|
3267
|
+
cb();
|
|
3268
|
+
}
|
|
3269
|
+
}
|
|
3270
|
+
|
|
3271
|
+
var Subscriber = (function (_super) {
|
|
3272
|
+
__extends(Subscriber, _super);
|
|
3273
|
+
function Subscriber(destination) {
|
|
3274
|
+
var _this = _super.call(this) || this;
|
|
3275
|
+
_this.isStopped = false;
|
|
3276
|
+
if (destination) {
|
|
3277
|
+
_this.destination = destination;
|
|
3278
|
+
if (isSubscription(destination)) {
|
|
3279
|
+
destination.add(_this);
|
|
3280
|
+
}
|
|
3281
|
+
}
|
|
3282
|
+
else {
|
|
3283
|
+
_this.destination = EMPTY_OBSERVER;
|
|
3284
|
+
}
|
|
3285
|
+
return _this;
|
|
3286
|
+
}
|
|
3287
|
+
Subscriber.create = function (next, error, complete) {
|
|
3288
|
+
return new SafeSubscriber(next, error, complete);
|
|
3289
|
+
};
|
|
3290
|
+
Subscriber.prototype.next = function (value) {
|
|
3291
|
+
if (this.isStopped) ;
|
|
3292
|
+
else {
|
|
3293
|
+
this._next(value);
|
|
3294
|
+
}
|
|
3295
|
+
};
|
|
3296
|
+
Subscriber.prototype.error = function (err) {
|
|
3297
|
+
if (this.isStopped) ;
|
|
3298
|
+
else {
|
|
3299
|
+
this.isStopped = true;
|
|
3300
|
+
this._error(err);
|
|
3301
|
+
}
|
|
3302
|
+
};
|
|
3303
|
+
Subscriber.prototype.complete = function () {
|
|
3304
|
+
if (this.isStopped) ;
|
|
3305
|
+
else {
|
|
3306
|
+
this.isStopped = true;
|
|
3307
|
+
this._complete();
|
|
3308
|
+
}
|
|
3309
|
+
};
|
|
3310
|
+
Subscriber.prototype.unsubscribe = function () {
|
|
3311
|
+
if (!this.closed) {
|
|
3312
|
+
this.isStopped = true;
|
|
3313
|
+
_super.prototype.unsubscribe.call(this);
|
|
3314
|
+
this.destination = null;
|
|
3315
|
+
}
|
|
3316
|
+
};
|
|
3317
|
+
Subscriber.prototype._next = function (value) {
|
|
3318
|
+
this.destination.next(value);
|
|
3319
|
+
};
|
|
3320
|
+
Subscriber.prototype._error = function (err) {
|
|
3321
|
+
try {
|
|
3322
|
+
this.destination.error(err);
|
|
3323
|
+
}
|
|
3324
|
+
finally {
|
|
3325
|
+
this.unsubscribe();
|
|
3326
|
+
}
|
|
3327
|
+
};
|
|
3328
|
+
Subscriber.prototype._complete = function () {
|
|
3329
|
+
try {
|
|
3330
|
+
this.destination.complete();
|
|
3331
|
+
}
|
|
3332
|
+
finally {
|
|
3333
|
+
this.unsubscribe();
|
|
3334
|
+
}
|
|
3335
|
+
};
|
|
3336
|
+
return Subscriber;
|
|
3337
|
+
}(Subscription));
|
|
3338
|
+
var SafeSubscriber = (function (_super) {
|
|
3339
|
+
__extends(SafeSubscriber, _super);
|
|
3340
|
+
function SafeSubscriber(observerOrNext, error, complete) {
|
|
3341
|
+
var _this = _super.call(this) || this;
|
|
3342
|
+
var next;
|
|
3343
|
+
if (isFunction$1(observerOrNext)) {
|
|
3344
|
+
next = observerOrNext;
|
|
3345
|
+
}
|
|
3346
|
+
else if (observerOrNext) {
|
|
3347
|
+
(next = observerOrNext.next, error = observerOrNext.error, complete = observerOrNext.complete);
|
|
3348
|
+
var context_1;
|
|
3349
|
+
if (_this && config.useDeprecatedNextContext) {
|
|
3350
|
+
context_1 = Object.create(observerOrNext);
|
|
3351
|
+
context_1.unsubscribe = function () { return _this.unsubscribe(); };
|
|
3352
|
+
}
|
|
3353
|
+
else {
|
|
3354
|
+
context_1 = observerOrNext;
|
|
3355
|
+
}
|
|
3356
|
+
next = next === null || next === void 0 ? void 0 : next.bind(context_1);
|
|
3357
|
+
error = error === null || error === void 0 ? void 0 : error.bind(context_1);
|
|
3358
|
+
complete = complete === null || complete === void 0 ? void 0 : complete.bind(context_1);
|
|
3359
|
+
}
|
|
3360
|
+
_this.destination = {
|
|
3361
|
+
next: next ? wrapForErrorHandling(next) : noop,
|
|
3362
|
+
error: wrapForErrorHandling(error !== null && error !== void 0 ? error : defaultErrorHandler),
|
|
3363
|
+
complete: complete ? wrapForErrorHandling(complete) : noop,
|
|
3364
|
+
};
|
|
3365
|
+
return _this;
|
|
3366
|
+
}
|
|
3367
|
+
return SafeSubscriber;
|
|
3368
|
+
}(Subscriber));
|
|
3369
|
+
function wrapForErrorHandling(handler, instance) {
|
|
3370
|
+
return function () {
|
|
3371
|
+
var args = [];
|
|
3372
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
3373
|
+
args[_i] = arguments[_i];
|
|
3374
|
+
}
|
|
3375
|
+
try {
|
|
3376
|
+
handler.apply(void 0, __spreadArray([], __read(args)));
|
|
3377
|
+
}
|
|
3378
|
+
catch (err) {
|
|
3379
|
+
{
|
|
3380
|
+
reportUnhandledError(err);
|
|
3381
|
+
}
|
|
3382
|
+
}
|
|
3383
|
+
};
|
|
3384
|
+
}
|
|
3385
|
+
function defaultErrorHandler(err) {
|
|
3386
|
+
throw err;
|
|
3387
|
+
}
|
|
3388
|
+
var EMPTY_OBSERVER = {
|
|
3389
|
+
closed: true,
|
|
3390
|
+
next: noop,
|
|
3391
|
+
error: defaultErrorHandler,
|
|
3392
|
+
complete: noop,
|
|
3393
|
+
};
|
|
3394
|
+
|
|
3395
|
+
var observable = (function () { return (typeof Symbol === 'function' && Symbol.observable) || '@@observable'; })();
|
|
3396
|
+
|
|
3397
|
+
function identity(x) {
|
|
3398
|
+
return x;
|
|
3399
|
+
}
|
|
3400
|
+
|
|
3401
|
+
function pipeFromArray(fns) {
|
|
3402
|
+
if (fns.length === 0) {
|
|
3403
|
+
return identity;
|
|
3404
|
+
}
|
|
3405
|
+
if (fns.length === 1) {
|
|
3406
|
+
return fns[0];
|
|
3407
|
+
}
|
|
3408
|
+
return function piped(input) {
|
|
3409
|
+
return fns.reduce(function (prev, fn) { return fn(prev); }, input);
|
|
3410
|
+
};
|
|
3411
|
+
}
|
|
3412
|
+
|
|
3413
|
+
var Observable = (function () {
|
|
3414
|
+
function Observable(subscribe) {
|
|
3415
|
+
if (subscribe) {
|
|
3416
|
+
this._subscribe = subscribe;
|
|
3417
|
+
}
|
|
3418
|
+
}
|
|
3419
|
+
Observable.prototype.lift = function (operator) {
|
|
3420
|
+
var observable = new Observable();
|
|
3421
|
+
observable.source = this;
|
|
3422
|
+
observable.operator = operator;
|
|
3423
|
+
return observable;
|
|
3424
|
+
};
|
|
3425
|
+
Observable.prototype.subscribe = function (observerOrNext, error, complete) {
|
|
3426
|
+
var _this = this;
|
|
3427
|
+
var subscriber = isSubscriber(observerOrNext) ? observerOrNext : new SafeSubscriber(observerOrNext, error, complete);
|
|
3428
|
+
errorContext(function () {
|
|
3429
|
+
var _a = _this, operator = _a.operator, source = _a.source;
|
|
3430
|
+
subscriber.add(operator
|
|
3431
|
+
?
|
|
3432
|
+
operator.call(subscriber, source)
|
|
3433
|
+
: source
|
|
3434
|
+
?
|
|
3435
|
+
_this._subscribe(subscriber)
|
|
3436
|
+
:
|
|
3437
|
+
_this._trySubscribe(subscriber));
|
|
3438
|
+
});
|
|
3439
|
+
return subscriber;
|
|
3440
|
+
};
|
|
3441
|
+
Observable.prototype._trySubscribe = function (sink) {
|
|
3442
|
+
try {
|
|
3443
|
+
return this._subscribe(sink);
|
|
3444
|
+
}
|
|
3445
|
+
catch (err) {
|
|
3446
|
+
sink.error(err);
|
|
3447
|
+
}
|
|
3448
|
+
};
|
|
3449
|
+
Observable.prototype.forEach = function (next, promiseCtor) {
|
|
3450
|
+
var _this = this;
|
|
3451
|
+
promiseCtor = getPromiseCtor(promiseCtor);
|
|
3452
|
+
return new promiseCtor(function (resolve, reject) {
|
|
3453
|
+
var subscription;
|
|
3454
|
+
subscription = _this.subscribe(function (value) {
|
|
3455
|
+
try {
|
|
3456
|
+
next(value);
|
|
3457
|
+
}
|
|
3458
|
+
catch (err) {
|
|
3459
|
+
reject(err);
|
|
3460
|
+
subscription === null || subscription === void 0 ? void 0 : subscription.unsubscribe();
|
|
3461
|
+
}
|
|
3462
|
+
}, reject, resolve);
|
|
3463
|
+
});
|
|
3464
|
+
};
|
|
3465
|
+
Observable.prototype._subscribe = function (subscriber) {
|
|
3466
|
+
var _a;
|
|
3467
|
+
return (_a = this.source) === null || _a === void 0 ? void 0 : _a.subscribe(subscriber);
|
|
3468
|
+
};
|
|
3469
|
+
Observable.prototype[observable] = function () {
|
|
3470
|
+
return this;
|
|
3471
|
+
};
|
|
3472
|
+
Observable.prototype.pipe = function () {
|
|
3473
|
+
var operations = [];
|
|
3474
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
3475
|
+
operations[_i] = arguments[_i];
|
|
3476
|
+
}
|
|
3477
|
+
return pipeFromArray(operations)(this);
|
|
3478
|
+
};
|
|
3479
|
+
Observable.prototype.toPromise = function (promiseCtor) {
|
|
3480
|
+
var _this = this;
|
|
3481
|
+
promiseCtor = getPromiseCtor(promiseCtor);
|
|
3482
|
+
return new promiseCtor(function (resolve, reject) {
|
|
3483
|
+
var value;
|
|
3484
|
+
_this.subscribe(function (x) { return (value = x); }, function (err) { return reject(err); }, function () { return resolve(value); });
|
|
3485
|
+
});
|
|
3486
|
+
};
|
|
3487
|
+
Observable.create = function (subscribe) {
|
|
3488
|
+
return new Observable(subscribe);
|
|
3489
|
+
};
|
|
3490
|
+
return Observable;
|
|
3491
|
+
}());
|
|
3492
|
+
function getPromiseCtor(promiseCtor) {
|
|
3493
|
+
var _a;
|
|
3494
|
+
return (_a = promiseCtor !== null && promiseCtor !== void 0 ? promiseCtor : config.Promise) !== null && _a !== void 0 ? _a : Promise;
|
|
3495
|
+
}
|
|
3496
|
+
function isObserver(value) {
|
|
3497
|
+
return value && isFunction$1(value.next) && isFunction$1(value.error) && isFunction$1(value.complete);
|
|
3498
|
+
}
|
|
3499
|
+
function isSubscriber(value) {
|
|
3500
|
+
return (value && value instanceof Subscriber) || (isObserver(value) && isSubscription(value));
|
|
3501
|
+
}
|
|
3502
|
+
|
|
3503
|
+
var ObjectUnsubscribedError = createErrorClass(function (_super) {
|
|
3504
|
+
return function ObjectUnsubscribedErrorImpl() {
|
|
3505
|
+
_super(this);
|
|
3506
|
+
this.name = 'ObjectUnsubscribedError';
|
|
3507
|
+
this.message = 'object unsubscribed';
|
|
3508
|
+
};
|
|
3509
|
+
});
|
|
3510
|
+
|
|
3511
|
+
var Subject = (function (_super) {
|
|
3512
|
+
__extends(Subject, _super);
|
|
3513
|
+
function Subject() {
|
|
3514
|
+
var _this = _super.call(this) || this;
|
|
3515
|
+
_this.closed = false;
|
|
3516
|
+
_this.observers = [];
|
|
3517
|
+
_this.isStopped = false;
|
|
3518
|
+
_this.hasError = false;
|
|
3519
|
+
_this.thrownError = null;
|
|
3520
|
+
return _this;
|
|
3521
|
+
}
|
|
3522
|
+
Subject.prototype.lift = function (operator) {
|
|
3523
|
+
var subject = new AnonymousSubject(this, this);
|
|
3524
|
+
subject.operator = operator;
|
|
3525
|
+
return subject;
|
|
3526
|
+
};
|
|
3527
|
+
Subject.prototype._throwIfClosed = function () {
|
|
3528
|
+
if (this.closed) {
|
|
3529
|
+
throw new ObjectUnsubscribedError();
|
|
3530
|
+
}
|
|
3531
|
+
};
|
|
3532
|
+
Subject.prototype.next = function (value) {
|
|
3533
|
+
var _this = this;
|
|
3534
|
+
errorContext(function () {
|
|
3535
|
+
var e_1, _a;
|
|
3536
|
+
_this._throwIfClosed();
|
|
3537
|
+
if (!_this.isStopped) {
|
|
3538
|
+
var copy = _this.observers.slice();
|
|
3539
|
+
try {
|
|
3540
|
+
for (var copy_1 = __values(copy), copy_1_1 = copy_1.next(); !copy_1_1.done; copy_1_1 = copy_1.next()) {
|
|
3541
|
+
var observer = copy_1_1.value;
|
|
3542
|
+
observer.next(value);
|
|
3543
|
+
}
|
|
3544
|
+
}
|
|
3545
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
3546
|
+
finally {
|
|
3547
|
+
try {
|
|
3548
|
+
if (copy_1_1 && !copy_1_1.done && (_a = copy_1.return)) _a.call(copy_1);
|
|
3549
|
+
}
|
|
3550
|
+
finally { if (e_1) throw e_1.error; }
|
|
3551
|
+
}
|
|
3552
|
+
}
|
|
3553
|
+
});
|
|
3554
|
+
};
|
|
3555
|
+
Subject.prototype.error = function (err) {
|
|
3556
|
+
var _this = this;
|
|
3557
|
+
errorContext(function () {
|
|
3558
|
+
_this._throwIfClosed();
|
|
3559
|
+
if (!_this.isStopped) {
|
|
3560
|
+
_this.hasError = _this.isStopped = true;
|
|
3561
|
+
_this.thrownError = err;
|
|
3562
|
+
var observers = _this.observers;
|
|
3563
|
+
while (observers.length) {
|
|
3564
|
+
observers.shift().error(err);
|
|
3565
|
+
}
|
|
3566
|
+
}
|
|
3567
|
+
});
|
|
3568
|
+
};
|
|
3569
|
+
Subject.prototype.complete = function () {
|
|
3570
|
+
var _this = this;
|
|
3571
|
+
errorContext(function () {
|
|
3572
|
+
_this._throwIfClosed();
|
|
3573
|
+
if (!_this.isStopped) {
|
|
3574
|
+
_this.isStopped = true;
|
|
3575
|
+
var observers = _this.observers;
|
|
3576
|
+
while (observers.length) {
|
|
3577
|
+
observers.shift().complete();
|
|
3578
|
+
}
|
|
3579
|
+
}
|
|
3580
|
+
});
|
|
3581
|
+
};
|
|
3582
|
+
Subject.prototype.unsubscribe = function () {
|
|
3583
|
+
this.isStopped = this.closed = true;
|
|
3584
|
+
this.observers = null;
|
|
3585
|
+
};
|
|
3586
|
+
Object.defineProperty(Subject.prototype, "observed", {
|
|
3587
|
+
get: function () {
|
|
3588
|
+
var _a;
|
|
3589
|
+
return ((_a = this.observers) === null || _a === void 0 ? void 0 : _a.length) > 0;
|
|
3590
|
+
},
|
|
3591
|
+
enumerable: false,
|
|
3592
|
+
configurable: true
|
|
3593
|
+
});
|
|
3594
|
+
Subject.prototype._trySubscribe = function (subscriber) {
|
|
3595
|
+
this._throwIfClosed();
|
|
3596
|
+
return _super.prototype._trySubscribe.call(this, subscriber);
|
|
3597
|
+
};
|
|
3598
|
+
Subject.prototype._subscribe = function (subscriber) {
|
|
3599
|
+
this._throwIfClosed();
|
|
3600
|
+
this._checkFinalizedStatuses(subscriber);
|
|
3601
|
+
return this._innerSubscribe(subscriber);
|
|
3602
|
+
};
|
|
3603
|
+
Subject.prototype._innerSubscribe = function (subscriber) {
|
|
3604
|
+
var _a = this, hasError = _a.hasError, isStopped = _a.isStopped, observers = _a.observers;
|
|
3605
|
+
return hasError || isStopped
|
|
3606
|
+
? EMPTY_SUBSCRIPTION
|
|
3607
|
+
: (observers.push(subscriber), new Subscription(function () { return arrRemove(observers, subscriber); }));
|
|
3608
|
+
};
|
|
3609
|
+
Subject.prototype._checkFinalizedStatuses = function (subscriber) {
|
|
3610
|
+
var _a = this, hasError = _a.hasError, thrownError = _a.thrownError, isStopped = _a.isStopped;
|
|
3611
|
+
if (hasError) {
|
|
3612
|
+
subscriber.error(thrownError);
|
|
3613
|
+
}
|
|
3614
|
+
else if (isStopped) {
|
|
3615
|
+
subscriber.complete();
|
|
3616
|
+
}
|
|
3617
|
+
};
|
|
3618
|
+
Subject.prototype.asObservable = function () {
|
|
3619
|
+
var observable = new Observable();
|
|
3620
|
+
observable.source = this;
|
|
3621
|
+
return observable;
|
|
3622
|
+
};
|
|
3623
|
+
Subject.create = function (destination, source) {
|
|
3624
|
+
return new AnonymousSubject(destination, source);
|
|
3625
|
+
};
|
|
3626
|
+
return Subject;
|
|
3627
|
+
}(Observable));
|
|
3628
|
+
var AnonymousSubject = (function (_super) {
|
|
3629
|
+
__extends(AnonymousSubject, _super);
|
|
3630
|
+
function AnonymousSubject(destination, source) {
|
|
3631
|
+
var _this = _super.call(this) || this;
|
|
3632
|
+
_this.destination = destination;
|
|
3633
|
+
_this.source = source;
|
|
3634
|
+
return _this;
|
|
3635
|
+
}
|
|
3636
|
+
AnonymousSubject.prototype.next = function (value) {
|
|
3637
|
+
var _a, _b;
|
|
3638
|
+
(_b = (_a = this.destination) === null || _a === void 0 ? void 0 : _a.next) === null || _b === void 0 ? void 0 : _b.call(_a, value);
|
|
3639
|
+
};
|
|
3640
|
+
AnonymousSubject.prototype.error = function (err) {
|
|
3641
|
+
var _a, _b;
|
|
3642
|
+
(_b = (_a = this.destination) === null || _a === void 0 ? void 0 : _a.error) === null || _b === void 0 ? void 0 : _b.call(_a, err);
|
|
3643
|
+
};
|
|
3644
|
+
AnonymousSubject.prototype.complete = function () {
|
|
3645
|
+
var _a, _b;
|
|
3646
|
+
(_b = (_a = this.destination) === null || _a === void 0 ? void 0 : _a.complete) === null || _b === void 0 ? void 0 : _b.call(_a);
|
|
3647
|
+
};
|
|
3648
|
+
AnonymousSubject.prototype._subscribe = function (subscriber) {
|
|
3649
|
+
var _a, _b;
|
|
3650
|
+
return (_b = (_a = this.source) === null || _a === void 0 ? void 0 : _a.subscribe(subscriber)) !== null && _b !== void 0 ? _b : EMPTY_SUBSCRIPTION;
|
|
3651
|
+
};
|
|
3652
|
+
return AnonymousSubject;
|
|
3653
|
+
}(Subject));
|
|
3654
|
+
|
|
3655
|
+
var es2018 = {};
|
|
3656
|
+
|
|
3657
|
+
var array = {};
|
|
3658
|
+
|
|
3659
|
+
array.isntEmptyArray = array.isEmptyArray = array.isntArray = array.isArray = void 0;
|
|
3660
|
+
function isArray(val) {
|
|
3661
|
+
return Array.isArray(val);
|
|
3662
|
+
}
|
|
3663
|
+
array.isArray = isArray;
|
|
3664
|
+
function isntArray(val) {
|
|
3665
|
+
return !isArray(val);
|
|
3666
|
+
}
|
|
3667
|
+
array.isntArray = isntArray;
|
|
3668
|
+
function isEmptyArray(val) {
|
|
3669
|
+
return val.length === 0;
|
|
3670
|
+
}
|
|
3671
|
+
array.isEmptyArray = isEmptyArray;
|
|
3672
|
+
function isntEmptyArray(val) {
|
|
3673
|
+
return val.length !== 0;
|
|
3674
|
+
}
|
|
3675
|
+
array.isntEmptyArray = isntEmptyArray;
|
|
3676
|
+
|
|
3677
|
+
var asyncIterable = {};
|
|
3678
|
+
|
|
3679
|
+
var _null = {};
|
|
3680
|
+
|
|
3681
|
+
_null.isntNull = _null.isNull = void 0;
|
|
3682
|
+
function isNull(val) {
|
|
3683
|
+
return val === null;
|
|
3684
|
+
}
|
|
3685
|
+
_null.isNull = isNull;
|
|
3686
|
+
function isntNull(val) {
|
|
3687
|
+
return !isNull(val);
|
|
3688
|
+
}
|
|
3689
|
+
_null.isntNull = isntNull;
|
|
3690
|
+
|
|
3691
|
+
var _undefined = {};
|
|
3692
|
+
|
|
3693
|
+
_undefined.isntUndefined = _undefined.isUndefined = void 0;
|
|
3694
|
+
function isUndefined(val) {
|
|
3695
|
+
return val === undefined;
|
|
3696
|
+
}
|
|
3697
|
+
_undefined.isUndefined = isUndefined;
|
|
3698
|
+
function isntUndefined(val) {
|
|
3699
|
+
return !isUndefined(val);
|
|
3700
|
+
}
|
|
3701
|
+
_undefined.isntUndefined = isntUndefined;
|
|
3702
|
+
|
|
3703
|
+
asyncIterable.isntAsyncIterable = asyncIterable.isAsyncIterable = void 0;
|
|
3704
|
+
const null_1$1 = _null;
|
|
3705
|
+
const undefined_1$2 = _undefined;
|
|
3706
|
+
function isAsyncIterable(val) {
|
|
3707
|
+
return (0, null_1$1.isntNull)(val)
|
|
3708
|
+
&& (0, undefined_1$2.isntUndefined)(val)
|
|
3709
|
+
&& typeof val[Symbol.asyncIterator] === 'function';
|
|
3710
|
+
}
|
|
3711
|
+
asyncIterable.isAsyncIterable = isAsyncIterable;
|
|
3712
|
+
function isntAsyncIterable(val) {
|
|
3713
|
+
return !isAsyncIterable(val);
|
|
3714
|
+
}
|
|
3715
|
+
asyncIterable.isntAsyncIterable = isntAsyncIterable;
|
|
3716
|
+
|
|
3717
|
+
var bigint = {};
|
|
3718
|
+
|
|
3719
|
+
bigint.isntBigInt = bigint.isBigInt = void 0;
|
|
3720
|
+
function isBigInt(val) {
|
|
3721
|
+
return typeof val === 'bigint';
|
|
3722
|
+
}
|
|
3723
|
+
bigint.isBigInt = isBigInt;
|
|
3724
|
+
function isntBigInt(val) {
|
|
3725
|
+
return !isBigInt(val);
|
|
3726
|
+
}
|
|
3727
|
+
bigint.isntBigInt = isntBigInt;
|
|
3728
|
+
|
|
3729
|
+
var boolean = {};
|
|
3730
|
+
|
|
3731
|
+
boolean.isntBoolean = boolean.isBoolean = void 0;
|
|
3732
|
+
function isBoolean(val) {
|
|
3733
|
+
return typeof val === 'boolean';
|
|
3734
|
+
}
|
|
3735
|
+
boolean.isBoolean = isBoolean;
|
|
3736
|
+
function isntBoolean(val) {
|
|
3737
|
+
return !isBoolean(val);
|
|
3738
|
+
}
|
|
3739
|
+
boolean.isntBoolean = isntBoolean;
|
|
3740
|
+
|
|
3741
|
+
var char = {};
|
|
3742
|
+
|
|
3743
|
+
var string = {};
|
|
3744
|
+
|
|
3745
|
+
string.isntString = string.isString = void 0;
|
|
3746
|
+
function isString(val) {
|
|
3747
|
+
return typeof val === 'string';
|
|
3748
|
+
}
|
|
3749
|
+
string.isString = isString;
|
|
3750
|
+
function isntString(val) {
|
|
3751
|
+
return !isString(val);
|
|
3752
|
+
}
|
|
3753
|
+
string.isntString = isntString;
|
|
3754
|
+
|
|
3755
|
+
char.isntChar = char.isChar = void 0;
|
|
3756
|
+
const string_1$1 = string;
|
|
3757
|
+
function isChar(val) {
|
|
3758
|
+
return (0, string_1$1.isString)(val)
|
|
3759
|
+
&& val.length === 1;
|
|
3760
|
+
}
|
|
3761
|
+
char.isChar = isChar;
|
|
3762
|
+
function isntChar(val) {
|
|
3763
|
+
return !isChar(val);
|
|
3764
|
+
}
|
|
3765
|
+
char.isntChar = isntChar;
|
|
3766
|
+
|
|
3767
|
+
var date = {};
|
|
3768
|
+
|
|
3769
|
+
date.isntDate = date.isDate = void 0;
|
|
3770
|
+
function isDate(val) {
|
|
3771
|
+
return val instanceof Date;
|
|
3772
|
+
}
|
|
3773
|
+
date.isDate = isDate;
|
|
3774
|
+
function isntDate(val) {
|
|
3775
|
+
return !isDate(val);
|
|
3776
|
+
}
|
|
3777
|
+
date.isntDate = isntDate;
|
|
3778
|
+
|
|
3779
|
+
var _enum = {};
|
|
3780
|
+
|
|
3781
|
+
_enum.inEnum = void 0;
|
|
3782
|
+
function inEnum(val, _enum) {
|
|
3783
|
+
return Object.values(_enum).includes(val);
|
|
3784
|
+
}
|
|
3785
|
+
_enum.inEnum = inEnum;
|
|
3786
|
+
|
|
3787
|
+
var error = {};
|
|
3788
|
+
|
|
3789
|
+
error.isntError = error.isError = void 0;
|
|
3790
|
+
function isError(val) {
|
|
3791
|
+
return val instanceof Error;
|
|
3792
|
+
}
|
|
3793
|
+
error.isError = isError;
|
|
3794
|
+
function isntError(val) {
|
|
3795
|
+
return !isError(val);
|
|
3796
|
+
}
|
|
3797
|
+
error.isntError = isntError;
|
|
3798
|
+
|
|
3799
|
+
var falsy = {};
|
|
3800
|
+
|
|
3801
|
+
falsy.isntFalsy = falsy.isFalsy = void 0;
|
|
3802
|
+
function isFalsy(val) {
|
|
3803
|
+
return !val;
|
|
3804
|
+
}
|
|
3805
|
+
falsy.isFalsy = isFalsy;
|
|
3806
|
+
function isntFalsy(val) {
|
|
3807
|
+
return !isFalsy(val);
|
|
3808
|
+
}
|
|
3809
|
+
falsy.isntFalsy = isntFalsy;
|
|
3810
|
+
|
|
3811
|
+
var _function = {};
|
|
3812
|
+
|
|
3813
|
+
_function.isntFunction = _function.isFunction = void 0;
|
|
3814
|
+
function isFunction(val) {
|
|
3815
|
+
return typeof val === 'function';
|
|
3816
|
+
}
|
|
3817
|
+
_function.isFunction = isFunction;
|
|
3818
|
+
function isntFunction(val) {
|
|
3819
|
+
return !isFunction(val);
|
|
3820
|
+
}
|
|
3821
|
+
_function.isntFunction = isntFunction;
|
|
3822
|
+
|
|
3823
|
+
var iterable = {};
|
|
3824
|
+
|
|
3825
|
+
iterable.isntIterable = iterable.isIterable = void 0;
|
|
3826
|
+
const null_1 = _null;
|
|
3827
|
+
const undefined_1$1 = _undefined;
|
|
3828
|
+
function isIterable(val) {
|
|
3829
|
+
return (0, null_1.isntNull)(val)
|
|
3830
|
+
&& (0, undefined_1$1.isntUndefined)(val)
|
|
3831
|
+
&& typeof val[Symbol.iterator] === 'function';
|
|
3832
|
+
}
|
|
3833
|
+
iterable.isIterable = isIterable;
|
|
3834
|
+
function isntIterable(val) {
|
|
3835
|
+
return !isIterable(val);
|
|
3836
|
+
}
|
|
3837
|
+
iterable.isntIterable = isntIterable;
|
|
3838
|
+
|
|
3839
|
+
var jsonRpc = {};
|
|
3840
|
+
|
|
3841
|
+
var object = {};
|
|
3842
|
+
|
|
3843
|
+
object.isntEmptyObject = object.isEmptyObject = object.isRecord = object.isntObject = object.isObject = void 0;
|
|
3844
|
+
function isObject(val) {
|
|
3845
|
+
return val !== null && typeof val === 'object';
|
|
3846
|
+
}
|
|
3847
|
+
object.isObject = isObject;
|
|
3848
|
+
function isntObject(val) {
|
|
3849
|
+
return !isObject(val);
|
|
3850
|
+
}
|
|
3851
|
+
object.isntObject = isntObject;
|
|
3852
|
+
function isRecord(val) {
|
|
3853
|
+
return isObject(val);
|
|
3854
|
+
}
|
|
3855
|
+
object.isRecord = isRecord;
|
|
3856
|
+
function isEmptyObject(val) {
|
|
3857
|
+
return Object.keys(val).length === 0;
|
|
3858
|
+
}
|
|
3859
|
+
object.isEmptyObject = isEmptyObject;
|
|
3860
|
+
function isntEmptyObject(val) {
|
|
3861
|
+
return Object.keys(val).length !== 0;
|
|
3862
|
+
}
|
|
3863
|
+
object.isntEmptyObject = isntEmptyObject;
|
|
3864
|
+
|
|
3865
|
+
var number = {};
|
|
3866
|
+
|
|
3867
|
+
number.isntNumber = number.isNumber = void 0;
|
|
3868
|
+
function isNumber(val) {
|
|
3869
|
+
return typeof val === 'number';
|
|
3870
|
+
}
|
|
3871
|
+
number.isNumber = isNumber;
|
|
3872
|
+
function isntNumber(val) {
|
|
3873
|
+
return !isNumber(val);
|
|
3874
|
+
}
|
|
3875
|
+
number.isntNumber = isntNumber;
|
|
3876
|
+
|
|
3877
|
+
jsonRpc.isntJsonRpcError = jsonRpc.isJsonRpcError = jsonRpc.isntJsonRpcSuccess = jsonRpc.isJsonRpcSuccess = jsonRpc.isntJsonRpcRequest = jsonRpc.isJsonRpcRequest = jsonRpc.isntJsonRpcNotification = jsonRpc.isJsonRpcNotification = void 0;
|
|
3878
|
+
const array_1 = array;
|
|
3879
|
+
const object_1 = object;
|
|
3880
|
+
const string_1 = string;
|
|
3881
|
+
const number_1 = number;
|
|
3882
|
+
const undefined_1 = _undefined;
|
|
3883
|
+
function isJsonRpcId(val) {
|
|
3884
|
+
return (0, string_1.isString)(val) || (0, number_1.isNumber)(val);
|
|
3885
|
+
}
|
|
3886
|
+
function isJsonRpcParams(val) {
|
|
3887
|
+
return (0, array_1.isArray)(val) || (0, object_1.isObject)(val);
|
|
3888
|
+
}
|
|
3889
|
+
function isJsonRpcNotification(val) {
|
|
3890
|
+
return (0, object_1.isRecord)(val)
|
|
3891
|
+
&& (0, string_1.isString)(val.jsonrpc)
|
|
3892
|
+
&& (0, string_1.isString)(val.method)
|
|
3893
|
+
&& (0, undefined_1.isUndefined)(val.id)
|
|
3894
|
+
&& isJsonRpcParams(val.params);
|
|
3895
|
+
}
|
|
3896
|
+
jsonRpc.isJsonRpcNotification = isJsonRpcNotification;
|
|
3897
|
+
function isntJsonRpcNotification(val) {
|
|
3898
|
+
return !isJsonRpcNotification(val);
|
|
3899
|
+
}
|
|
3900
|
+
jsonRpc.isntJsonRpcNotification = isntJsonRpcNotification;
|
|
3901
|
+
function isJsonRpcRequest(val) {
|
|
3902
|
+
return (0, object_1.isRecord)(val)
|
|
3903
|
+
&& (0, string_1.isString)(val.jsonrpc)
|
|
3904
|
+
&& (0, string_1.isString)(val.method)
|
|
3905
|
+
&& isJsonRpcId(val.id)
|
|
3906
|
+
&& isJsonRpcParams(val.params);
|
|
3907
|
+
}
|
|
3908
|
+
jsonRpc.isJsonRpcRequest = isJsonRpcRequest;
|
|
3909
|
+
function isntJsonRpcRequest(val) {
|
|
3910
|
+
return !isJsonRpcRequest(val);
|
|
3911
|
+
}
|
|
3912
|
+
jsonRpc.isntJsonRpcRequest = isntJsonRpcRequest;
|
|
3913
|
+
function isJsonRpcSuccess(val) {
|
|
3914
|
+
return (0, object_1.isRecord)(val)
|
|
3915
|
+
&& (0, string_1.isString)(val.jsonrpc)
|
|
3916
|
+
&& (0, string_1.isString)(val.id)
|
|
3917
|
+
&& 'result' in val;
|
|
3918
|
+
}
|
|
3919
|
+
jsonRpc.isJsonRpcSuccess = isJsonRpcSuccess;
|
|
3920
|
+
function isntJsonRpcSuccess(val) {
|
|
3921
|
+
return !isJsonRpcSuccess(val);
|
|
3922
|
+
}
|
|
3923
|
+
jsonRpc.isntJsonRpcSuccess = isntJsonRpcSuccess;
|
|
3924
|
+
function isJsonRpcError(val) {
|
|
3925
|
+
return (0, object_1.isRecord)(val)
|
|
3926
|
+
&& (0, string_1.isString)(val.jsonrpc)
|
|
3927
|
+
&& isJsonRpcId(val.id)
|
|
3928
|
+
&& isJsonRpcErrorObject(val.error);
|
|
3929
|
+
}
|
|
3930
|
+
jsonRpc.isJsonRpcError = isJsonRpcError;
|
|
3931
|
+
function isntJsonRpcError(val) {
|
|
3932
|
+
return !isJsonRpcError(val);
|
|
3933
|
+
}
|
|
3934
|
+
jsonRpc.isntJsonRpcError = isntJsonRpcError;
|
|
3935
|
+
function isJsonRpcErrorObject(val) {
|
|
3936
|
+
return (0, object_1.isRecord)(val)
|
|
3937
|
+
&& (0, number_1.isNumber)(val.code)
|
|
3938
|
+
&& (0, string_1.isString)(val.message)
|
|
3939
|
+
&& ((0, undefined_1.isUndefined)(val.data) || (0, object_1.isObject)(val.data));
|
|
3940
|
+
}
|
|
3941
|
+
|
|
3942
|
+
var json = {};
|
|
3943
|
+
|
|
3944
|
+
json.isntJson = json.isJson = void 0;
|
|
3945
|
+
function isJson(val) {
|
|
3946
|
+
try {
|
|
3947
|
+
JSON.stringify(val);
|
|
3948
|
+
return true;
|
|
3949
|
+
}
|
|
3950
|
+
catch (_a) {
|
|
3951
|
+
return false;
|
|
3952
|
+
}
|
|
3953
|
+
}
|
|
3954
|
+
json.isJson = isJson;
|
|
3955
|
+
function isntJson(val) {
|
|
3956
|
+
return !isntJson();
|
|
3957
|
+
}
|
|
3958
|
+
json.isntJson = isntJson;
|
|
3959
|
+
|
|
3960
|
+
var url = {};
|
|
3961
|
+
|
|
3962
|
+
url.isAbsoluteURL = void 0;
|
|
3963
|
+
function isAbsoluteURL(str) {
|
|
3964
|
+
try {
|
|
3965
|
+
new URL(str);
|
|
3966
|
+
return true;
|
|
3967
|
+
}
|
|
3968
|
+
catch (_a) {
|
|
3969
|
+
return false;
|
|
3970
|
+
}
|
|
3971
|
+
}
|
|
3972
|
+
url.isAbsoluteURL = isAbsoluteURL;
|
|
3973
|
+
|
|
3974
|
+
(function (exports) {
|
|
3975
|
+
var __createBinding = (commonjsGlobal && commonjsGlobal.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3976
|
+
if (k2 === undefined) k2 = k;
|
|
3977
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
3978
|
+
}) : (function(o, m, k, k2) {
|
|
3979
|
+
if (k2 === undefined) k2 = k;
|
|
3980
|
+
o[k2] = m[k];
|
|
3981
|
+
}));
|
|
3982
|
+
var __exportStar = (commonjsGlobal && commonjsGlobal.__exportStar) || function(m, exports) {
|
|
3983
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
3984
|
+
};__exportStar(array, exports);
|
|
3985
|
+
__exportStar(asyncIterable, exports);
|
|
3986
|
+
__exportStar(bigint, exports);
|
|
3987
|
+
__exportStar(boolean, exports);
|
|
3988
|
+
__exportStar(char, exports);
|
|
3989
|
+
__exportStar(date, exports);
|
|
3990
|
+
__exportStar(_enum, exports);
|
|
3991
|
+
__exportStar(error, exports);
|
|
3992
|
+
__exportStar(falsy, exports);
|
|
3993
|
+
__exportStar(_function, exports);
|
|
3994
|
+
__exportStar(iterable, exports);
|
|
3995
|
+
__exportStar(jsonRpc, exports);
|
|
3996
|
+
__exportStar(json, exports);
|
|
3997
|
+
__exportStar(_null, exports);
|
|
3998
|
+
__exportStar(number, exports);
|
|
3999
|
+
__exportStar(object, exports);
|
|
4000
|
+
__exportStar(string, exports);
|
|
4001
|
+
__exportStar(_undefined, exports);
|
|
4002
|
+
__exportStar(url, exports);
|
|
4003
|
+
|
|
4004
|
+
}(es2018));
|
|
4005
|
+
|
|
4006
|
+
class ObservableFiniteStateMachine extends FiniteStateMachine {
|
|
4007
|
+
constructor() {
|
|
4008
|
+
super(...arguments);
|
|
4009
|
+
this.stateChanges = new Subject();
|
|
4010
|
+
}
|
|
4011
|
+
observeStateChanges() {
|
|
4012
|
+
return this.stateChanges;
|
|
4013
|
+
}
|
|
4014
|
+
/**
|
|
4015
|
+
* @throws {BadEventError}
|
|
4016
|
+
*/
|
|
4017
|
+
send(event) {
|
|
4018
|
+
const oldState = this.state;
|
|
4019
|
+
super.send(event);
|
|
4020
|
+
const newState = this.state;
|
|
4021
|
+
this.stateChanges.next({ event, oldState, newState });
|
|
4022
|
+
if (es2018.isEmptyObject(this.schema[newState])) {
|
|
4023
|
+
this.stateChanges.complete();
|
|
4024
|
+
}
|
|
4025
|
+
}
|
|
4026
|
+
}
|
|
4027
|
+
|
|
4028
|
+
exports.BadEventError = BadEventError;
|
|
4029
|
+
exports.Box = Box;
|
|
2868
4030
|
exports.Emitter = Emitter;
|
|
2869
4031
|
exports.ExpirableMap = ExpirableMap;
|
|
4032
|
+
exports.FiniteStateMachine = FiniteStateMachine;
|
|
2870
4033
|
exports.HashMap = HashMap;
|
|
2871
4034
|
exports.HashSet = HashSet;
|
|
2872
4035
|
exports.LRUMap = LRUMap;
|
|
4036
|
+
exports.ObservableFiniteStateMachine = ObservableFiniteStateMachine;
|
|
2873
4037
|
exports.Queue = Queue;
|
|
2874
4038
|
exports.TLRUMap = TLRUMap;
|
|
2875
4039
|
exports.TrieMap = TrieMap;
|