itee-validators 5.3.9 → 5.5.0
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/.czrc +6 -0
- package/CHANGELOG.md +20 -0
- package/builds/itee-validators.cjs.js +278 -277
- package/builds/itee-validators.cjs.js.map +1 -1
- package/builds/itee-validators.cjs.min.js +144 -144
- package/builds/itee-validators.esm.js +210 -205
- package/builds/itee-validators.esm.js.map +1 -1
- package/builds/itee-validators.esm.min.js +97 -97
- package/builds/itee-validators.iife.js +211 -207
- package/builds/itee-validators.iife.js.map +1 -1
- package/builds/itee-validators.iife.min.js +120 -120
- package/package.json +6 -10
- package/sources/cores/arrays/isArray.js +4 -4
- package/sources/cores/arrays/isArrayOfArray.js +2 -2
- package/sources/cores/arrays/isArrayOfBoolean.js +2 -2
- package/sources/cores/arrays/isArrayOfFunction.js +2 -2
- package/sources/cores/arrays/isArrayOfMultiElement.js +1 -1
- package/sources/cores/arrays/isArrayOfNull.js +2 -2
- package/sources/cores/arrays/isArrayOfNumber.js +2 -2
- package/sources/cores/arrays/isArrayOfObject.js +2 -2
- package/sources/cores/arrays/isArrayOfSingleElement.js +1 -1
- package/sources/cores/arrays/isArrayOfString.js +3 -3
- package/sources/cores/arrays/isArrayOfUndefined.js +2 -2
- package/sources/cores/arrays/isEmptyArray.js +2 -2
- package/sources/cores/booleans/isBoolean.js +4 -4
- package/sources/cores/booleans/isTrue.js +2 -2
- package/sources/cores/cores.js +91 -91
- package/sources/cores/functions/isFunction.js +2 -2
- package/sources/cores/numbers/isInfinite.js +13 -19
- package/sources/cores/numbers/isMax.js +2 -2
- package/sources/cores/numbers/isMin.js +2 -2
- package/sources/cores/numbers/isNumber.js +15 -15
- package/sources/cores/numbers/isSafeInteger.js +2 -2
- package/sources/cores/numbers/isZero.js +3 -3
- package/sources/cores/objects/isEmptyObject.js +2 -2
- package/sources/cores/objects/isObject.js +2 -2
- package/sources/cores/strings/isBlankString.js +2 -2
- package/sources/cores/strings/isEmptyString.js +2 -2
- package/sources/cores/strings/isString.js +7 -7
- package/sources/cores/symbols/isSymbol.js +2 -2
- package/sources/cores/tests/isTestUnitGenerator.js +10 -10
- package/sources/cores/typed-arrays/isArrayBuffer.js +2 -2
- package/sources/cores/typed-arrays/isBigInt64Array.js +2 -2
- package/sources/cores/typed-arrays/isBigUint64Array.js +2 -2
- package/sources/cores/typed-arrays/isFloat32Array.js +2 -2
- package/sources/cores/typed-arrays/isFloat64Array.js +2 -2
- package/sources/cores/typed-arrays/isInt16Array.js +2 -2
- package/sources/cores/typed-arrays/isInt32Array.js +2 -2
- package/sources/cores/typed-arrays/isInt8Array.js +2 -2
- package/sources/cores/typed-arrays/isUint16Array.js +2 -2
- package/sources/cores/typed-arrays/isUint32Array.js +2 -2
- package/sources/cores/typed-arrays/isUint8Array.js +2 -2
- package/sources/cores/typed-arrays/isUint8ClampedArray.js +2 -2
- package/sources/cores/voids/isDefined.js +2 -2
- package/sources/cores/voids/isEmpty.js +2 -2
- package/sources/cores/voids/isNull.js +3 -3
- package/sources/cores/voids/isUndefined.js +2 -2
- package/sources/dom/isEventTarget.js +2 -2
- package/sources/file-system/block-devices/isBlockDevicePath.js +9 -9
- package/sources/file-system/block-devices/isValidBlockDevicePath.js +2 -2
- package/sources/file-system/character-devices/isCharacterDevicePath.js +9 -9
- package/sources/file-system/character-devices/isValidCharacterDevicePath.js +2 -2
- package/sources/file-system/directories/isDirectoryPath.js +9 -9
- package/sources/file-system/directories/isEmptyDirectory.js +4 -4
- package/sources/file-system/directories/isValidDirectoryPath.js +2 -2
- package/sources/file-system/fifo-pipes/isFIFOPath.js +9 -9
- package/sources/file-system/fifo-pipes/isValidFIFOPath.js +2 -2
- package/sources/file-system/files/isEmptyFile.js +9 -9
- package/sources/file-system/files/isFilePath.js +9 -9
- package/sources/file-system/files/isValidFilePath.js +2 -2
- package/sources/file-system/paths/isValidPath.js +4 -4
- package/sources/file-system/sockets/isSocketPath.js +9 -9
- package/sources/file-system/sockets/isValidSocketPath.js +2 -2
- package/sources/file-system/symbolic-links/isSymbolicLinkPath.js +9 -9
- package/sources/file-system/symbolic-links/isValidSymbolicLinkPath.js +2 -2
- package/sources/itee-validators.js +1 -14
- package/sources/physics/temperatures/isCelsius.js +2 -2
- package/sources/physics/temperatures/isFahrenheit.js +2 -2
- package/sources/physics/temperatures/isKelvin.js +2 -2
- package/sources/physics/temperatures/isTemperature.js +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var r=require("fs");
|
|
2
2
|
/**
|
|
3
3
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
4
4
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
* //...
|
|
16
16
|
* }
|
|
17
17
|
*
|
|
18
|
-
*/function
|
|
18
|
+
*/function t(r){return Array.isArray(r)}function n(r){return!Array.isArray(r)}
|
|
19
19
|
/**
|
|
20
20
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
21
21
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
* //...
|
|
33
33
|
* }
|
|
34
34
|
*
|
|
35
|
-
*/function
|
|
35
|
+
*/function e(r){return!n(r)&&0===r.length}
|
|
36
36
|
/**
|
|
37
37
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
38
38
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
* }
|
|
51
51
|
*
|
|
52
52
|
*/
|
|
53
|
-
function
|
|
53
|
+
function i(r){return"boolean"==typeof r}function o(r){return"boolean"!=typeof r}
|
|
54
54
|
/**
|
|
55
55
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
56
56
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -85,7 +85,7 @@ function o(t){return"boolean"==typeof t}function u(t){return"boolean"!=typeof t}
|
|
|
85
85
|
* }
|
|
86
86
|
*
|
|
87
87
|
*/
|
|
88
|
-
function
|
|
88
|
+
function u(r){return"function"==typeof r}function s(r){return"function"!=typeof r}
|
|
89
89
|
/**
|
|
90
90
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
91
91
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -102,7 +102,7 @@ function s(t){return"function"==typeof t}function f(t){return"function"!=typeof
|
|
|
102
102
|
* //...
|
|
103
103
|
* }
|
|
104
104
|
*
|
|
105
|
-
*/function
|
|
105
|
+
*/function f(r){return null!==r}
|
|
106
106
|
/**
|
|
107
107
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
108
108
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -136,7 +136,7 @@ function s(t){return"function"==typeof t}function f(t){return"function"!=typeof
|
|
|
136
136
|
* }
|
|
137
137
|
*
|
|
138
138
|
*/
|
|
139
|
-
function
|
|
139
|
+
function a(r){return null!=r}function c(r){return null==r}
|
|
140
140
|
/**
|
|
141
141
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
142
142
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -153,7 +153,7 @@ function c(t){return null!=t}function p(t){return null==t}
|
|
|
153
153
|
* //...
|
|
154
154
|
* }
|
|
155
155
|
*
|
|
156
|
-
*/function
|
|
156
|
+
*/function p(r){return r===Number.NEGATIVE_INFINITY}function l(r){return r===Number.POSITIVE_INFINITY}function y(r){return p(r)||l(r)}function x(r){return 0===r&&1/r===Number.POSITIVE_INFINITY}
|
|
157
157
|
/**
|
|
158
158
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
159
159
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -171,7 +171,7 @@ function c(t){return null!=t}function p(t){return null==t}
|
|
|
171
171
|
* }
|
|
172
172
|
*
|
|
173
173
|
*/
|
|
174
|
-
function
|
|
174
|
+
function h(r){return!c(r)&&r.constructor===Number}function N(r){return!h(r)}function A(r){return Number.isInteger(r)}function d(r){return!N(r)&&(!Number.isNaN(r)&&(!y(r)&&r%1!=0))}
|
|
175
175
|
/**
|
|
176
176
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
177
177
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -189,7 +189,7 @@ function N(t){return!p(t)&&t.constructor===Number}function h(t){return!N(t)}func
|
|
|
189
189
|
* }
|
|
190
190
|
*
|
|
191
191
|
*/
|
|
192
|
-
function I(
|
|
192
|
+
function I(r){return!c(r)&&r.constructor===Object}function E(r){return!I(r)}
|
|
193
193
|
/**
|
|
194
194
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
195
195
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -224,7 +224,7 @@ function I(t){return!p(t)&&t.constructor===Object}function E(t){return!I(t)}
|
|
|
224
224
|
* }
|
|
225
225
|
*
|
|
226
226
|
*/
|
|
227
|
-
function
|
|
227
|
+
function g(r){return"string"==typeof r||r instanceof String}function v(r){return!g(r)}
|
|
228
228
|
/**
|
|
229
229
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
230
230
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -241,7 +241,7 @@ function b(t){return"string"==typeof t||t instanceof String}function g(t){return
|
|
|
241
241
|
* //...
|
|
242
242
|
* }
|
|
243
243
|
*
|
|
244
|
-
*/function
|
|
244
|
+
*/function b(r){return void 0!==r}
|
|
245
245
|
/**
|
|
246
246
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
247
247
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -276,7 +276,7 @@ function b(t){return"string"==typeof t||t instanceof String}function g(t){return
|
|
|
276
276
|
* }
|
|
277
277
|
*
|
|
278
278
|
*/
|
|
279
|
-
function m(
|
|
279
|
+
function m(r){if(E(r))return!1;if(0===r.length)return!0;for(let t in r)if(Object.prototype.hasOwnProperty.call(r,t))return!1;return!0}
|
|
280
280
|
/**
|
|
281
281
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
282
282
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -294,7 +294,7 @@ function m(t){if(E(t))return!1;if(0===t.length)return!0;for(let r in t)if(Object
|
|
|
294
294
|
* }
|
|
295
295
|
*
|
|
296
296
|
*/
|
|
297
|
-
function S(
|
|
297
|
+
function S(r){return!v(r)&&0===r.length}
|
|
298
298
|
/**
|
|
299
299
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
300
300
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -312,7 +312,7 @@ function S(t){return!g(t)&&0===t.length}
|
|
|
312
312
|
* }
|
|
313
313
|
*
|
|
314
314
|
*/
|
|
315
|
-
function
|
|
315
|
+
function w(r){return!v(r)&&(!S(r)&&!/\S/.test(r))}
|
|
316
316
|
/**
|
|
317
317
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
318
318
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -330,7 +330,7 @@ function F(t){return!g(t)&&(!S(t)&&!/\S/.test(t))}
|
|
|
330
330
|
* }
|
|
331
331
|
*
|
|
332
332
|
*/
|
|
333
|
-
function
|
|
333
|
+
function F(r){return"symbol"==typeof r}
|
|
334
334
|
/**
|
|
335
335
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
336
336
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -348,7 +348,7 @@ function w(t){return"symbol"==typeof t}
|
|
|
348
348
|
* }
|
|
349
349
|
*
|
|
350
350
|
*/
|
|
351
|
-
function O(
|
|
351
|
+
function O(r){return!c(r)&&(!!S(r)||(!!e(r)||!!m(r)))}
|
|
352
352
|
/**
|
|
353
353
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
354
354
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -363,118 +363,118 @@ function O(t){return!p(t)&&(!!S(t)||(!!i(t)||!!m(t)))}
|
|
|
363
363
|
// Usefull when a simple data structure is used multiple times
|
|
364
364
|
validator.add( 'ColorType', color => {
|
|
365
365
|
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
366
|
+
const r = color.r
|
|
367
|
+
if ( color.r === undefined || Itee.Validators.isNotNumber( r ) ) {
|
|
368
|
+
return false
|
|
369
|
+
}
|
|
370
370
|
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
371
|
+
const g = color.g
|
|
372
|
+
if ( color.g === undefined || Itee.Validators.isNotNumber( g ) ) {
|
|
373
|
+
return false
|
|
374
|
+
}
|
|
375
375
|
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
376
|
+
const b = color.b
|
|
377
|
+
if ( color.b === undefined || Itee.Validators.isNotNumber( b ) ) {
|
|
378
|
+
return false
|
|
379
|
+
}
|
|
380
380
|
|
|
381
|
-
|
|
382
|
-
|
|
381
|
+
return true
|
|
382
|
+
} )
|
|
383
383
|
|
|
384
384
|
// Using schema composition
|
|
385
385
|
// Usefull for design validation schema faster and based on previous declared validation types
|
|
386
386
|
validator.add( 'Range_0_255', ( value ) => {
|
|
387
387
|
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
388
|
+
if ( Itee.Validators.isNotNumber( value ) ) {
|
|
389
|
+
return false
|
|
390
|
+
}
|
|
391
391
|
|
|
392
|
-
|
|
392
|
+
return !(value <= 0 || value > 255)
|
|
393
393
|
|
|
394
|
-
|
|
394
|
+
} )
|
|
395
395
|
|
|
396
396
|
validator.add( 'ColorSchema', {
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
397
|
+
r: {
|
|
398
|
+
required: true,
|
|
399
|
+
type: 'Range_0_255'
|
|
400
|
+
},
|
|
401
|
+
g: {
|
|
402
|
+
required: true,
|
|
403
|
+
type: 'Range_0_255'
|
|
404
|
+
},
|
|
405
|
+
b: {
|
|
406
|
+
required: true,
|
|
407
|
+
type: 'Range_0_255'
|
|
408
|
+
}
|
|
409
|
+
} )
|
|
410
410
|
|
|
411
411
|
validator.add( 'ColorStructure', {
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
412
|
+
color_from_type: {
|
|
413
|
+
type: 'ColorType'
|
|
414
|
+
},
|
|
415
|
+
col_from_schema: {
|
|
416
|
+
type: 'ColorSchema'
|
|
417
|
+
},
|
|
418
|
+
col_from_fn: {
|
|
419
|
+
// Inner function
|
|
420
|
+
// Usefull for specific validation requirement that cannot match other previous validation schema or type
|
|
421
|
+
fn: function ColorValidator ( color ) {
|
|
422
422
|
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
423
|
+
const r = color.r
|
|
424
|
+
if ( color.r === undefined || Itee.Validators.isNotNumber( r ) ) {
|
|
425
|
+
return false
|
|
426
|
+
}
|
|
427
427
|
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
428
|
+
const g = color.g
|
|
429
|
+
if ( color.g === undefined || Itee.Validators.isNotNumber( g ) ) {
|
|
430
|
+
return false
|
|
431
|
+
}
|
|
432
432
|
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
433
|
+
const b = color.b
|
|
434
|
+
if ( color.b === undefined || Itee.Validators.isNotNumber( b ) ) {
|
|
435
|
+
return false
|
|
436
|
+
}
|
|
437
437
|
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
438
|
+
return true
|
|
439
|
+
}
|
|
440
|
+
}
|
|
441
|
+
} )
|
|
442
442
|
|
|
443
443
|
// The data to validate
|
|
444
444
|
const colorStruct = {
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
445
|
+
color_from_type: {
|
|
446
|
+
r: 0,
|
|
447
|
+
g: 1,
|
|
448
|
+
b: 2
|
|
449
|
+
},
|
|
450
|
+
col_from_schema: {
|
|
451
|
+
r: 10,
|
|
452
|
+
g: 20,
|
|
453
|
+
b: 30
|
|
454
|
+
},
|
|
455
|
+
col_from_fn: {
|
|
456
|
+
r: 0,
|
|
457
|
+
g: 127,
|
|
458
|
+
b: 255
|
|
459
|
+
}
|
|
460
|
+
}
|
|
461
461
|
|
|
462
462
|
// Execute
|
|
463
463
|
|
|
464
464
|
try {
|
|
465
465
|
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
466
|
+
if ( validator.check( colorStruct, 'ColorStructure' ) ) {
|
|
467
|
+
alert( 'ColorStructure is valid !' )
|
|
468
|
+
} else {
|
|
469
|
+
alert( validator.errors )
|
|
470
|
+
}
|
|
471
471
|
|
|
472
|
-
} catch ( err ) {
|
|
473
|
-
|
|
474
|
-
}
|
|
472
|
+
} catch ( err ) {
|
|
473
|
+
alert( err )
|
|
474
|
+
}
|
|
475
475
|
*
|
|
476
476
|
*/
|
|
477
|
-
class P{constructor(){this.validators={Boolean:
|
|
477
|
+
class P{constructor(){this.validators={Boolean:i,Number:h,Integer:A,Float:d,Array:t,String:g,Object:I,Symbol:F,Function:u},this.errors=[]}add(r,t){if(v(r))throw new TypeError("Validator: Expect type to be a string");if(s(t)&&E(t))throw new TypeError("Validator: Expect validator to be an object or a function");if(a(this.validators[r]))throw new TypeError(`Validator: a validator is already defined for type '${r}'`);this.validators[r]=t}remove(r){delete this.validators[r]}getAvalaibleTypes(){const r=[];for(let t in this.validators)r.push(t);return r}check(r,t,n=!0){const e=this.validators[t];if(c(e))throw new TypeError(`Validator: Unable to find schema validation of type '${t}'`);let i=!0;if(u(e))i=e(r);else{if(!I(e))throw new TypeError(`Validator: Unknown validator of type '${t}'`);{let o=!0;for(let u in e){const f=e[u];if(c(f))throw new TypeError(`Validator: Missing validator for key '${u}' of type '${t}'`);const p=r[u],l=f.required;if(c(p)){if(!l)continue;o=!1}let y=f.fn;if(a(y)){if(s(y))throw new TypeError(`Validator: Invalid validation function for '${u}' with type '${t}'`);o=y(p)}else o=this.check(p,f.type,n);if(!1===o&&(this.errors.push(`Validator: Invalid property '${u}' of type '${f.type}' with value '${p}' in object of type '${t}'`),i=!1,n))break}}}return i}}
|
|
478
478
|
/**
|
|
479
479
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
480
480
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -492,7 +492,7 @@ class P{constructor(){this.validators={Boolean:o,Number:N,Integer:d,Float:A,Arra
|
|
|
492
492
|
* }
|
|
493
493
|
*
|
|
494
494
|
*/
|
|
495
|
-
function U(
|
|
495
|
+
function U(r){return r instanceof ArrayBuffer}
|
|
496
496
|
/**
|
|
497
497
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
498
498
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -510,7 +510,7 @@ function U(t){return t instanceof ArrayBuffer}
|
|
|
510
510
|
* }
|
|
511
511
|
*
|
|
512
512
|
*/
|
|
513
|
-
function T(
|
|
513
|
+
function T(r){return r instanceof BigInt64Array}
|
|
514
514
|
/**
|
|
515
515
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
516
516
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -528,7 +528,7 @@ function T(t){return t instanceof BigInt64Array}
|
|
|
528
528
|
* }
|
|
529
529
|
*
|
|
530
530
|
*/
|
|
531
|
-
function B(
|
|
531
|
+
function B(r){return r instanceof BigUint64Array}
|
|
532
532
|
/**
|
|
533
533
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
534
534
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -546,7 +546,7 @@ function B(t){return t instanceof BigUint64Array}
|
|
|
546
546
|
* }
|
|
547
547
|
*
|
|
548
548
|
*/
|
|
549
|
-
function V(
|
|
549
|
+
function V(r){return r instanceof Float32Array}
|
|
550
550
|
/**
|
|
551
551
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
552
552
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -564,7 +564,7 @@ function V(t){return t instanceof Float32Array}
|
|
|
564
564
|
* }
|
|
565
565
|
*
|
|
566
566
|
*/
|
|
567
|
-
function k(
|
|
567
|
+
function k(r){return r instanceof Float64Array}
|
|
568
568
|
/**
|
|
569
569
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
570
570
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -582,7 +582,7 @@ function k(t){return t instanceof Float64Array}
|
|
|
582
582
|
* }
|
|
583
583
|
*
|
|
584
584
|
*/
|
|
585
|
-
function L(
|
|
585
|
+
function L(r){return r instanceof Int16Array}
|
|
586
586
|
/**
|
|
587
587
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
588
588
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -600,7 +600,7 @@ function L(t){return t instanceof Int16Array}
|
|
|
600
600
|
* }
|
|
601
601
|
*
|
|
602
602
|
*/
|
|
603
|
-
function _(
|
|
603
|
+
function _(r){return r instanceof Int32Array}
|
|
604
604
|
/**
|
|
605
605
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
606
606
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -618,7 +618,7 @@ function _(t){return t instanceof Int32Array}
|
|
|
618
618
|
* }
|
|
619
619
|
*
|
|
620
620
|
*/
|
|
621
|
-
function D(
|
|
621
|
+
function D(r){return r instanceof Int8Array}
|
|
622
622
|
/**
|
|
623
623
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
624
624
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -636,7 +636,7 @@ function D(t){return t instanceof Int8Array}
|
|
|
636
636
|
* }
|
|
637
637
|
*
|
|
638
638
|
*/
|
|
639
|
-
function M(
|
|
639
|
+
function M(r){return r instanceof Uint16Array}
|
|
640
640
|
/**
|
|
641
641
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
642
642
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -654,7 +654,7 @@ function M(t){return t instanceof Uint16Array}
|
|
|
654
654
|
* }
|
|
655
655
|
*
|
|
656
656
|
*/
|
|
657
|
-
function R(
|
|
657
|
+
function R(r){return r instanceof Uint32Array}
|
|
658
658
|
/**
|
|
659
659
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
660
660
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -672,7 +672,7 @@ function R(t){return t instanceof Uint32Array}
|
|
|
672
672
|
* }
|
|
673
673
|
*
|
|
674
674
|
*/
|
|
675
|
-
function j(
|
|
675
|
+
function j(r){return r instanceof Uint8Array}
|
|
676
676
|
/**
|
|
677
677
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
678
678
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -690,7 +690,7 @@ function j(t){return t instanceof Uint8Array}
|
|
|
690
690
|
* }
|
|
691
691
|
*
|
|
692
692
|
*/
|
|
693
|
-
function C(
|
|
693
|
+
function C(r){return r instanceof Uint8ClampedArray}exports.Validator=void 0,c(exports.Validator)&&(exports.Validator=new P);
|
|
694
694
|
/**
|
|
695
695
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
696
696
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -708,7 +708,7 @@ function C(t){return t instanceof Uint8ClampedArray}exports.Validator=void 0,p(e
|
|
|
708
708
|
* }
|
|
709
709
|
*
|
|
710
710
|
*/
|
|
711
|
-
function $(
|
|
711
|
+
function $(r){return h(r)&&r>=-273.14999999955}function Z(r){return!$(r)}
|
|
712
712
|
/**
|
|
713
713
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
714
714
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -725,7 +725,7 @@ function $(t){return N(t)&&t>=-273.14999999955}function Z(t){return!$(t)}
|
|
|
725
725
|
* //...
|
|
726
726
|
* }
|
|
727
727
|
*
|
|
728
|
-
*/function G(
|
|
728
|
+
*/function G(r){return h(r)&&r>=-459.67}function Y(r){return!G(r)}
|
|
729
729
|
/**
|
|
730
730
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
731
731
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -742,7 +742,7 @@ function $(t){return N(t)&&t>=-273.14999999955}function Z(t){return!$(t)}
|
|
|
742
742
|
* //...
|
|
743
743
|
* }
|
|
744
744
|
*
|
|
745
|
-
*/function K(
|
|
745
|
+
*/function K(r){return h(r)&&r>=4.5e-10}function X(r){return!K(r)}
|
|
746
746
|
/**
|
|
747
747
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
748
748
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -780,7 +780,7 @@ function $(t){return N(t)&&t>=-273.14999999955}function Z(t){return!$(t)}
|
|
|
780
780
|
* }
|
|
781
781
|
*
|
|
782
782
|
*/
|
|
783
|
-
function q(t){if(
|
|
783
|
+
function q(t){if(v(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new TypeError("Invalid path type! Expect string, buffer or url.");const n=r.statSync(t,{throwIfNoEntry:!1});return a(n)&&n.isBlockDevice()}
|
|
784
784
|
/**
|
|
785
785
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
786
786
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -801,7 +801,7 @@ function q(t){if(g(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new Typ
|
|
|
801
801
|
* }
|
|
802
802
|
*
|
|
803
803
|
*/
|
|
804
|
-
function H(t){return r.
|
|
804
|
+
function H(t){return r.existsSync(t)}
|
|
805
805
|
/**
|
|
806
806
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
807
807
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -819,7 +819,7 @@ function H(t){return r.default.existsSync(t)}
|
|
|
819
819
|
* }
|
|
820
820
|
*
|
|
821
821
|
*/
|
|
822
|
-
function z(
|
|
822
|
+
function z(r){return H(r)&&q(r)}
|
|
823
823
|
/**
|
|
824
824
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
825
825
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -840,7 +840,7 @@ function z(t){return H(t)&&q(t)}
|
|
|
840
840
|
* }
|
|
841
841
|
*
|
|
842
842
|
*/
|
|
843
|
-
function J(t){if(
|
|
843
|
+
function J(t){if(v(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new TypeError("Invalid path type! Expect string, buffer or url.");const n=r.statSync(t,{throwIfNoEntry:!1});return a(n)&&n.isCharacterDevice()}
|
|
844
844
|
/**
|
|
845
845
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
846
846
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -858,7 +858,7 @@ function J(t){if(g(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new Typ
|
|
|
858
858
|
* }
|
|
859
859
|
*
|
|
860
860
|
*/
|
|
861
|
-
function Q(
|
|
861
|
+
function Q(r){return H(r)&&J(r)}
|
|
862
862
|
/**
|
|
863
863
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
864
864
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -879,7 +879,7 @@ function Q(t){return H(t)&&J(t)}
|
|
|
879
879
|
* }
|
|
880
880
|
*
|
|
881
881
|
*/
|
|
882
|
-
function W(t){if(
|
|
882
|
+
function W(t){if(v(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new TypeError("Invalid path type! Expect string, buffer or url.");const n=r.statSync(t,{throwIfNoEntry:!1});return a(n)&&n.isDirectory()}
|
|
883
883
|
/**
|
|
884
884
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
885
885
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -900,7 +900,7 @@ function W(t){if(g(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new Typ
|
|
|
900
900
|
* }
|
|
901
901
|
*
|
|
902
902
|
*/
|
|
903
|
-
function
|
|
903
|
+
function rr(t){return W(t)&&0===r.readdirSync(t).length}
|
|
904
904
|
/**
|
|
905
905
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
906
906
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -918,7 +918,7 @@ function tt(t){return W(t)&&0===r.default.readdirSync(t).length}
|
|
|
918
918
|
* }
|
|
919
919
|
*
|
|
920
920
|
*/
|
|
921
|
-
function
|
|
921
|
+
function tr(r){return H(r)&&W(r)}
|
|
922
922
|
/**
|
|
923
923
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
924
924
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -939,7 +939,7 @@ function rt(t){return H(t)&&W(t)}
|
|
|
939
939
|
* }
|
|
940
940
|
*
|
|
941
941
|
*/
|
|
942
|
-
function
|
|
942
|
+
function nr(t){if(v(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new TypeError("Invalid path type! Expect string, buffer or url.");const n=r.statSync(t,{throwIfNoEntry:!1});return a(n)&&n.isFIFO()}
|
|
943
943
|
/**
|
|
944
944
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
945
945
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -960,7 +960,7 @@ function nt(t){if(g(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new Ty
|
|
|
960
960
|
* }
|
|
961
961
|
*
|
|
962
962
|
*/
|
|
963
|
-
function
|
|
963
|
+
function er(r){return H(r)&&nr(r)}
|
|
964
964
|
/**
|
|
965
965
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
966
966
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -981,7 +981,7 @@ function et(t){return H(t)&&nt(t)}
|
|
|
981
981
|
* }
|
|
982
982
|
*
|
|
983
983
|
*/
|
|
984
|
-
function
|
|
984
|
+
function ir(t){if(v(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new TypeError("Invalid path type! Expect string, buffer or url.");const n=r.statSync(t,{throwIfNoEntry:!1});return a(n)&&n.isFile()}
|
|
985
985
|
/**
|
|
986
986
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
987
987
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1002,7 +1002,7 @@ function it(t){if(g(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new Ty
|
|
|
1002
1002
|
* }
|
|
1003
1003
|
*
|
|
1004
1004
|
*/
|
|
1005
|
-
function
|
|
1005
|
+
function or(t,n=0){if(v(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new TypeError("Invalid path type! Expect string, buffer or url.");return ir(t)&&r.statSync(t).size<=n}
|
|
1006
1006
|
/**
|
|
1007
1007
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1008
1008
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1020,7 +1020,7 @@ function ot(t,n=0){if(g(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw ne
|
|
|
1020
1020
|
* }
|
|
1021
1021
|
*
|
|
1022
1022
|
*/
|
|
1023
|
-
function
|
|
1023
|
+
function ur(r){return H(r)&&ir(r)}
|
|
1024
1024
|
/**
|
|
1025
1025
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1026
1026
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1041,7 +1041,7 @@ function ut(t){return H(t)&&it(t)}
|
|
|
1041
1041
|
* }
|
|
1042
1042
|
*
|
|
1043
1043
|
*/
|
|
1044
|
-
function
|
|
1044
|
+
function sr(t){if(v(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new TypeError("Invalid path type! Expect string, buffer or url.");const n=r.statSync(t,{throwIfNoEntry:!1});return a(n)&&n.isSocket()}
|
|
1045
1045
|
/**
|
|
1046
1046
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1047
1047
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1059,7 +1059,7 @@ function st(t){if(g(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new Ty
|
|
|
1059
1059
|
* }
|
|
1060
1060
|
*
|
|
1061
1061
|
*/
|
|
1062
|
-
function
|
|
1062
|
+
function fr(r){return H(r)&&sr(r)}
|
|
1063
1063
|
/**
|
|
1064
1064
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1065
1065
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1080,7 +1080,7 @@ function ft(t){return H(t)&&st(t)}
|
|
|
1080
1080
|
* }
|
|
1081
1081
|
*
|
|
1082
1082
|
*/
|
|
1083
|
-
function
|
|
1083
|
+
function ar(t){if(v(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new TypeError("Invalid path type! Expect string, buffer or url.");const n=r.statSync(t,{throwIfNoEntry:!1});return a(n)&&n.isSymbolicLink()}
|
|
1084
1084
|
/**
|
|
1085
1085
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1086
1086
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1098,7 +1098,7 @@ function at(t){if(g(t)&&!(t instanceof Buffer)&&!(t instanceof URL))throw new Ty
|
|
|
1098
1098
|
* }
|
|
1099
1099
|
*
|
|
1100
1100
|
*/
|
|
1101
|
-
function
|
|
1101
|
+
function cr(r){return H(r)&&ar(r)}exports.ABSOLUTE_ZERO_CELSIUS=-273.14999999955,exports.ABSOLUTE_ZERO_FAHRENHEIT=-459.67,exports.ABSOLUTE_ZERO_KELVIN=4.5e-10,exports.isArray=t,exports.isArrayBuffer=U,exports.isArrayOfArray=
|
|
1102
1102
|
/**
|
|
1103
1103
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1104
1104
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1116,7 +1116,7 @@ function ct(t){return H(t)&&at(t)}exports.ABSOLUTE_ZERO_CELSIUS=-273.14999999955
|
|
|
1116
1116
|
* }
|
|
1117
1117
|
*
|
|
1118
1118
|
*/
|
|
1119
|
-
function(
|
|
1119
|
+
function(r){if(n(r))return!1;if(e(r))return!1;for(let t=0,e=r.length;t<e;t++)if(n(r[t]))return!1;return!0},exports.isArrayOfBoolean=function(r){if(n(r))return!1;if(e(r))return!1;for(let t=0,n=r.length;t<n;t++)if(o(r[t]))return!1;return!0},exports.isArrayOfFunction=function(r){if(n(r))return!1;if(e(r))return!1;for(let t=0,n=r.length;t<n;t++)if(s(r[t]))return!1;return!0},exports.isArrayOfMultiElement=
|
|
1120
1120
|
/**
|
|
1121
1121
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1122
1122
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1134,7 +1134,7 @@ function(t){if(e(t))return!1;if(i(t))return!1;for(let r=0,n=t.length;r<n;r++)if(
|
|
|
1134
1134
|
* }
|
|
1135
1135
|
*
|
|
1136
1136
|
*/
|
|
1137
|
-
function(
|
|
1137
|
+
function(r){return!n(r)&&r.length>1}
|
|
1138
1138
|
/**
|
|
1139
1139
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1140
1140
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1151,7 +1151,7 @@ function(t){return!e(t)&&t.length>1}
|
|
|
1151
1151
|
* //...
|
|
1152
1152
|
* }
|
|
1153
1153
|
*
|
|
1154
|
-
*/,exports.isArrayOfNull=function(
|
|
1154
|
+
*/,exports.isArrayOfNull=function(r){if(n(r))return!1;if(e(r))return!1;for(let t=0,n=r.length;t<n;t++)if(f(r[t]))return!1;return!0},exports.isArrayOfNumber=
|
|
1155
1155
|
/**
|
|
1156
1156
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1157
1157
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1169,7 +1169,7 @@ function(t){return!e(t)&&t.length>1}
|
|
|
1169
1169
|
* }
|
|
1170
1170
|
*
|
|
1171
1171
|
*/
|
|
1172
|
-
function(
|
|
1172
|
+
function(r){if(n(r))return!1;if(e(r))return!1;for(let t=0,n=r.length;t<n;t++)if(N(r[t]))return!1;return!0},exports.isArrayOfObject=function(r){if(n(r))return!1;if(e(r))return!1;for(let t=0,n=r.length;t<n;t++)if(E(r[t]))return!1;return!0},exports.isArrayOfSingleElement=
|
|
1173
1173
|
/**
|
|
1174
1174
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1175
1175
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1187,7 +1187,7 @@ function(t){if(e(t))return!1;if(i(t))return!1;for(let r=0,n=t.length;r<n;r++)if(
|
|
|
1187
1187
|
* }
|
|
1188
1188
|
*
|
|
1189
1189
|
*/
|
|
1190
|
-
function(
|
|
1190
|
+
function(r){return!n(r)&&1===r.length},exports.isArrayOfString=function(r){if(n(r))return!1;if(e(r))return!1;for(let t=0,n=r.length;t<n;t++)if(v(r[t]))return!1;return!0},exports.isArrayOfUndefined=function(r){if(n(r))return!1;if(e(r))return!1;for(let t=0,n=r.length;t<n;t++)if(b(r[t]))return!1;return!0},exports.isBigInt64Array=T,exports.isBigUint64Array=B,exports.isBlankString=w,exports.isBlockDevicePath=q,exports.isBoolean=i,exports.isCelsius=$,exports.isCharacterDevicePath=J,exports.isDefined=a,exports.isDirectoryPath=W,exports.isEmpty=O,exports.isEmptyArray=e,exports.isEmptyDirectory=rr,exports.isEmptyFile=or,exports.isEmptyObject=m,exports.isEmptyString=S,exports.isFIFOPath=nr,exports.isFahrenheit=G,exports.isFalse=function(r){return i(r)&&!1===r}
|
|
1191
1191
|
/**
|
|
1192
1192
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1193
1193
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1204,7 +1204,7 @@ function(t){return!e(t)&&1===t.length},exports.isArrayOfString=function(t){if(e(
|
|
|
1204
1204
|
* //...
|
|
1205
1205
|
* }
|
|
1206
1206
|
*
|
|
1207
|
-
*/,exports.isFilePath=
|
|
1207
|
+
*/,exports.isFilePath=ir,exports.isFinite=function(r){return Number.isFinite(r)}
|
|
1208
1208
|
/**
|
|
1209
1209
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1210
1210
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1221,7 +1221,7 @@ function(t){return!e(t)&&1===t.length},exports.isArrayOfString=function(t){if(e(
|
|
|
1221
1221
|
* //...
|
|
1222
1222
|
* }
|
|
1223
1223
|
*
|
|
1224
|
-
*/,exports.isFloat=
|
|
1224
|
+
*/,exports.isFloat=d,exports.isFloat32Array=V,exports.isFloat64Array=k,exports.isFunction=u,exports.isInfinite=y,exports.isInfiniteNegative=p,exports.isInfinitePositive=l,exports.isInt16Array=L,exports.isInt32Array=_,exports.isInt8Array=D,exports.isInteger=A,exports.isInvalidBlockDevicePath=function(r){return!z(r)},exports.isInvalidCharacterDevicePath=function(r){return!Q(r)},exports.isInvalidDirectoryPath=function(r){return!tr(r)},exports.isInvalidFIFOPath=function(r){return!er(r)},exports.isInvalidFilePath=function(r){return!ur(r)},exports.isInvalidPath=function(r){return!H(r)},exports.isInvalidSocketPath=function(r){return!fr(r)},exports.isInvalidSymbolicLinkPath=function(r){return!cr(r)},exports.isKelvin=K,exports.isMaxNegative=function(r){return r===-Number.MAX_VALUE}
|
|
1225
1225
|
/**
|
|
1226
1226
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1227
1227
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1238,7 +1238,7 @@ function(t){return!e(t)&&1===t.length},exports.isArrayOfString=function(t){if(e(
|
|
|
1238
1238
|
* //...
|
|
1239
1239
|
* }
|
|
1240
1240
|
*
|
|
1241
|
-
*/,exports.isMaxPositive=function(
|
|
1241
|
+
*/,exports.isMaxPositive=function(r){return r===Number.MAX_VALUE},exports.isMaxSafeInteger=
|
|
1242
1242
|
/**
|
|
1243
1243
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1244
1244
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1256,7 +1256,7 @@ function(t){return!e(t)&&1===t.length},exports.isArrayOfString=function(t){if(e(
|
|
|
1256
1256
|
* }
|
|
1257
1257
|
*
|
|
1258
1258
|
*/
|
|
1259
|
-
function(
|
|
1259
|
+
function(r){return r===Number.MAX_SAFE_INTEGER},exports.isMinNegative=function(r){return r===-Number.MIN_VALUE},exports.isMinPositive=function(r){return r===Number.MIN_VALUE},exports.isMinSafeInteger=function(r){return r===Number.MIN_SAFE_INTEGER},exports.isNaN=function(r){return Number.isNaN(r)},exports.isNotArray=n,exports.isNotArrayBuffer=function(r){return!U(r)},exports.isNotArrayOfArray=function(r){if(n(r))return!0;if(e(r))return!0;for(let n=0,e=r.length;n<e;n++)if(t(r[n]))return!1;return!0},exports.isNotArrayOfBoolean=function(r){if(n(r))return!0;if(e(r))return!0;for(let t=0,n=r.length;t<n;t++)if(o(r[t]))return!0;return!1},exports.isNotArrayOfFunction=function(r){if(n(r))return!0;if(e(r))return!0;for(let t=0,n=r.length;t<n;t++)if(s(r[t]))return!0;return!1},exports.isNotArrayOfNull=function(r){if(n(r))return!0;if(e(r))return!0;for(let t=0,n=r.length;t<n;t++)if(f(r[t]))return!0;return!1},exports.isNotArrayOfNumber=function(r){if(n(r))return!0;if(e(r))return!0;for(let t=0,n=r.length;t<n;t++)if(N(r[t]))return!0;return!1},exports.isNotArrayOfObject=function(r){if(n(r))return!0;if(e(r))return!0;for(let t=0,n=r.length;t<n;t++)if(E(r[t]))return!0;return!1},exports.isNotArrayOfString=function(r){if(n(r))return!0;if(e(r))return!0;for(let t=0,n=r.length;t<n;t++)if(v(r[t]))return!0;return!1}
|
|
1260
1260
|
/**
|
|
1261
1261
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1262
1262
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1273,7 +1273,7 @@ function(t){return t===Number.MAX_SAFE_INTEGER},exports.isMinNegative=function(t
|
|
|
1273
1273
|
* //...
|
|
1274
1274
|
* }
|
|
1275
1275
|
*
|
|
1276
|
-
*/,exports.isNotArrayOfUndefined=function(
|
|
1276
|
+
*/,exports.isNotArrayOfUndefined=function(r){if(n(r))return!0;if(e(r))return!0;for(let t=0,n=r.length;t<n;t++)if(b(r[t]))return!0;return!1}
|
|
1277
1277
|
/**
|
|
1278
1278
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1279
1279
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1290,7 +1290,7 @@ function(t){return t===Number.MAX_SAFE_INTEGER},exports.isMinNegative=function(t
|
|
|
1290
1290
|
* //...
|
|
1291
1291
|
* }
|
|
1292
1292
|
*
|
|
1293
|
-
*/,exports.isNotBigInt64Array=function(
|
|
1293
|
+
*/,exports.isNotBigInt64Array=function(r){return!T(r)},exports.isNotBigUint64Array=function(r){return!B(r)},exports.isNotBlankString=function(r){return!w(r)},exports.isNotBlockDevicePath=function(r){return!q(r)},exports.isNotBoolean=o,exports.isNotCelsius=Z,exports.isNotCharacterDevicePath=function(r){return!J(r)},exports.isNotDefined=c,exports.isNotDirectoryPath=function(r){return!W(r)},exports.isNotEmpty=function(r){return!O(r)},exports.isNotEmptyArray=function(r){return!!n(r)||r.length>0},exports.isNotEmptyDirectory=function(r){return!rr(r)},exports.isNotEmptyFile=function(r,t=0){return!or(r,t)},exports.isNotEmptyObject=function(r){return!m(r)},exports.isNotEmptyString=function(r){return!S(r)},exports.isNotFIFOPath=function(r){return!nr(r)},exports.isNotFahrenheit=Y,exports.isNotFilePath=function(r){return!ir(r)},exports.isNotFloat32Array=function(r){return!V(r)},exports.isNotFloat64Array=function(r){return!k(r)},exports.isNotFunction=s,exports.isNotInt16Array=function(r){return!L(r)},exports.isNotInt32Array=function(r){return!_(r)},exports.isNotInt8Array=function(r){return!D(r)},exports.isNotKelvin=X,exports.isNotNull=f,exports.isNotNumber=N,exports.isNotObject=E,exports.isNotSocketPath=function(r){return!sr(r)},exports.isNotString=v,exports.isNotSymbol=function(r){return"symbol"!=typeof r},exports.isNotSymbolicLinkPath=function(r){return!ar(r)},exports.isNotTemperature=function(r){return X(r)&&Z(r)&&Y(r)},exports.isNotUint16Array=function(r){return!M(r)},exports.isNotUint32Array=function(r){return!R(r)},exports.isNotUint8Array=function(r){return!j(r)},exports.isNotUint8ClampedArray=function(r){return!C(r)}
|
|
1294
1294
|
/**
|
|
1295
1295
|
* @author [Tristan Valcke]{@link https://github.com/Itee}
|
|
1296
1296
|
* @license [BSD-3-Clause]{@link https://opensource.org/licenses/BSD-3-Clause}
|
|
@@ -1298,4 +1298,4 @@ function(t){return t===Number.MAX_SAFE_INTEGER},exports.isMinNegative=function(t
|
|
|
1298
1298
|
* @module sources/physics/constants
|
|
1299
1299
|
* @desc Export constants about temperatures
|
|
1300
1300
|
*
|
|
1301
|
-
*/,exports.isNotUndefined=
|
|
1301
|
+
*/,exports.isNotUndefined=b,exports.isNull=function(r){return null===r},exports.isNumber=h,exports.isNumberNegative=function(r){return h(r)&&r<0},exports.isNumberPositive=function(r){return!N(r)&&(r>0||x(r)||l(r))},exports.isObject=I,exports.isSocketPath=sr,exports.isString=g,exports.isSymbol=F,exports.isSymbolicLinkPath=ar,exports.isTemperature=function(r){return K(r)||$(r)||G(r)},exports.isTrue=function(r){return i(r)&&!0===r},exports.isUint16Array=M,exports.isUint32Array=R,exports.isUint8Array=j,exports.isUint8ClampedArray=C,exports.isUndefined=function(r){return void 0===r},exports.isValidBlockDevicePath=z,exports.isValidCharacterDevicePath=Q,exports.isValidDirectoryPath=tr,exports.isValidFIFOPath=er,exports.isValidFilePath=ur,exports.isValidPath=H,exports.isValidSocketPath=fr,exports.isValidSymbolicLinkPath=cr,exports.isZero=function(r){return 0===r},exports.isZeroNegative=function(r){return 0===r&&1/r===Number.NEGATIVE_INFINITY},exports.isZeroPositive=x;
|