umt 2.1.1 → 2.2.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/module/Advance/rangeAdvance.d.ts +10 -6
- package/module/Advance/rangeAdvance.js +10 -6
- package/module/Advance/rangeAdvance.js.map +1 -1
- package/module/Array/arraysJoin.d.ts +4 -4
- package/module/Array/arraysJoin.js +4 -4
- package/module/Array/binarySearch.d.ts +4 -3
- package/module/Array/binarySearch.js +4 -3
- package/module/Array/binarySearch.js.map +1 -1
- package/module/Array/checkFlagAlignment.d.ts +3 -3
- package/module/Array/checkFlagAlignment.js +7 -7
- package/module/Array/checkFlagAlignment.js.map +1 -1
- package/module/Array/chunk.d.ts +4 -4
- package/module/Array/compact.d.ts +8 -0
- package/module/Array/compact.js +8 -0
- package/module/Array/compact.js.map +1 -1
- package/module/Array/compareFunctionDefault.d.ts +13 -0
- package/module/Array/compareFunctionDefault.js +13 -0
- package/module/Array/compareFunctionDefault.js.map +1 -1
- package/module/Array/drop.d.ts +5 -5
- package/module/Array/drop.js +5 -5
- package/module/Array/dualPivotQuickSort.d.ts +16 -0
- package/module/Array/dualPivotQuickSort.js +152 -0
- package/module/Array/dualPivotQuickSort.js.map +1 -0
- package/module/Array/first.d.ts +3 -3
- package/module/Array/first.js +3 -3
- package/module/Array/generateNumberArray.d.ts +6 -6
- package/module/Array/generateNumberArray.js +6 -6
- package/module/Array/getArraysCommon.d.ts +4 -4
- package/module/Array/getArraysCommon.js +4 -4
- package/module/Array/getArraysDiff.d.ts +4 -4
- package/module/Array/getArraysDiff.js +4 -4
- package/module/Array/groupBy.d.ts +8 -4
- package/module/Array/groupBy.js +8 -4
- package/module/Array/groupBy.js.map +1 -1
- package/module/Array/index.d.ts +1 -0
- package/module/Array/index.js +1 -0
- package/module/Array/index.js.map +1 -1
- package/module/Array/insertionSort.d.ts +8 -7
- package/module/Array/insertionSort.js +6 -6
- package/module/Array/insertionSort.js.map +1 -1
- package/module/Array/mergeSort.d.ts +6 -5
- package/module/Array/mergeSort.js +9 -9
- package/module/Array/mergeSort.js.map +1 -1
- package/module/Array/quickSort.d.ts +12 -11
- package/module/Array/quickSort.js +44 -10
- package/module/Array/quickSort.js.map +1 -1
- package/module/Array/randomSelect.d.ts +5 -5
- package/module/Array/randomSelect.js +5 -5
- package/module/Array/range.d.ts +5 -5
- package/module/Array/range.js +26 -10
- package/module/Array/range.js.map +1 -1
- package/module/Array/shuffle.d.ts +3 -3
- package/module/Array/shuffle.js +3 -3
- package/module/Array/shuffle2DArray.d.ts +4 -4
- package/module/Array/shuffle2DArray.js +6 -6
- package/module/Array/shuffle2DArray.js.map +1 -1
- package/module/Array/sum.d.ts +3 -3
- package/module/Array/sum.js +4 -4
- package/module/Array/sum.js.map +1 -1
- package/module/Array/timSort.d.ts +13 -11
- package/module/Array/timSort.js +33 -9
- package/module/Array/timSort.js.map +1 -1
- package/module/Array/zip.d.ts +6 -3
- package/module/Array/zip.js +6 -3
- package/module/Array/zip.js.map +1 -1
- package/module/Array/zipLongest.d.ts +8 -5
- package/module/Array/zipLongest.js +8 -5
- package/module/Array/zipLongest.js.map +1 -1
- package/module/Color/cmykToRgba.d.ts +7 -7
- package/module/Color/cmykToRgba.js +12 -12
- package/module/Color/cmykToRgba.js.map +1 -1
- package/module/Color/hexaToRgba.d.ts +4 -3
- package/module/Color/hexaToRgba.js +18 -7
- package/module/Color/hexaToRgba.js.map +1 -1
- package/module/Color/hslaToRgba.d.ts +7 -6
- package/module/Color/hslaToRgba.js +19 -15
- package/module/Color/hslaToRgba.js.map +1 -1
- package/module/Color/rgbaToCmyk.d.ts +3 -3
- package/module/Color/rgbaToCmyk.js +14 -3
- package/module/Color/rgbaToCmyk.js.map +1 -1
- package/module/Color/rgbaToHexA.d.ts +4 -4
- package/module/Color/rgbaToHexA.js +5 -5
- package/module/Color/rgbaToHexA.js.map +1 -1
- package/module/Color/rgbaToHsla.d.ts +4 -3
- package/module/Color/rgbaToHsla.js +15 -3
- package/module/Color/rgbaToHsla.js.map +1 -1
- package/module/Consts/clock.d.ts +11 -11
- package/module/Consts/clock.js +11 -11
- package/module/Consts/httpStatus/httpClientErrorStatus.d.ts +28 -0
- package/module/Consts/httpStatus/httpClientErrorStatus.js +28 -0
- package/module/Consts/httpStatus/httpClientErrorStatus.js.map +1 -1
- package/module/Consts/httpStatus/httpInformationalStatus.d.ts +9 -0
- package/module/Consts/httpStatus/httpInformationalStatus.js +9 -0
- package/module/Consts/httpStatus/httpInformationalStatus.js.map +1 -1
- package/module/Consts/httpStatus/httpRedirectionStatus.d.ts +11 -0
- package/module/Consts/httpStatus/httpRedirectionStatus.js +11 -0
- package/module/Consts/httpStatus/httpRedirectionStatus.js.map +1 -1
- package/module/Consts/httpStatus/httpServerErrorStatus.d.ts +10 -0
- package/module/Consts/httpStatus/httpServerErrorStatus.js +10 -0
- package/module/Consts/httpStatus/httpServerErrorStatus.js.map +1 -1
- package/module/Consts/httpStatus/httpSuccessStatus.d.ts +11 -0
- package/module/Consts/httpStatus/httpSuccessStatus.js +11 -0
- package/module/Consts/httpStatus/httpSuccessStatus.js.map +1 -1
- package/module/Date/birthday.d.ts +7 -6
- package/module/Date/birthday.js +7 -6
- package/module/Date/birthday.js.map +1 -1
- package/module/Date/dateRange.d.ts +7 -4
- package/module/Date/dateRange.js +7 -4
- package/module/Date/dateRange.js.map +1 -1
- package/module/Date/dayOfWeek.d.ts +4 -4
- package/module/Date/dayOfWeek.js +4 -4
- package/module/Date/format.d.ts +30 -4
- package/module/Date/format.js +30 -4
- package/module/Date/format.js.map +1 -1
- package/module/Date/getDay.d.ts +8 -5
- package/module/Date/getDay.js +8 -5
- package/module/Date/getDay.js.map +1 -1
- package/module/Date/getTimezoneOffsetString.d.ts +3 -3
- package/module/Date/getTimezoneOffsetString.js +3 -3
- package/module/Date/isLeapYear.d.ts +8 -3
- package/module/Date/isLeapYear.js +8 -3
- package/module/Date/isLeapYear.js.map +1 -1
- package/module/Date/new.d.ts +20 -20
- package/module/Date/new.js +21 -21
- package/module/Date/new.js.map +1 -1
- package/module/Date/now.d.ts +7 -4
- package/module/Date/now.js +7 -4
- package/module/Date/now.js.map +1 -1
- package/module/Error/safeExecute.d.ts +21 -0
- package/module/Error/safeExecute.js +20 -0
- package/module/Error/safeExecute.js.map +1 -1
- package/module/IP/cidrToLong.d.ts +4 -3
- package/module/IP/cidrToLong.js +10 -4
- package/module/IP/cidrToLong.js.map +1 -1
- package/module/IP/cidrToSubnetMask.d.ts +4 -3
- package/module/IP/cidrToSubnetMask.js +4 -3
- package/module/IP/cidrToSubnetMask.js.map +1 -1
- package/module/IP/getIpClass.d.ts +3 -3
- package/module/IP/getIpClass.js +30 -18
- package/module/IP/getIpClass.js.map +1 -1
- package/module/IP/getNetworkAddress.d.ts +5 -4
- package/module/IP/getNetworkAddress.js +36 -6
- package/module/IP/getNetworkAddress.js.map +1 -1
- package/module/IP/ipToBinaryString.d.ts +4 -3
- package/module/IP/ipToBinaryString.js +32 -7
- package/module/IP/ipToBinaryString.js.map +1 -1
- package/module/IP/ipToLong.d.ts +4 -3
- package/module/IP/ipToLong.js +4 -3
- package/module/IP/ipToLong.js.map +1 -1
- package/module/IP/isInRange.d.ts +6 -5
- package/module/IP/isInRange.js +33 -7
- package/module/IP/isInRange.js.map +1 -1
- package/module/IP/isPrivateIp.d.ts +4 -3
- package/module/IP/isPrivateIp.js +17 -9
- package/module/IP/isPrivateIp.js.map +1 -1
- package/module/IP/longToIp.d.ts +4 -3
- package/module/IP/longToIp.js +16 -4
- package/module/IP/longToIp.js.map +1 -1
- package/module/IP/subnetMaskToCidr.d.ts +4 -3
- package/module/IP/subnetMaskToCidr.js +28 -12
- package/module/IP/subnetMaskToCidr.js.map +1 -1
- package/module/Math/addition.d.ts +3 -3
- package/module/Math/addition.js +3 -3
- package/module/Math/average.d.ts +7 -4
- package/module/Math/average.js +7 -4
- package/module/Math/average.js.map +1 -1
- package/module/Math/bitwise.d.ts +5 -5
- package/module/Math/bitwise.js +5 -5
- package/module/Math/calculator/calculator.d.ts +9 -7
- package/module/Math/calculator/calculator.js +9 -7
- package/module/Math/calculator/calculator.js.map +1 -1
- package/module/Math/calculator/calculatorInitialization.d.ts +4 -3
- package/module/Math/calculator/calculatorInitialization.js +6 -5
- package/module/Math/calculator/calculatorInitialization.js.map +1 -1
- package/module/Math/calculator/convertCurrency.d.ts +6 -4
- package/module/Math/calculator/convertCurrency.js +6 -4
- package/module/Math/calculator/convertCurrency.js.map +1 -1
- package/module/Math/calculator/core.js +13 -13
- package/module/Math/calculator/core.js.map +1 -1
- package/module/Math/calculator/literalExpression.d.ts +5 -3
- package/module/Math/calculator/literalExpression.js +12 -10
- package/module/Math/calculator/literalExpression.js.map +1 -1
- package/module/Math/degToRad.d.ts +3 -3
- package/module/Math/degToRad.js +3 -3
- package/module/Math/deviationValue.d.ts +5 -5
- package/module/Math/deviationValue.js +5 -5
- package/module/Math/division.d.ts +5 -5
- package/module/Math/division.js +31 -21
- package/module/Math/division.js.map +1 -1
- package/module/Math/factorial.d.ts +3 -3
- package/module/Math/factorial.js +3 -3
- package/module/Math/factorize.d.ts +3 -3
- package/module/Math/factorize.js +3 -3
- package/module/Math/flexibleNumberConversion.d.ts +11 -11
- package/module/Math/flexibleNumberConversion.js +19 -19
- package/module/Math/flexibleNumberConversion.js.map +1 -1
- package/module/Math/gcd.d.ts +5 -5
- package/module/Math/gcd.js +6 -6
- package/module/Math/gcd.js.map +1 -1
- package/module/Math/getDecimalLength.d.ts +7 -4
- package/module/Math/getDecimalLength.js +9 -5
- package/module/Math/getDecimalLength.js.map +1 -1
- package/module/Math/lcm.d.ts +4 -4
- package/module/Math/lcm.js +5 -5
- package/module/Math/lcm.js.map +1 -1
- package/module/Math/linearCongruentialGenerator.d.ts +6 -6
- package/module/Math/linearCongruentialGenerator.js +6 -6
- package/module/Math/mathConverter.d.ts +7 -3
- package/module/Math/mathConverter.js +7 -3
- package/module/Math/mathConverter.js.map +1 -1
- package/module/Math/mathSeparator.d.ts +8 -3
- package/module/Math/mathSeparator.js +8 -3
- package/module/Math/mathSeparator.js.map +1 -1
- package/module/Math/max.d.ts +4 -3
- package/module/Math/max.js +4 -3
- package/module/Math/max.js.map +1 -1
- package/module/Math/median.d.ts +3 -3
- package/module/Math/median.js +3 -3
- package/module/Math/min.d.ts +4 -3
- package/module/Math/min.js +4 -3
- package/module/Math/min.js.map +1 -1
- package/module/Math/multiples.d.ts +4 -4
- package/module/Math/multiples.js +4 -4
- package/module/Math/multiplication.d.ts +3 -3
- package/module/Math/multiplication.js +3 -3
- package/module/Math/nCr.d.ts +7 -4
- package/module/Math/nCr.js +7 -4
- package/module/Math/nCr.js.map +1 -1
- package/module/Math/nHr.d.ts +7 -4
- package/module/Math/nHr.js +7 -4
- package/module/Math/nHr.js.map +1 -1
- package/module/Math/nPr.d.ts +7 -4
- package/module/Math/nPr.js +7 -4
- package/module/Math/nPr.js.map +1 -1
- package/module/Math/primeFactorization.d.ts +6 -3
- package/module/Math/primeFactorization.js +11 -8
- package/module/Math/primeFactorization.js.map +1 -1
- package/module/Math/quotient.d.ts +7 -4
- package/module/Math/quotient.js +7 -4
- package/module/Math/quotient.js.map +1 -1
- package/module/Math/radToDeg.d.ts +5 -3
- package/module/Math/radToDeg.js +5 -3
- package/module/Math/radToDeg.js.map +1 -1
- package/module/Math/random.d.ts +6 -5
- package/module/Math/random.js +6 -5
- package/module/Math/random.js.map +1 -1
- package/module/Math/reduce.d.ts +9 -4
- package/module/Math/reduce.js +16 -6
- package/module/Math/reduce.js.map +1 -1
- package/module/Math/repeatedTrial.d.ts +5 -5
- package/module/Math/repeatedTrial.js +5 -5
- package/module/Math/roundOf.d.ts +7 -5
- package/module/Math/roundOf.js +8 -6
- package/module/Math/roundOf.js.map +1 -1
- package/module/Math/solveEquation.d.ts +12 -13
- package/module/Math/solveEquation.js +32 -37
- package/module/Math/solveEquation.js.map +1 -1
- package/module/Math/standardDeviation.d.ts +8 -3
- package/module/Math/standardDeviation.js +13 -7
- package/module/Math/standardDeviation.js.map +1 -1
- package/module/Math/subtract.d.ts +10 -4
- package/module/Math/subtract.js +12 -6
- package/module/Math/subtract.js.map +1 -1
- package/module/Math/toBaseN.d.ts +8 -6
- package/module/Math/toBaseN.js +9 -7
- package/module/Math/toBaseN.js.map +1 -1
- package/module/Math/toCelsius.d.ts +5 -3
- package/module/Math/toCelsius.js +5 -3
- package/module/Math/toCelsius.js.map +1 -1
- package/module/Math/toKelvin.d.ts +5 -3
- package/module/Math/toKelvin.js +5 -3
- package/module/Math/toKelvin.js.map +1 -1
- package/module/Math/uuidv7.d.ts +10 -2
- package/module/Math/uuidv7.js +10 -2
- package/module/Math/uuidv7.js.map +1 -1
- package/module/Math/valueSwap.d.ts +5 -4
- package/module/Math/valueSwap.js +5 -4
- package/module/Math/valueSwap.js.map +1 -1
- package/module/Math/xoshiro256.d.ts +8 -3
- package/module/Math/xoshiro256.js +8 -3
- package/module/Math/xoshiro256.js.map +1 -1
- package/module/Object/has.d.ts +4 -4
- package/module/Object/has.js +4 -4
- package/module/Object/keyBy.d.ts +3 -3
- package/module/Object/keyBy.js +4 -4
- package/module/Object/pick.d.ts +6 -6
- package/module/Object/pick.js +6 -6
- package/module/Object/pickDeep.d.ts +7 -7
- package/module/Object/pickDeep.js +7 -7
- package/module/Simple/Array/quickSortSimple.d.ts +9 -7
- package/module/Simple/Array/quickSortSimple.js +7 -6
- package/module/Simple/Array/quickSortSimple.js.map +1 -1
- package/module/Simple/Date/birthdaySimple.d.ts +4 -4
- package/module/Simple/Date/birthdaySimple.js +4 -4
- package/module/Simple/Date/dayOfWeekSimple.d.ts +4 -4
- package/module/Simple/Date/nowSimple.d.ts +3 -3
- package/module/Simple/Date/nowSimple.js +3 -3
- package/module/Simple/Math/deviationValueSimple.d.ts +10 -11
- package/module/Simple/Math/deviationValueSimple.js +14 -13
- package/module/Simple/Math/deviationValueSimple.js.map +1 -1
- package/module/String/deleteSpaces.d.ts +8 -4
- package/module/String/deleteSpaces.js +8 -4
- package/module/String/deleteSpaces.js.map +1 -1
- package/module/String/formatString.d.ts +8 -8
- package/module/String/formatString.js +7 -7
- package/module/String/formatString.js.map +1 -1
- package/module/String/fromBase64.d.ts +4 -3
- package/module/String/fromBase64.js +15 -9
- package/module/String/fromBase64.js.map +1 -1
- package/module/String/hasNoLetters.d.ts +9 -3
- package/module/String/hasNoLetters.js +12 -6
- package/module/String/hasNoLetters.js.map +1 -1
- package/module/String/padEnd.d.ts +5 -5
- package/module/String/padEnd.js +5 -5
- package/module/String/padStart.d.ts +11 -5
- package/module/String/padStart.js +17 -5
- package/module/String/padStart.js.map +1 -1
- package/module/String/randomString.d.ts +4 -4
- package/module/String/randomString.js +4 -4
- package/module/String/randomStringInitialization.d.ts +3 -3
- package/module/String/randomStringInitialization.js +3 -3
- package/module/String/reverseString.d.ts +3 -3
- package/module/String/reverseString.js +3 -3
- package/module/String/toBase64.d.ts +3 -3
- package/module/String/toBase64.js +3 -3
- package/module/String/toHalfWidth.d.ts +3 -3
- package/module/String/toHalfWidth.js +3 -3
- package/module/String/trimCharacters.d.ts +4 -4
- package/module/String/trimCharacters.js +4 -4
- package/module/String/trimEndCharacters.d.ts +10 -4
- package/module/String/trimEndCharacters.js +10 -4
- package/module/String/trimEndCharacters.js.map +1 -1
- package/module/String/trimStartCharacters.d.ts +10 -4
- package/module/String/trimStartCharacters.js +10 -4
- package/module/String/trimStartCharacters.js.map +1 -1
- package/module/Time/convertTime.d.ts +6 -6
- package/module/Time/convertTime.js +12 -11
- package/module/Time/convertTime.js.map +1 -1
- package/module/Tool/createPipeline.d.ts +8 -6
- package/module/Tool/createPipeline.js +6 -5
- package/module/Tool/createPipeline.js.map +1 -1
- package/module/Tool/parseJson.d.ts +7 -0
- package/module/Tool/parseJson.js +7 -0
- package/module/Tool/parseJson.js.map +1 -1
- package/module/UA/extractBrowserFromUserAgent.d.ts +12 -0
- package/module/UA/extractBrowserFromUserAgent.js +22 -5
- package/module/UA/extractBrowserFromUserAgent.js.map +1 -1
- package/module/UA/extractDeviceFromUserAgent.d.ts +12 -0
- package/module/UA/extractDeviceFromUserAgent.js +12 -0
- package/module/UA/extractDeviceFromUserAgent.js.map +1 -1
- package/module/UA/extractOsFromUserAgent.d.ts +12 -0
- package/module/UA/extractOsFromUserAgent.js +12 -0
- package/module/UA/extractOsFromUserAgent.js.map +1 -1
- package/module/UA/parseUserAgent.d.ts +16 -0
- package/module/UA/parseUserAgent.js +16 -0
- package/module/UA/parseUserAgent.js.map +1 -1
- package/module/Unit/index.d.ts +1 -0
- package/module/Unit/index.js +2 -0
- package/module/Unit/index.js.map +1 -0
- package/module/Unit/unitConverterInitialization.d.ts +16 -0
- package/module/Unit/unitConverterInitialization.js +19 -0
- package/module/Unit/unitConverterInitialization.js.map +1 -0
- package/module/Validate/array/core.d.ts +12 -0
- package/module/Validate/array/core.js +15 -3
- package/module/Validate/array/core.js.map +1 -1
- package/module/Validate/boolean/core.d.ts +9 -0
- package/module/Validate/boolean/core.js +9 -0
- package/module/Validate/boolean/core.js.map +1 -1
- package/module/Validate/core/index.d.ts +10 -0
- package/module/Validate/core/index.js +11 -1
- package/module/Validate/core/index.js.map +1 -1
- package/module/Validate/isArray.d.ts +3 -3
- package/module/Validate/isArray.js +3 -3
- package/module/Validate/isBrowser.d.ts +1 -1
- package/module/Validate/isBrowser.js +1 -1
- package/module/Validate/isBun.d.ts +1 -1
- package/module/Validate/isBun.js +1 -1
- package/module/Validate/isDictionaryObject.d.ts +3 -3
- package/module/Validate/isDictionaryObject.js +3 -3
- package/module/Validate/isDouble.d.ts +4 -4
- package/module/Validate/isDouble.js +4 -4
- package/module/Validate/isNode.d.ts +1 -1
- package/module/Validate/isNode.js +1 -1
- package/module/Validate/isNodeWebkit.d.ts +1 -1
- package/module/Validate/isNodeWebkit.js +1 -1
- package/module/Validate/isNotEmpty.d.ts +3 -3
- package/module/Validate/isNotEmpty.js +4 -4
- package/module/Validate/isNotEmpty.js.map +1 -1
- package/module/Validate/isNumber.d.ts +4 -4
- package/module/Validate/isNumber.js +10 -4
- package/module/Validate/isNumber.js.map +1 -1
- package/module/Validate/isPerfectSquare.d.ts +8 -3
- package/module/Validate/isPerfectSquare.js +8 -3
- package/module/Validate/isPerfectSquare.js.map +1 -1
- package/module/Validate/isPrimeNumber.d.ts +7 -3
- package/module/Validate/isPrimeNumber.js +8 -4
- package/module/Validate/isPrimeNumber.js.map +1 -1
- package/module/Validate/isValueNaN.d.ts +7 -5
- package/module/Validate/isValueNaN.js +7 -5
- package/module/Validate/isValueNaN.js.map +1 -1
- package/module/Validate/number/core.d.ts +11 -0
- package/module/Validate/number/core.js +11 -0
- package/module/Validate/number/core.js.map +1 -1
- package/module/Validate/number/double.d.ts +9 -0
- package/module/Validate/number/double.js +9 -0
- package/module/Validate/number/double.js.map +1 -1
- package/module/Validate/number/even.d.ts +9 -0
- package/module/Validate/number/even.js +9 -0
- package/module/Validate/number/even.js.map +1 -1
- package/module/Validate/number/maxValue.d.ts +10 -0
- package/module/Validate/number/maxValue.js +10 -0
- package/module/Validate/number/maxValue.js.map +1 -1
- package/module/Validate/number/minValue.d.ts +10 -0
- package/module/Validate/number/minValue.js +10 -0
- package/module/Validate/number/minValue.js.map +1 -1
- package/module/Validate/number/prime.d.ts +9 -0
- package/module/Validate/number/prime.js +9 -0
- package/module/Validate/number/prime.js.map +1 -1
- package/module/Validate/object/core.d.ts +11 -0
- package/module/Validate/object/core.js +11 -0
- package/module/Validate/object/core.js.map +1 -1
- package/module/Validate/string/core.d.ts +11 -0
- package/module/Validate/string/core.js +11 -0
- package/module/Validate/string/core.js.map +1 -1
- package/module/Validate/string/email.d.ts +9 -0
- package/module/Validate/string/email.js +10 -1
- package/module/Validate/string/email.js.map +1 -1
- package/module/Validate/string/length.d.ts +11 -0
- package/module/Validate/string/length.js +11 -0
- package/module/Validate/string/length.js.map +1 -1
- package/module/Validate/string/maxLength.d.ts +10 -0
- package/module/Validate/string/maxLength.js +10 -0
- package/module/Validate/string/maxLength.js.map +1 -1
- package/module/Validate/string/minLength.d.ts +10 -0
- package/module/Validate/string/minLength.js +10 -0
- package/module/Validate/string/minLength.js.map +1 -1
- package/module/Validate/string/numberString.d.ts +9 -0
- package/module/Validate/string/numberString.js +9 -0
- package/module/Validate/string/numberString.js.map +1 -1
- package/module/Validate/string/regexMatch.d.ts +10 -0
- package/module/Validate/string/regexMatch.js +10 -0
- package/module/Validate/string/regexMatch.js.map +1 -1
- package/module/Validate/string/uuid.d.ts +8 -3
- package/module/Validate/string/uuid.js +9 -4
- package/module/Validate/string/uuid.js.map +1 -1
- package/module/Validate/type.d.ts +22 -0
- package/module/es5/Advance/rangeAdvance.d.ts +10 -6
- package/module/es5/Advance/rangeAdvance.js +10 -6
- package/module/es5/Array/arraysJoin.d.ts +4 -4
- package/module/es5/Array/arraysJoin.js +4 -4
- package/module/es5/Array/binarySearch.d.ts +4 -3
- package/module/es5/Array/binarySearch.js +4 -3
- package/module/es5/Array/checkFlagAlignment.d.ts +3 -3
- package/module/es5/Array/checkFlagAlignment.js +7 -7
- package/module/es5/Array/chunk.d.ts +4 -4
- package/module/es5/Array/chunk.js +4 -4
- package/module/es5/Array/compact.d.ts +8 -0
- package/module/es5/Array/compact.js +8 -0
- package/module/es5/Array/compareFunctionDefault.d.ts +13 -0
- package/module/es5/Array/compareFunctionDefault.js +13 -0
- package/module/es5/Array/drop.d.ts +5 -5
- package/module/es5/Array/drop.js +5 -5
- package/module/es5/Array/dualPivotQuickSort.d.ts +16 -0
- package/module/es5/Array/dualPivotQuickSort.js +201 -0
- package/module/es5/Array/first.d.ts +3 -3
- package/module/es5/Array/first.js +3 -3
- package/module/es5/Array/generateNumberArray.d.ts +6 -6
- package/module/es5/Array/generateNumberArray.js +6 -6
- package/module/es5/Array/getArraysCommon.d.ts +4 -4
- package/module/es5/Array/getArraysCommon.js +4 -4
- package/module/es5/Array/getArraysDiff.d.ts +4 -4
- package/module/es5/Array/getArraysDiff.js +4 -4
- package/module/es5/Array/groupBy.d.ts +8 -4
- package/module/es5/Array/groupBy.js +8 -4
- package/module/es5/Array/index.d.ts +1 -0
- package/module/es5/Array/index.js +11 -0
- package/module/es5/Array/insertionSort.d.ts +8 -7
- package/module/es5/Array/insertionSort.js +6 -6
- package/module/es5/Array/mergeSort.d.ts +6 -5
- package/module/es5/Array/mergeSort.js +9 -9
- package/module/es5/Array/quickSort.d.ts +12 -11
- package/module/es5/Array/quickSort.js +47 -10
- package/module/es5/Array/randomSelect.d.ts +5 -5
- package/module/es5/Array/randomSelect.js +5 -5
- package/module/es5/Array/range.d.ts +5 -5
- package/module/es5/Array/range.js +28 -10
- package/module/es5/Array/shuffle.d.ts +3 -3
- package/module/es5/Array/shuffle.js +3 -3
- package/module/es5/Array/shuffle2DArray.d.ts +4 -4
- package/module/es5/Array/shuffle2DArray.js +6 -6
- package/module/es5/Array/sum.d.ts +3 -3
- package/module/es5/Array/sum.js +4 -4
- package/module/es5/Array/timSort.d.ts +13 -11
- package/module/es5/Array/timSort.js +36 -9
- package/module/es5/Array/zip.d.ts +6 -3
- package/module/es5/Array/zip.js +6 -3
- package/module/es5/Array/zipLongest.d.ts +8 -5
- package/module/es5/Array/zipLongest.js +8 -5
- package/module/es5/Color/cmykToRgba.d.ts +7 -7
- package/module/es5/Color/cmykToRgba.js +12 -12
- package/module/es5/Color/hexaToRgba.d.ts +4 -3
- package/module/es5/Color/hexaToRgba.js +18 -6
- package/module/es5/Color/hslaToRgba.d.ts +7 -6
- package/module/es5/Color/hslaToRgba.js +19 -13
- package/module/es5/Color/rgbaToCmyk.d.ts +3 -3
- package/module/es5/Color/rgbaToCmyk.js +7 -3
- package/module/es5/Color/rgbaToHexA.d.ts +4 -4
- package/module/es5/Color/rgbaToHexA.js +5 -5
- package/module/es5/Color/rgbaToHsla.d.ts +4 -3
- package/module/es5/Color/rgbaToHsla.js +8 -3
- package/module/es5/Consts/clock.d.ts +11 -11
- package/module/es5/Consts/clock.js +11 -11
- package/module/es5/Consts/httpStatus/httpClientErrorStatus.d.ts +28 -0
- package/module/es5/Consts/httpStatus/httpClientErrorStatus.js +28 -0
- package/module/es5/Consts/httpStatus/httpInformationalStatus.d.ts +9 -0
- package/module/es5/Consts/httpStatus/httpInformationalStatus.js +9 -0
- package/module/es5/Consts/httpStatus/httpRedirectionStatus.d.ts +11 -0
- package/module/es5/Consts/httpStatus/httpRedirectionStatus.js +11 -0
- package/module/es5/Consts/httpStatus/httpServerErrorStatus.d.ts +10 -0
- package/module/es5/Consts/httpStatus/httpServerErrorStatus.js +10 -0
- package/module/es5/Consts/httpStatus/httpSuccessStatus.d.ts +11 -0
- package/module/es5/Consts/httpStatus/httpSuccessStatus.js +11 -0
- package/module/es5/Date/birthday.d.ts +7 -6
- package/module/es5/Date/birthday.js +7 -6
- package/module/es5/Date/dateRange.d.ts +7 -4
- package/module/es5/Date/dateRange.js +7 -4
- package/module/es5/Date/dayOfWeek.d.ts +4 -4
- package/module/es5/Date/dayOfWeek.js +4 -4
- package/module/es5/Date/format.d.ts +30 -4
- package/module/es5/Date/format.js +30 -4
- package/module/es5/Date/getDay.d.ts +8 -5
- package/module/es5/Date/getDay.js +8 -5
- package/module/es5/Date/getTimezoneOffsetString.d.ts +3 -3
- package/module/es5/Date/getTimezoneOffsetString.js +3 -3
- package/module/es5/Date/isLeapYear.d.ts +8 -3
- package/module/es5/Date/isLeapYear.js +8 -3
- package/module/es5/Date/new.d.ts +20 -20
- package/module/es5/Date/new.js +21 -21
- package/module/es5/Date/now.d.ts +7 -4
- package/module/es5/Date/now.js +7 -4
- package/module/es5/Error/safeExecute.d.ts +21 -0
- package/module/es5/Error/safeExecute.js +36 -0
- package/module/es5/IP/cidrToLong.d.ts +4 -3
- package/module/es5/IP/cidrToLong.js +7 -3
- package/module/es5/IP/cidrToSubnetMask.d.ts +4 -3
- package/module/es5/IP/cidrToSubnetMask.js +4 -3
- package/module/es5/IP/getIpClass.d.ts +3 -3
- package/module/es5/IP/getIpClass.js +44 -18
- package/module/es5/IP/getNetworkAddress.d.ts +5 -4
- package/module/es5/IP/getNetworkAddress.js +35 -6
- package/module/es5/IP/ipToBinaryString.d.ts +4 -3
- package/module/es5/IP/ipToBinaryString.js +44 -5
- package/module/es5/IP/ipToLong.d.ts +4 -3
- package/module/es5/IP/ipToLong.js +4 -3
- package/module/es5/IP/isInRange.d.ts +6 -5
- package/module/es5/IP/isInRange.js +34 -7
- package/module/es5/IP/isPrivateIp.d.ts +4 -3
- package/module/es5/IP/isPrivateIp.js +30 -17
- package/module/es5/IP/longToIp.d.ts +4 -3
- package/module/es5/IP/longToIp.js +17 -5
- package/module/es5/IP/subnetMaskToCidr.d.ts +4 -3
- package/module/es5/IP/subnetMaskToCidr.js +33 -12
- package/module/es5/Math/addition.d.ts +3 -3
- package/module/es5/Math/addition.js +3 -3
- package/module/es5/Math/average.d.ts +7 -4
- package/module/es5/Math/average.js +7 -4
- package/module/es5/Math/bitwise.d.ts +5 -5
- package/module/es5/Math/bitwise.js +5 -5
- package/module/es5/Math/calculator/calculator.d.ts +9 -7
- package/module/es5/Math/calculator/calculator.js +9 -7
- package/module/es5/Math/calculator/calculatorInitialization.d.ts +4 -3
- package/module/es5/Math/calculator/calculatorInitialization.js +6 -5
- package/module/es5/Math/calculator/convertCurrency.d.ts +6 -4
- package/module/es5/Math/calculator/convertCurrency.js +6 -4
- package/module/es5/Math/calculator/core.js +13 -13
- package/module/es5/Math/calculator/literalExpression.d.ts +5 -3
- package/module/es5/Math/calculator/literalExpression.js +12 -10
- package/module/es5/Math/degToRad.d.ts +3 -3
- package/module/es5/Math/degToRad.js +3 -3
- package/module/es5/Math/deviationValue.d.ts +5 -5
- package/module/es5/Math/deviationValue.js +5 -5
- package/module/es5/Math/division.d.ts +5 -5
- package/module/es5/Math/division.js +35 -21
- package/module/es5/Math/factorial.d.ts +3 -3
- package/module/es5/Math/factorial.js +3 -3
- package/module/es5/Math/factorize.d.ts +3 -3
- package/module/es5/Math/factorize.js +3 -3
- package/module/es5/Math/flexibleNumberConversion.d.ts +11 -11
- package/module/es5/Math/flexibleNumberConversion.js +19 -19
- package/module/es5/Math/gcd.d.ts +5 -5
- package/module/es5/Math/gcd.js +6 -6
- package/module/es5/Math/getDecimalLength.d.ts +7 -4
- package/module/es5/Math/getDecimalLength.js +9 -5
- package/module/es5/Math/lcm.d.ts +4 -4
- package/module/es5/Math/lcm.js +5 -5
- package/module/es5/Math/linearCongruentialGenerator.d.ts +6 -6
- package/module/es5/Math/linearCongruentialGenerator.js +6 -6
- package/module/es5/Math/mathConverter.d.ts +7 -3
- package/module/es5/Math/mathConverter.js +7 -3
- package/module/es5/Math/mathSeparator.d.ts +8 -3
- package/module/es5/Math/mathSeparator.js +8 -3
- package/module/es5/Math/max.d.ts +4 -3
- package/module/es5/Math/max.js +4 -3
- package/module/es5/Math/median.d.ts +3 -3
- package/module/es5/Math/median.js +3 -3
- package/module/es5/Math/min.d.ts +4 -3
- package/module/es5/Math/min.js +4 -3
- package/module/es5/Math/multiples.d.ts +4 -4
- package/module/es5/Math/multiples.js +4 -4
- package/module/es5/Math/multiplication.d.ts +3 -3
- package/module/es5/Math/multiplication.js +3 -3
- package/module/es5/Math/nCr.d.ts +7 -4
- package/module/es5/Math/nCr.js +7 -4
- package/module/es5/Math/nHr.d.ts +7 -4
- package/module/es5/Math/nHr.js +7 -4
- package/module/es5/Math/nPr.d.ts +7 -4
- package/module/es5/Math/nPr.js +7 -4
- package/module/es5/Math/primeFactorization.d.ts +6 -3
- package/module/es5/Math/primeFactorization.js +11 -8
- package/module/es5/Math/quotient.d.ts +7 -4
- package/module/es5/Math/quotient.js +7 -4
- package/module/es5/Math/radToDeg.d.ts +5 -3
- package/module/es5/Math/radToDeg.js +5 -3
- package/module/es5/Math/random.d.ts +6 -5
- package/module/es5/Math/random.js +6 -5
- package/module/es5/Math/reduce.d.ts +9 -4
- package/module/es5/Math/reduce.js +14 -8
- package/module/es5/Math/repeatedTrial.d.ts +5 -5
- package/module/es5/Math/repeatedTrial.js +5 -5
- package/module/es5/Math/roundOf.d.ts +7 -5
- package/module/es5/Math/roundOf.js +8 -6
- package/module/es5/Math/solveEquation.d.ts +12 -13
- package/module/es5/Math/solveEquation.js +34 -38
- package/module/es5/Math/standardDeviation.d.ts +8 -3
- package/module/es5/Math/standardDeviation.js +16 -7
- package/module/es5/Math/subtract.d.ts +10 -4
- package/module/es5/Math/subtract.js +12 -6
- package/module/es5/Math/toBaseN.d.ts +8 -6
- package/module/es5/Math/toBaseN.js +9 -7
- package/module/es5/Math/toCelsius.d.ts +5 -3
- package/module/es5/Math/toCelsius.js +5 -3
- package/module/es5/Math/toKelvin.d.ts +5 -3
- package/module/es5/Math/toKelvin.js +5 -3
- package/module/es5/Math/uuidv7.d.ts +10 -2
- package/module/es5/Math/uuidv7.js +10 -2
- package/module/es5/Math/valueSwap.d.ts +5 -4
- package/module/es5/Math/valueSwap.js +5 -4
- package/module/es5/Math/xoshiro256.d.ts +8 -3
- package/module/es5/Math/xoshiro256.js +8 -3
- package/module/es5/Object/has.d.ts +4 -4
- package/module/es5/Object/has.js +4 -4
- package/module/es5/Object/keyBy.d.ts +3 -3
- package/module/es5/Object/keyBy.js +4 -4
- package/module/es5/Object/pick.d.ts +6 -6
- package/module/es5/Object/pick.js +6 -6
- package/module/es5/Object/pickDeep.d.ts +7 -7
- package/module/es5/Object/pickDeep.js +7 -7
- package/module/es5/Simple/Array/quickSortSimple.d.ts +9 -7
- package/module/es5/Simple/Array/quickSortSimple.js +7 -6
- package/module/es5/Simple/Date/birthdaySimple.d.ts +4 -4
- package/module/es5/Simple/Date/birthdaySimple.js +4 -4
- package/module/es5/Simple/Date/dayOfWeekSimple.d.ts +4 -4
- package/module/es5/Simple/Date/dayOfWeekSimple.js +4 -4
- package/module/es5/Simple/Date/nowSimple.d.ts +3 -3
- package/module/es5/Simple/Date/nowSimple.js +3 -3
- package/module/es5/Simple/Math/deviationValueSimple.d.ts +10 -11
- package/module/es5/Simple/Math/deviationValueSimple.js +23 -12
- package/module/es5/String/deleteSpaces.d.ts +8 -4
- package/module/es5/String/deleteSpaces.js +8 -4
- package/module/es5/String/formatString.d.ts +8 -8
- package/module/es5/String/formatString.js +7 -7
- package/module/es5/String/fromBase64.d.ts +4 -3
- package/module/es5/String/fromBase64.js +14 -9
- package/module/es5/String/hasNoLetters.d.ts +9 -3
- package/module/es5/String/hasNoLetters.js +12 -6
- package/module/es5/String/padEnd.d.ts +5 -5
- package/module/es5/String/padEnd.js +5 -5
- package/module/es5/String/padStart.d.ts +11 -5
- package/module/es5/String/padStart.js +20 -5
- package/module/es5/String/randomString.d.ts +4 -4
- package/module/es5/String/randomString.js +4 -4
- package/module/es5/String/randomStringInitialization.d.ts +3 -3
- package/module/es5/String/randomStringInitialization.js +3 -3
- package/module/es5/String/reverseString.d.ts +3 -3
- package/module/es5/String/reverseString.js +3 -3
- package/module/es5/String/toBase64.d.ts +3 -3
- package/module/es5/String/toBase64.js +3 -3
- package/module/es5/String/toHalfWidth.d.ts +3 -3
- package/module/es5/String/toHalfWidth.js +3 -3
- package/module/es5/String/trimCharacters.d.ts +4 -4
- package/module/es5/String/trimCharacters.js +4 -4
- package/module/es5/String/trimEndCharacters.d.ts +10 -4
- package/module/es5/String/trimEndCharacters.js +10 -4
- package/module/es5/String/trimStartCharacters.d.ts +10 -4
- package/module/es5/String/trimStartCharacters.js +10 -4
- package/module/es5/Time/convertTime.d.ts +6 -6
- package/module/es5/Time/convertTime.js +12 -11
- package/module/es5/Tool/createPipeline.d.ts +8 -6
- package/module/es5/Tool/createPipeline.js +10 -8
- package/module/es5/Tool/parseJson.d.ts +7 -0
- package/module/es5/Tool/parseJson.js +7 -0
- package/module/es5/UA/extractBrowserFromUserAgent.d.ts +12 -0
- package/module/es5/UA/extractBrowserFromUserAgent.js +22 -5
- package/module/es5/UA/extractDeviceFromUserAgent.d.ts +12 -0
- package/module/es5/UA/extractDeviceFromUserAgent.js +12 -0
- package/module/es5/UA/extractOsFromUserAgent.d.ts +12 -0
- package/module/es5/UA/extractOsFromUserAgent.js +12 -0
- package/module/es5/UA/parseUserAgent.d.ts +16 -0
- package/module/es5/UA/parseUserAgent.js +16 -0
- package/module/es5/Unit/index.d.ts +1 -0
- package/module/es5/Unit/index.js +16 -0
- package/module/es5/Unit/unitConverterInitialization.d.ts +16 -0
- package/module/es5/Unit/unitConverterInitialization.js +28 -0
- package/module/es5/Validate/array/core.d.ts +12 -0
- package/module/es5/Validate/array/core.js +15 -4
- package/module/es5/Validate/boolean/core.d.ts +9 -0
- package/module/es5/Validate/boolean/core.js +10 -0
- package/module/es5/Validate/core/index.d.ts +10 -0
- package/module/es5/Validate/core/index.js +13 -1
- package/module/es5/Validate/isArray.d.ts +3 -3
- package/module/es5/Validate/isArray.js +3 -3
- package/module/es5/Validate/isBrowser.d.ts +1 -1
- package/module/es5/Validate/isBrowser.js +1 -1
- package/module/es5/Validate/isBun.d.ts +1 -1
- package/module/es5/Validate/isBun.js +1 -1
- package/module/es5/Validate/isDictionaryObject.d.ts +3 -3
- package/module/es5/Validate/isDictionaryObject.js +3 -3
- package/module/es5/Validate/isDouble.d.ts +4 -4
- package/module/es5/Validate/isDouble.js +4 -4
- package/module/es5/Validate/isNode.d.ts +1 -1
- package/module/es5/Validate/isNode.js +1 -1
- package/module/es5/Validate/isNodeWebkit.d.ts +1 -1
- package/module/es5/Validate/isNodeWebkit.js +1 -1
- package/module/es5/Validate/isNotEmpty.d.ts +3 -3
- package/module/es5/Validate/isNotEmpty.js +4 -4
- package/module/es5/Validate/isNumber.d.ts +4 -4
- package/module/es5/Validate/isNumber.js +11 -4
- package/module/es5/Validate/isPerfectSquare.d.ts +8 -3
- package/module/es5/Validate/isPerfectSquare.js +8 -3
- package/module/es5/Validate/isPrimeNumber.d.ts +7 -3
- package/module/es5/Validate/isPrimeNumber.js +8 -4
- package/module/es5/Validate/isValueNaN.d.ts +7 -5
- package/module/es5/Validate/isValueNaN.js +7 -5
- package/module/es5/Validate/number/core.d.ts +11 -0
- package/module/es5/Validate/number/core.js +12 -0
- package/module/es5/Validate/number/double.d.ts +9 -0
- package/module/es5/Validate/number/double.js +10 -0
- package/module/es5/Validate/number/even.d.ts +9 -0
- package/module/es5/Validate/number/even.js +10 -0
- package/module/es5/Validate/number/maxValue.d.ts +10 -0
- package/module/es5/Validate/number/maxValue.js +11 -0
- package/module/es5/Validate/number/minValue.d.ts +10 -0
- package/module/es5/Validate/number/minValue.js +11 -0
- package/module/es5/Validate/number/prime.d.ts +9 -0
- package/module/es5/Validate/number/prime.js +10 -0
- package/module/es5/Validate/object/core.d.ts +11 -0
- package/module/es5/Validate/object/core.js +12 -0
- package/module/es5/Validate/string/core.d.ts +11 -0
- package/module/es5/Validate/string/core.js +12 -0
- package/module/es5/Validate/string/email.d.ts +9 -0
- package/module/es5/Validate/string/email.js +11 -1
- package/module/es5/Validate/string/length.d.ts +11 -0
- package/module/es5/Validate/string/length.js +12 -0
- package/module/es5/Validate/string/maxLength.d.ts +10 -0
- package/module/es5/Validate/string/maxLength.js +11 -0
- package/module/es5/Validate/string/minLength.d.ts +10 -0
- package/module/es5/Validate/string/minLength.js +11 -0
- package/module/es5/Validate/string/numberString.d.ts +9 -0
- package/module/es5/Validate/string/numberString.js +10 -0
- package/module/es5/Validate/string/regexMatch.d.ts +10 -0
- package/module/es5/Validate/string/regexMatch.js +11 -0
- package/module/es5/Validate/string/uuid.d.ts +8 -3
- package/module/es5/Validate/string/uuid.js +10 -4
- package/module/es5/Validate/type.d.ts +22 -0
- package/module/es5/index.d.ts +1 -0
- package/module/es5/index.js +11 -0
- package/module/es5/tests/integration/Array/drop-and-first.test.js +20 -0
- package/module/es5/tests/integration/Tool/parseJson-and-Validate.test.js +68 -14
- package/module/es5/tests/unit/Array/arraysJoin.test.js +15 -3
- package/module/es5/tests/unit/Array/checkFlagAlignment.test.js +10 -10
- package/module/es5/tests/unit/Array/compact.test.js +17 -17
- package/module/es5/tests/unit/Array/compareFunctionDefault.test.d.ts +1 -0
- package/module/es5/tests/unit/Array/compareFunctionDefault.test.js +29 -0
- package/module/es5/tests/unit/Array/drop.test.js +10 -10
- package/module/es5/tests/unit/Array/dualPivotQuickSort.test.d.ts +1 -0
- package/module/es5/tests/unit/Array/dualPivotQuickSort.test.js +87 -0
- package/module/es5/tests/unit/Array/generateNumberArray.test.js +6 -6
- package/module/es5/tests/unit/Array/getArraysCommon.test.js +36 -4
- package/module/es5/tests/unit/Array/getArraysDiff.test.js +14 -14
- package/module/es5/tests/unit/Array/groupBy.test.js +6 -6
- package/module/es5/tests/unit/Array/insertionSort.test.js +8 -8
- package/module/es5/tests/unit/Array/mergeSort.test.js +34 -5
- package/module/es5/tests/unit/Array/quickSort.test.js +76 -11
- package/module/es5/tests/unit/Array/randomSelect.test.js +11 -6
- package/module/es5/tests/unit/Array/range.test.js +25 -4
- package/module/es5/tests/unit/Array/shuffle.test.js +53 -6
- package/module/es5/tests/unit/Array/shuffle2DArray.test.js +51 -8
- package/module/es5/tests/unit/Array/sum.test.js +40 -2
- package/module/es5/tests/unit/Array/timSort.test.js +89 -9
- package/module/es5/tests/unit/Array/zip.test.js +48 -9
- package/module/es5/tests/unit/Array/zipLongest.test.js +52 -9
- package/module/es5/tests/unit/Color/cmykToRgba.test.js +3 -3
- package/module/es5/tests/unit/Color/hexaToRgba.test.js +53 -1
- package/module/es5/tests/unit/Color/hslaToRgba.test.js +35 -53
- package/module/es5/tests/unit/Color/rgbaToCmyk.test.js +67 -1
- package/module/es5/tests/unit/Color/rgbaToHsla.test.js +91 -1
- package/module/es5/tests/unit/Consts/clock.test.js +51 -18
- package/module/es5/tests/unit/Consts/httpStatus.test.js +9 -0
- package/module/es5/tests/unit/Date/birthday.test.d.ts +1 -0
- package/module/es5/tests/unit/Date/birthday.test.js +31 -0
- package/module/es5/tests/unit/Date/dateRange.test.d.ts +1 -0
- package/module/es5/tests/unit/Date/dateRange.test.js +40 -0
- package/module/es5/tests/unit/Date/dayOfWeek.test.js +5 -5
- package/module/es5/tests/unit/Date/format.test.js +22 -0
- package/module/es5/tests/unit/Date/getDay.test.d.ts +1 -0
- package/module/es5/tests/unit/Date/getDay.test.js +40 -0
- package/module/es5/tests/unit/Date/getTimezoneOffsetString.test.js +3 -3
- package/module/es5/tests/unit/Date/isLeapYear.test.d.ts +1 -0
- package/module/es5/tests/unit/Date/isLeapYear.test.js +30 -0
- package/module/es5/tests/unit/Date/new.test.d.ts +1 -0
- package/module/es5/tests/unit/Date/new.test.js +39 -0
- package/module/es5/tests/unit/Date/now.test.d.ts +1 -0
- package/module/es5/tests/unit/Date/now.test.js +42 -0
- package/module/es5/tests/unit/Error/safeExecute.test.js +69 -15
- package/module/es5/tests/unit/IP/cidrToLong.test.js +27 -5
- package/module/es5/tests/unit/IP/cidrToSubnetMask.test.js +29 -10
- package/module/es5/tests/unit/IP/getIpClass.test.js +29 -18
- package/module/es5/tests/unit/IP/getNetworkAddress.test.js +35 -14
- package/module/es5/tests/unit/IP/ipToBinaryString.test.js +38 -9
- package/module/es5/tests/unit/IP/ipToLong.test.js +27 -13
- package/module/es5/tests/unit/IP/isInRange.test.js +75 -4
- package/module/es5/tests/unit/IP/isPrivateIp.test.js +18 -12
- package/module/es5/tests/unit/IP/longToIp.test.d.ts +1 -0
- package/module/es5/tests/unit/IP/longToIp.test.js +39 -0
- package/module/es5/tests/unit/IP/subnetMaskToCidr.test.js +34 -20
- package/module/es5/tests/unit/Math/average.test.js +40 -18
- package/module/es5/tests/unit/Math/bitwise.test.js +14 -14
- package/module/es5/tests/unit/Math/calculator/calculator.test.js +9 -9
- package/module/es5/tests/unit/Math/calculator/calculatorInitialization.test.js +16 -5
- package/module/es5/tests/unit/Math/calculator/convertCurrency.test.js +12 -12
- package/module/es5/tests/unit/Math/calculator/literalExpression.test.js +8 -8
- package/module/es5/tests/unit/Math/degToRad.test.js +10 -10
- package/module/es5/tests/unit/Math/deviationValue.test.js +12 -12
- package/module/es5/tests/unit/Math/division.test.js +72 -25
- package/module/es5/tests/unit/Math/factorial.test.js +4 -4
- package/module/es5/tests/unit/Math/factorize.test.js +34 -9
- package/module/es5/tests/unit/Math/flexibleNumberConversion.test.js +75 -75
- package/module/es5/tests/unit/Math/gcd.test.js +5 -5
- package/module/es5/tests/unit/Math/getDecimalLength.test.js +40 -4
- package/module/es5/tests/unit/Math/lcm.test.js +16 -9
- package/module/es5/tests/unit/Math/linearCongruentialGenerator.test.js +4 -4
- package/module/es5/tests/unit/Math/mathConverter.test.js +13 -13
- package/module/es5/tests/unit/Math/mathSeparator.test.js +23 -5
- package/module/es5/tests/unit/Math/max.test.js +18 -3
- package/module/es5/tests/unit/Math/median.test.js +4 -4
- package/module/es5/tests/unit/Math/min.test.js +18 -3
- package/module/es5/tests/unit/Math/multiples.test.js +26 -10
- package/module/es5/tests/unit/Math/multiplication.test.js +43 -9
- package/module/es5/tests/unit/Math/nCr.test.js +27 -14
- package/module/es5/tests/unit/Math/nHr.test.js +28 -15
- package/module/es5/tests/unit/Math/nPr.test.js +31 -14
- package/module/es5/tests/unit/Math/primeFactorization.test.js +79 -8
- package/module/es5/tests/unit/Math/quotient.test.js +32 -10
- package/module/es5/tests/unit/Math/radToDeg.test.js +39 -38
- package/module/es5/tests/unit/Math/random.test.js +55 -17
- package/module/es5/tests/unit/Math/reduce.test.js +87 -8
- package/module/es5/tests/unit/Math/repeatedTrial.test.js +35 -5
- package/module/es5/tests/unit/Math/roundOf.test.js +36 -11
- package/module/es5/tests/unit/Math/solveEquation.test.js +20 -20
- package/module/es5/tests/unit/Math/standardDeviation.test.js +19 -2
- package/module/es5/tests/unit/Math/subtract.test.js +14 -2
- package/module/es5/tests/unit/Math/toBaseN.test.js +36 -19
- package/module/es5/tests/unit/Math/toCelsius.test.js +14 -2
- package/module/es5/tests/unit/Math/toKelvin.test.js +14 -2
- package/module/es5/tests/unit/Math/uuidv7.test.js +6 -6
- package/module/es5/tests/unit/Math/valueSwap.test.js +24 -6
- package/module/es5/tests/unit/Math/xoshiro256.test.js +22 -11
- package/module/es5/tests/unit/Object/keyBy.test.js +6 -6
- package/module/es5/tests/unit/Object/pick.test.js +11 -11
- package/module/es5/tests/unit/Object/pickDeep.test.js +15 -15
- package/module/es5/tests/unit/Simple/Array/quickSortSimple.test.js +4 -4
- package/module/es5/tests/unit/Simple/Math/deviationValueSimple.test.js +39 -3
- package/module/es5/tests/unit/String/deleteSpaces.test.d.ts +1 -0
- package/module/es5/tests/unit/String/deleteSpaces.test.js +22 -0
- package/module/es5/tests/unit/String/formatString.test.js +41 -14
- package/module/es5/tests/unit/String/fromBase64.test.js +19 -8
- package/module/es5/tests/unit/String/hasNoLetters.test.js +20 -24
- package/module/es5/tests/unit/String/padEnd.test.js +5 -5
- package/module/es5/tests/unit/String/padStart.test.js +32 -19
- package/module/es5/tests/unit/String/randomString.test.js +3 -3
- package/module/es5/tests/unit/String/randomStringInitialization.test.js +2 -2
- package/module/es5/tests/unit/String/reverseString.test.js +10 -12
- package/module/es5/tests/unit/String/toBase64.test.js +5 -5
- package/module/es5/tests/unit/String/toHalfWidth.test.js +3 -3
- package/module/es5/tests/unit/String/trimCharacters.test.js +4 -4
- package/module/es5/tests/unit/String/trimEndCharacters.test.js +17 -7
- package/module/es5/tests/unit/String/trimStartCharacters.test.js +23 -10
- package/module/es5/tests/unit/Time/convertTime.test.js +40 -46
- package/module/es5/tests/unit/Tool/createPipeline.test.js +15 -15
- package/module/es5/tests/unit/UA/extractBrowserFromUserAgent.test.d.ts +1 -0
- package/module/es5/tests/unit/UA/extractBrowserFromUserAgent.test.js +47 -0
- package/module/es5/tests/unit/UA/extractDeviceFromUserAgent.test.d.ts +1 -0
- package/module/es5/tests/unit/UA/extractDeviceFromUserAgent.test.js +55 -0
- package/module/es5/tests/unit/UA/extractOsFromUserAgent.test.d.ts +1 -0
- package/module/es5/tests/unit/UA/extractOsFromUserAgent.test.js +57 -0
- package/module/es5/tests/unit/Unit/unitConverterInitialization.test.d.ts +1 -0
- package/module/es5/tests/unit/Unit/unitConverterInitialization.test.js +40 -0
- package/module/es5/tests/unit/Validate/array/core.test.js +39 -10
- package/module/es5/tests/unit/Validate/core/core.test.d.ts +1 -0
- package/module/es5/tests/unit/Validate/core/core.test.js +87 -0
- package/module/es5/tests/unit/Validate/isArray.test.js +11 -0
- package/module/es5/tests/unit/Validate/isDictionaryObject.test.js +15 -1
- package/module/es5/tests/unit/Validate/isDouble.test.js +21 -4
- package/module/es5/tests/unit/Validate/isNotEmpty.test.js +3 -3
- package/module/es5/tests/unit/Validate/isNumber.test.js +67 -29
- package/module/es5/tests/unit/Validate/isPerfectSquare.test.js +5 -0
- package/module/es5/tests/unit/Validate/isPrimeNumber.test.js +14 -4
- package/module/es5/tests/unit/Validate/isValueNaN.test.js +50 -11
- package/module/es5/tests/unit/Validate/string/uuid.test.js +13 -13
- package/module/es5/tsconfig.tsbuildinfo +1 -1
- package/module/es5/types/array/compareFunction.d.ts +2 -0
- package/module/es5/types/array/compareFunction.js +5 -0
- package/module/es5/types/time/timeUnit.d.ts +1 -1
- package/module/index.d.ts +1 -0
- package/module/index.js +1 -0
- package/module/index.js.map +1 -1
- package/module/types/array/compareFunction.d.ts +2 -0
- package/module/types/array/compareFunction.js +2 -0
- package/module/types/array/compareFunction.js.map +1 -0
- package/module/types/time/timeUnit.d.ts +1 -1
- package/package.json +14 -14
|
@@ -6,11 +6,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.dateRange = void 0;
|
|
7
7
|
var _clock = require("@/Consts/clock");
|
|
8
8
|
/**
|
|
9
|
-
*
|
|
9
|
+
* Generate an array containing all dates between the specified start and end dates.
|
|
10
10
|
*
|
|
11
|
-
* @param {Date} startDate -
|
|
12
|
-
* @param {Date} endDate -
|
|
13
|
-
* @returns {Date[]} startDate
|
|
11
|
+
* @param {Date} startDate - The start date of the range
|
|
12
|
+
* @param {Date} endDate - The end date of the range
|
|
13
|
+
* @returns {Date[]} An array of Date objects from startDate to endDate (inclusive)
|
|
14
|
+
* @example
|
|
15
|
+
* dateRange(new Date('2025-01-01'), new Date('2025-01-03'))
|
|
16
|
+
* // Returns array of dates: [2025-01-01, 2025-01-02, 2025-01-03]
|
|
14
17
|
*/
|
|
15
18
|
var dateRange = exports.dateRange = function dateRange(startDate, endDate) {
|
|
16
19
|
var dates = [];
|
|
@@ -2,10 +2,10 @@ import type { HoursTypeInt } from "$/clock/hoursTypeInt";
|
|
|
2
2
|
import type { DayTypeInt } from "$/date/dayTypeInt";
|
|
3
3
|
import type { MonTypeInt } from "$/date/monTypeInt";
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
6
|
-
* @param properties
|
|
7
|
-
* @param timeDifference
|
|
8
|
-
* @returns number
|
|
5
|
+
* Get the day of the week
|
|
6
|
+
* @param properties Object containing year, month, and day
|
|
7
|
+
* @param timeDifference Time difference from UTC in hours (default: 9)
|
|
8
|
+
* @returns A number representing the day of the week (0 = Sunday, 6 = Saturday)
|
|
9
9
|
* @example dayOfWeek({ year: 2000, mon: 1, day: 1 });
|
|
10
10
|
*/
|
|
11
11
|
export declare const dayOfWeek: <T extends MonTypeInt>(properties?: {
|
|
@@ -7,10 +7,10 @@ exports.dayOfWeek = void 0;
|
|
|
7
7
|
var _new = require("@/Date/new");
|
|
8
8
|
var _now = require("@/Date/now");
|
|
9
9
|
/**
|
|
10
|
-
*
|
|
11
|
-
* @param properties
|
|
12
|
-
* @param timeDifference
|
|
13
|
-
* @returns number
|
|
10
|
+
* Get the day of the week
|
|
11
|
+
* @param properties Object containing year, month, and day
|
|
12
|
+
* @param timeDifference Time difference from UTC in hours (default: 9)
|
|
13
|
+
* @returns A number representing the day of the week (0 = Sunday, 6 = Saturday)
|
|
14
14
|
* @example dayOfWeek({ year: 2000, mon: 1, day: 1 });
|
|
15
15
|
*/
|
|
16
16
|
var dayOfWeek = exports.dayOfWeek = function dayOfWeek(properties) {
|
|
@@ -1,7 +1,33 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
* @param {Date} date -
|
|
4
|
-
* @param {string} formatString -
|
|
5
|
-
* @return {string} -
|
|
2
|
+
* Converts a date to a string according to the specified format pattern.
|
|
3
|
+
* @param {Date} date - The date object to format
|
|
4
|
+
* @param {string} formatString - The format pattern string (default: "YYYY-MM-DDTHH:mm:ssZ")
|
|
5
|
+
* @return {string} - The formatted date string
|
|
6
|
+
* @example
|
|
7
|
+
* format(new Date('2025-04-04'), 'YYYY-MM-DD') // Returns "2025-04-04"
|
|
8
|
+
* format(new Date('2025-04-04T15:30:00'), 'HH:mm') // Returns "15:30"
|
|
9
|
+
* format(new Date('2025-04-04'), 'MM/DD/YYYY') // Returns "04/04/2025"
|
|
10
|
+
*
|
|
11
|
+
* Available format tokens:
|
|
12
|
+
* - YYYY: Full year (e.g., 2025)
|
|
13
|
+
* - YY: Short year (e.g., 25)
|
|
14
|
+
* - MM: Month with leading zero (01-12)
|
|
15
|
+
* - M: Month without leading zero (1-12)
|
|
16
|
+
* - DD: Day with leading zero (01-31)
|
|
17
|
+
* - D: Day without leading zero (1-31)
|
|
18
|
+
* - d: Day of week (0-6)
|
|
19
|
+
* - HH: Hours with leading zero (00-23)
|
|
20
|
+
* - H: Hours without leading zero (0-23)
|
|
21
|
+
* - hh: Hours (12-hour) with leading zero (01-12)
|
|
22
|
+
* - h: Hours (12-hour) without leading zero (1-12)
|
|
23
|
+
* - mm: Minutes with leading zero (00-59)
|
|
24
|
+
* - m: Minutes without leading zero (0-59)
|
|
25
|
+
* - ss: Seconds with leading zero (00-59)
|
|
26
|
+
* - s: Seconds without leading zero (0-59)
|
|
27
|
+
* - SSS: Milliseconds with leading zeros (000-999)
|
|
28
|
+
* - A: AM/PM
|
|
29
|
+
* - a: am/pm
|
|
30
|
+
* - Z: Timezone offset (+09:00)
|
|
31
|
+
* - ZZ: Timezone offset without colon (+0900)
|
|
6
32
|
*/
|
|
7
33
|
export declare const format: (date: Date, formatString?: string) => string;
|
|
@@ -7,10 +7,36 @@ exports.format = void 0;
|
|
|
7
7
|
var _getTimezoneOffsetString = require("@/Date/getTimezoneOffsetString");
|
|
8
8
|
var _padStart = require("@/String/padStart");
|
|
9
9
|
/**
|
|
10
|
-
*
|
|
11
|
-
* @param {Date} date -
|
|
12
|
-
* @param {string} formatString -
|
|
13
|
-
* @return {string} -
|
|
10
|
+
* Converts a date to a string according to the specified format pattern.
|
|
11
|
+
* @param {Date} date - The date object to format
|
|
12
|
+
* @param {string} formatString - The format pattern string (default: "YYYY-MM-DDTHH:mm:ssZ")
|
|
13
|
+
* @return {string} - The formatted date string
|
|
14
|
+
* @example
|
|
15
|
+
* format(new Date('2025-04-04'), 'YYYY-MM-DD') // Returns "2025-04-04"
|
|
16
|
+
* format(new Date('2025-04-04T15:30:00'), 'HH:mm') // Returns "15:30"
|
|
17
|
+
* format(new Date('2025-04-04'), 'MM/DD/YYYY') // Returns "04/04/2025"
|
|
18
|
+
*
|
|
19
|
+
* Available format tokens:
|
|
20
|
+
* - YYYY: Full year (e.g., 2025)
|
|
21
|
+
* - YY: Short year (e.g., 25)
|
|
22
|
+
* - MM: Month with leading zero (01-12)
|
|
23
|
+
* - M: Month without leading zero (1-12)
|
|
24
|
+
* - DD: Day with leading zero (01-31)
|
|
25
|
+
* - D: Day without leading zero (1-31)
|
|
26
|
+
* - d: Day of week (0-6)
|
|
27
|
+
* - HH: Hours with leading zero (00-23)
|
|
28
|
+
* - H: Hours without leading zero (0-23)
|
|
29
|
+
* - hh: Hours (12-hour) with leading zero (01-12)
|
|
30
|
+
* - h: Hours (12-hour) without leading zero (1-12)
|
|
31
|
+
* - mm: Minutes with leading zero (00-59)
|
|
32
|
+
* - m: Minutes without leading zero (0-59)
|
|
33
|
+
* - ss: Seconds with leading zero (00-59)
|
|
34
|
+
* - s: Seconds without leading zero (0-59)
|
|
35
|
+
* - SSS: Milliseconds with leading zeros (000-999)
|
|
36
|
+
* - A: AM/PM
|
|
37
|
+
* - a: am/pm
|
|
38
|
+
* - Z: Timezone offset (+09:00)
|
|
39
|
+
* - ZZ: Timezone offset without colon (+0900)
|
|
14
40
|
*/
|
|
15
41
|
var format = exports.format = function format(date) {
|
|
16
42
|
var formatString = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "YYYY-MM-DDTHH:mm:ssZ";
|
|
@@ -7,11 +7,14 @@ interface DayList {
|
|
|
7
7
|
fr: ["Dim", "Lun", "Mar", "Mer", "Jeu", "Ven", "Sam"];
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
*
|
|
11
|
-
* @param day
|
|
12
|
-
* @param lang
|
|
13
|
-
* @returns
|
|
14
|
-
* @example
|
|
10
|
+
* Convert a number to a day of the week in the specified language
|
|
11
|
+
* @param day Number representing the day (0-6, where 0 is Sunday)
|
|
12
|
+
* @param lang Language code ('de', 'ko', 'en', 'ja', 'fr')
|
|
13
|
+
* @returns Day of the week string in the specified language
|
|
14
|
+
* @example
|
|
15
|
+
* getDay(0); // Returns "日" (default is Japanese)
|
|
16
|
+
* getDay(0, "en"); // Returns "Sun"
|
|
17
|
+
* getDay(1, "fr"); // Returns "Lun"
|
|
15
18
|
*/
|
|
16
19
|
export declare const getDay: <T extends keyof DayList>(day: number, lang?: T) => ArrayToUnion<DayList[T]>;
|
|
17
20
|
export {};
|
|
@@ -5,11 +5,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.getDay = void 0;
|
|
7
7
|
/**
|
|
8
|
-
*
|
|
9
|
-
* @param day
|
|
10
|
-
* @param lang
|
|
11
|
-
* @returns
|
|
12
|
-
* @example
|
|
8
|
+
* Convert a number to a day of the week in the specified language
|
|
9
|
+
* @param day Number representing the day (0-6, where 0 is Sunday)
|
|
10
|
+
* @param lang Language code ('de', 'ko', 'en', 'ja', 'fr')
|
|
11
|
+
* @returns Day of the week string in the specified language
|
|
12
|
+
* @example
|
|
13
|
+
* getDay(0); // Returns "日" (default is Japanese)
|
|
14
|
+
* getDay(0, "en"); // Returns "Sun"
|
|
15
|
+
* getDay(1, "fr"); // Returns "Lun"
|
|
13
16
|
*/
|
|
14
17
|
var getDay = exports.getDay = function getDay(day) {
|
|
15
18
|
var lang = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "ja";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
* @param {Date} instance -
|
|
4
|
-
* @return {string} -
|
|
2
|
+
* Get timezone offset string in format "+HH:mm" or "-HH:mm"
|
|
3
|
+
* @param {Date} instance - The date object to get timezone offset from
|
|
4
|
+
* @return {string} - The timezone offset string (e.g. "+09:00" for JST)
|
|
5
5
|
*/
|
|
6
6
|
export declare const getTimezoneOffsetString: (instance: Date) => string;
|
|
@@ -6,9 +6,9 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.getTimezoneOffsetString = void 0;
|
|
7
7
|
var _padStart = require("@/String/padStart");
|
|
8
8
|
/**
|
|
9
|
-
*
|
|
10
|
-
* @param {Date} instance -
|
|
11
|
-
* @return {string} -
|
|
9
|
+
* Get timezone offset string in format "+HH:mm" or "-HH:mm"
|
|
10
|
+
* @param {Date} instance - The date object to get timezone offset from
|
|
11
|
+
* @return {string} - The timezone offset string (e.g. "+09:00" for JST)
|
|
12
12
|
*/
|
|
13
13
|
var getTimezoneOffsetString = exports.getTimezoneOffsetString = function getTimezoneOffsetString(instance) {
|
|
14
14
|
var negMinutes = -instance.getTimezoneOffset();
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
* @param {number} year -
|
|
4
|
-
* @returns {boolean}
|
|
2
|
+
* Determine if a given year is a leap year
|
|
3
|
+
* @param {number} year - The year to check
|
|
4
|
+
* @returns {boolean} true if the year is a leap year, false otherwise
|
|
5
|
+
* @example
|
|
6
|
+
* isLeapYear(2000); // Returns true (divisible by 400)
|
|
7
|
+
* isLeapYear(2020); // Returns true (divisible by 4 but not 100)
|
|
8
|
+
* isLeapYear(2100); // Returns false (divisible by 100 but not 400)
|
|
9
|
+
* isLeapYear(2023); // Returns false (not divisible by 4)
|
|
5
10
|
*/
|
|
6
11
|
export declare const isLeapYear: (year: number) => boolean;
|
|
@@ -5,9 +5,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.isLeapYear = void 0;
|
|
7
7
|
/**
|
|
8
|
-
*
|
|
9
|
-
* @param {number} year -
|
|
10
|
-
* @returns {boolean}
|
|
8
|
+
* Determine if a given year is a leap year
|
|
9
|
+
* @param {number} year - The year to check
|
|
10
|
+
* @returns {boolean} true if the year is a leap year, false otherwise
|
|
11
|
+
* @example
|
|
12
|
+
* isLeapYear(2000); // Returns true (divisible by 400)
|
|
13
|
+
* isLeapYear(2020); // Returns true (divisible by 4 but not 100)
|
|
14
|
+
* isLeapYear(2100); // Returns false (divisible by 100 but not 400)
|
|
15
|
+
* isLeapYear(2023); // Returns false (not divisible by 4)
|
|
11
16
|
*/
|
|
12
17
|
var isLeapYear = exports.isLeapYear = function isLeapYear(year) {
|
|
13
18
|
return year % 4 === 0 && year % 100 !== 0 || year % 400 === 0;
|
package/module/es5/Date/new.d.ts
CHANGED
|
@@ -11,27 +11,27 @@ import type { DayTypeInt } from "$/date/dayTypeInt";
|
|
|
11
11
|
import type { MonTypeInt } from "$/date/monTypeInt";
|
|
12
12
|
import type { MonTypeZero } from "$/date/monTypeZero";
|
|
13
13
|
/**
|
|
14
|
-
*
|
|
15
|
-
* @param year
|
|
16
|
-
* @param mon
|
|
17
|
-
* @param day
|
|
18
|
-
* @param hours
|
|
19
|
-
* @param minutes
|
|
20
|
-
* @param seconds
|
|
21
|
-
* @param milliseconds
|
|
22
|
-
* @returns Date
|
|
23
|
-
* @example newDateInt(2021, 1, 1); // 2021
|
|
14
|
+
* Create a new Date object from numeric values
|
|
15
|
+
* @param year - The year
|
|
16
|
+
* @param mon - The month (1-12)
|
|
17
|
+
* @param day - The day of the month
|
|
18
|
+
* @param hours - Hours offset from UTC (defaults to local timezone offset)
|
|
19
|
+
* @param minutes - Minutes (0-59)
|
|
20
|
+
* @param seconds - Seconds (0-59)
|
|
21
|
+
* @param milliseconds - Milliseconds (0-999)
|
|
22
|
+
* @returns Date object
|
|
23
|
+
* @example newDateInt(2021, 1, 1); // Creates date for January 1, 2021
|
|
24
24
|
*/
|
|
25
25
|
export declare const newDateInt: <T extends MonTypeInt>(year: number, mon: T, day: DayTypeInt<T>, hours?: HoursTypeInt, minutes?: MinutesTypeInt, seconds?: SecondsTypeInt, milliseconds?: MillisecondsTypeInt) => Date;
|
|
26
26
|
/**
|
|
27
|
-
*
|
|
28
|
-
* @param date "
|
|
29
|
-
* @param hours
|
|
30
|
-
* @param minutes
|
|
31
|
-
* @param seconds
|
|
32
|
-
* @param
|
|
33
|
-
* @param timeDifference
|
|
34
|
-
* @returns Date
|
|
35
|
-
* @example newDateString("2021-01-01"); // 2021
|
|
27
|
+
* Create a new Date object from a string date and time components
|
|
28
|
+
* @param date - Date string in format "YYYY-MM-DD"
|
|
29
|
+
* @param hours - Hours in "HH" format (00-23)
|
|
30
|
+
* @param minutes - Minutes in "mm" format (00-59)
|
|
31
|
+
* @param seconds - Seconds in "ss" format (00-59)
|
|
32
|
+
* @param milliseconds - Milliseconds in "mmm" format (000-999)
|
|
33
|
+
* @param timeDifference - Timezone offset in "HH" format (e.g., "09" for UTC+9)
|
|
34
|
+
* @returns Date object
|
|
35
|
+
* @example newDateString("2021-01-01"); // Creates date for January 1, 2021 00:00:00
|
|
36
36
|
*/
|
|
37
|
-
export declare const newDateString: <T extends MonTypeZero>(date: `${number}-${T}-${DayType<T>}`, hours?: HoursType, minutes?: MinutesType, seconds?: SecondsType,
|
|
37
|
+
export declare const newDateString: <T extends MonTypeZero>(date: `${number}-${T}-${DayType<T>}`, hours?: HoursType, minutes?: MinutesType, seconds?: SecondsType, milliseconds?: MillisecondsType, timeDifference?: HoursType) => Date;
|
package/module/es5/Date/new.js
CHANGED
|
@@ -5,16 +5,16 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.newDateString = exports.newDateInt = void 0;
|
|
7
7
|
/**
|
|
8
|
-
*
|
|
9
|
-
* @param year
|
|
10
|
-
* @param mon
|
|
11
|
-
* @param day
|
|
12
|
-
* @param hours
|
|
13
|
-
* @param minutes
|
|
14
|
-
* @param seconds
|
|
15
|
-
* @param milliseconds
|
|
16
|
-
* @returns Date
|
|
17
|
-
* @example newDateInt(2021, 1, 1); // 2021
|
|
8
|
+
* Create a new Date object from numeric values
|
|
9
|
+
* @param year - The year
|
|
10
|
+
* @param mon - The month (1-12)
|
|
11
|
+
* @param day - The day of the month
|
|
12
|
+
* @param hours - Hours offset from UTC (defaults to local timezone offset)
|
|
13
|
+
* @param minutes - Minutes (0-59)
|
|
14
|
+
* @param seconds - Seconds (0-59)
|
|
15
|
+
* @param milliseconds - Milliseconds (0-999)
|
|
16
|
+
* @returns Date object
|
|
17
|
+
* @example newDateInt(2021, 1, 1); // Creates date for January 1, 2021
|
|
18
18
|
*/
|
|
19
19
|
var newDateInt = exports.newDateInt = function newDateInt(year, mon, day) {
|
|
20
20
|
var hours = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : -new Date().getTimezoneOffset() / 60;
|
|
@@ -26,21 +26,21 @@ var newDateInt = exports.newDateInt = function newDateInt(year, mon, day) {
|
|
|
26
26
|
};
|
|
27
27
|
|
|
28
28
|
/**
|
|
29
|
-
*
|
|
30
|
-
* @param date "
|
|
31
|
-
* @param hours
|
|
32
|
-
* @param minutes
|
|
33
|
-
* @param seconds
|
|
34
|
-
* @param
|
|
35
|
-
* @param timeDifference
|
|
36
|
-
* @returns Date
|
|
37
|
-
* @example newDateString("2021-01-01"); // 2021
|
|
29
|
+
* Create a new Date object from a string date and time components
|
|
30
|
+
* @param date - Date string in format "YYYY-MM-DD"
|
|
31
|
+
* @param hours - Hours in "HH" format (00-23)
|
|
32
|
+
* @param minutes - Minutes in "mm" format (00-59)
|
|
33
|
+
* @param seconds - Seconds in "ss" format (00-59)
|
|
34
|
+
* @param milliseconds - Milliseconds in "mmm" format (000-999)
|
|
35
|
+
* @param timeDifference - Timezone offset in "HH" format (e.g., "09" for UTC+9)
|
|
36
|
+
* @returns Date object
|
|
37
|
+
* @example newDateString("2021-01-01"); // Creates date for January 1, 2021 00:00:00
|
|
38
38
|
*/
|
|
39
39
|
var newDateString = exports.newDateString = function newDateString(date) {
|
|
40
40
|
var hours = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "00";
|
|
41
41
|
var minutes = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "00";
|
|
42
42
|
var seconds = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : "00";
|
|
43
|
-
var
|
|
43
|
+
var milliseconds = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : "000";
|
|
44
44
|
var timeDifference = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : "00";
|
|
45
|
-
return new Date("".concat(date, "T").concat(hours, ":").concat(minutes, ":").concat(seconds, ".").concat(
|
|
45
|
+
return new Date("".concat(date, "T").concat(hours, ":").concat(minutes, ":").concat(seconds, ".").concat(milliseconds, "+").concat(timeDifference, ":00"));
|
|
46
46
|
};
|
package/module/es5/Date/now.d.ts
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
import type { HoursTypeInt } from "$/clock/hoursTypeInt";
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
4
|
-
* @param {hoursTypeInt} [timeDifference=9] UTC
|
|
5
|
-
* @returns {Date}
|
|
6
|
-
* @example
|
|
3
|
+
* Get the current time with a specified UTC offset, regardless of the local timezone
|
|
4
|
+
* @param {hoursTypeInt} [timeDifference=9] Hours offset from UTC (default: 9 for Japan Standard Time)
|
|
5
|
+
* @returns {Date} Current date and time adjusted for the specified UTC offset
|
|
6
|
+
* @example
|
|
7
|
+
* now(); // Returns current time in JST (UTC+9)
|
|
8
|
+
* now(0); // Returns current time in UTC
|
|
9
|
+
* now(1); // Returns current time in UTC+1
|
|
7
10
|
*/
|
|
8
11
|
export declare const now: (timeDifference?: HoursTypeInt) => Date;
|
package/module/es5/Date/now.js
CHANGED
|
@@ -6,10 +6,13 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.now = void 0;
|
|
7
7
|
var _clock = require("@/Consts/clock");
|
|
8
8
|
/**
|
|
9
|
-
*
|
|
10
|
-
* @param {hoursTypeInt} [timeDifference=9] UTC
|
|
11
|
-
* @returns {Date}
|
|
12
|
-
* @example
|
|
9
|
+
* Get the current time with a specified UTC offset, regardless of the local timezone
|
|
10
|
+
* @param {hoursTypeInt} [timeDifference=9] Hours offset from UTC (default: 9 for Japan Standard Time)
|
|
11
|
+
* @returns {Date} Current date and time adjusted for the specified UTC offset
|
|
12
|
+
* @example
|
|
13
|
+
* now(); // Returns current time in JST (UTC+9)
|
|
14
|
+
* now(0); // Returns current time in UTC
|
|
15
|
+
* now(1); // Returns current time in UTC+1
|
|
13
16
|
*/
|
|
14
17
|
var now = exports.now = function now() {
|
|
15
18
|
var timeDifference = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 9;
|
|
@@ -1,11 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Represents a successful execution result containing a value
|
|
3
|
+
* @template V The type of the success value
|
|
4
|
+
*/
|
|
1
5
|
interface SuccessType<V> {
|
|
2
6
|
type: "success";
|
|
3
7
|
value: V;
|
|
4
8
|
}
|
|
9
|
+
/**
|
|
10
|
+
* Represents an error result containing an error object
|
|
11
|
+
* @template E The type of the error
|
|
12
|
+
*/
|
|
5
13
|
interface ErrorType<E> {
|
|
6
14
|
type: "error";
|
|
7
15
|
error: E;
|
|
8
16
|
}
|
|
17
|
+
/**
|
|
18
|
+
* Union type representing either a successful result or an error result
|
|
19
|
+
* @template V The type of the success value
|
|
20
|
+
* @template E The type of the error
|
|
21
|
+
*/
|
|
9
22
|
export type Result<V, E> = SuccessType<V> | ErrorType<E>;
|
|
23
|
+
/**
|
|
24
|
+
* Safely executes a callback function and returns a Result type
|
|
25
|
+
* Catches any errors and wraps them in a Result type
|
|
26
|
+
* @template V The type of the success value
|
|
27
|
+
* @template E The type of the error (defaults to Error)
|
|
28
|
+
* @param callback The function to execute safely
|
|
29
|
+
* @returns A Result containing either the successful value or the caught error
|
|
30
|
+
*/
|
|
10
31
|
export declare const safeExecute: <V, E = Error>(callback: () => V) => Result<V, E>;
|
|
11
32
|
export {};
|
|
@@ -4,18 +4,54 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.safeExecute = void 0;
|
|
7
|
+
/**
|
|
8
|
+
* Represents a successful execution result containing a value
|
|
9
|
+
* @template V The type of the success value
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Represents an error result containing an error object
|
|
14
|
+
* @template E The type of the error
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* Union type representing either a successful result or an error result
|
|
19
|
+
* @template V The type of the success value
|
|
20
|
+
* @template E The type of the error
|
|
21
|
+
*/
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* Creates an error result
|
|
25
|
+
* @template E The type of the error
|
|
26
|
+
* @param error The error object
|
|
27
|
+
* @returns An ErrorType containing the error
|
|
28
|
+
*/
|
|
7
29
|
var errorFunction = function errorFunction(error) {
|
|
8
30
|
return {
|
|
9
31
|
type: "error",
|
|
10
32
|
error: error
|
|
11
33
|
};
|
|
12
34
|
};
|
|
35
|
+
/**
|
|
36
|
+
* Creates a success result
|
|
37
|
+
* @template V The type of the success value
|
|
38
|
+
* @param value The success value
|
|
39
|
+
* @returns A SuccessType containing the value
|
|
40
|
+
*/
|
|
13
41
|
var successFunction = function successFunction(value) {
|
|
14
42
|
return {
|
|
15
43
|
type: "success",
|
|
16
44
|
value: value
|
|
17
45
|
};
|
|
18
46
|
};
|
|
47
|
+
/**
|
|
48
|
+
* Safely executes a callback function and returns a Result type
|
|
49
|
+
* Catches any errors and wraps them in a Result type
|
|
50
|
+
* @template V The type of the success value
|
|
51
|
+
* @template E The type of the error (defaults to Error)
|
|
52
|
+
* @param callback The function to execute safely
|
|
53
|
+
* @returns A Result containing either the successful value or the caught error
|
|
54
|
+
*/
|
|
19
55
|
var safeExecute = exports.safeExecute = function safeExecute(callback) {
|
|
20
56
|
try {
|
|
21
57
|
return successFunction(callback());
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* CIDR
|
|
3
|
-
* @param {number} cidr - CIDR
|
|
4
|
-
* @returns {number}
|
|
2
|
+
* Converts CIDR notation to a subnet mask number
|
|
3
|
+
* @param {number} cidr - CIDR notation (0-32)
|
|
4
|
+
* @returns {number} Subnet mask as a 32-bit number
|
|
5
|
+
* @throws {Error} If CIDR is not between 0 and 32
|
|
5
6
|
*/
|
|
6
7
|
export declare const cidrToLong: (cidr: number) => number;
|
|
@@ -5,10 +5,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.cidrToLong = void 0;
|
|
7
7
|
/**
|
|
8
|
-
* CIDR
|
|
9
|
-
* @param {number} cidr - CIDR
|
|
10
|
-
* @returns {number}
|
|
8
|
+
* Converts CIDR notation to a subnet mask number
|
|
9
|
+
* @param {number} cidr - CIDR notation (0-32)
|
|
10
|
+
* @returns {number} Subnet mask as a 32-bit number
|
|
11
|
+
* @throws {Error} If CIDR is not between 0 and 32
|
|
11
12
|
*/
|
|
12
13
|
var cidrToLong = exports.cidrToLong = function cidrToLong(cidr) {
|
|
14
|
+
if (!Number.isInteger(cidr) || cidr < 0 || cidr > 32) {
|
|
15
|
+
throw new Error("CIDR must be an integer between 0 and 32");
|
|
16
|
+
}
|
|
13
17
|
return Number.parseInt("1".repeat(cidr).padEnd(32, "0"), 2) >>> 0;
|
|
14
18
|
};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* CIDR
|
|
3
|
-
* @param {number} cidr - CIDR
|
|
4
|
-
* @returns {string}
|
|
2
|
+
* Converts CIDR notation to a subnet mask
|
|
3
|
+
* @param {number} cidr - CIDR notation (0-32)
|
|
4
|
+
* @returns {string} Subnet mask in IPv4 format (e.g., "255.255.255.0")
|
|
5
|
+
* @throws {Error} If CIDR is not between 0 and 32
|
|
5
6
|
*/
|
|
6
7
|
export declare const cidrToSubnetMask: (cidr: number) => string;
|
|
@@ -7,9 +7,10 @@ exports.cidrToSubnetMask = void 0;
|
|
|
7
7
|
var _cidrToLong = require("./cidrToLong");
|
|
8
8
|
var _longToIp = require("./longToIp");
|
|
9
9
|
/**
|
|
10
|
-
* CIDR
|
|
11
|
-
* @param {number} cidr - CIDR
|
|
12
|
-
* @returns {string}
|
|
10
|
+
* Converts CIDR notation to a subnet mask
|
|
11
|
+
* @param {number} cidr - CIDR notation (0-32)
|
|
12
|
+
* @returns {string} Subnet mask in IPv4 format (e.g., "255.255.255.0")
|
|
13
|
+
* @throws {Error} If CIDR is not between 0 and 32
|
|
13
14
|
*/
|
|
14
15
|
var cidrToSubnetMask = exports.cidrToSubnetMask = function cidrToSubnetMask(cidr) {
|
|
15
16
|
return (0, _longToIp.longToIp)((0, _cidrToLong.cidrToLong)(cidr));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* IP
|
|
3
|
-
* @param {string} ip -
|
|
4
|
-
* @returns {string} IP
|
|
2
|
+
* Gets the IP address class (A, B, C, D, or E)
|
|
3
|
+
* @param {string} ip - IPv4 address
|
|
4
|
+
* @returns {string} IP class ('A', 'B', 'C', 'D', 'E', or empty string for invalid IP)
|
|
5
5
|
*/
|
|
6
6
|
export declare const getIpClass: (ip: string) => string;
|
|
@@ -5,30 +5,56 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.getIpClass = void 0;
|
|
7
7
|
/**
|
|
8
|
-
* IP
|
|
9
|
-
* @param {string} ip -
|
|
10
|
-
* @returns {string} IP
|
|
8
|
+
* Gets the IP address class (A, B, C, D, or E)
|
|
9
|
+
* @param {string} ip - IPv4 address
|
|
10
|
+
* @returns {string} IP class ('A', 'B', 'C', 'D', 'E', or empty string for invalid IP)
|
|
11
11
|
*/
|
|
12
12
|
var getIpClass = exports.getIpClass = function getIpClass(ip) {
|
|
13
13
|
if (!ip) {
|
|
14
14
|
return "";
|
|
15
15
|
}
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
if (firstOctet < 192) {
|
|
22
|
-
return "B";
|
|
23
|
-
}
|
|
24
|
-
if (firstOctet < 224) {
|
|
25
|
-
return "C";
|
|
16
|
+
|
|
17
|
+
// Validate IP format
|
|
18
|
+
var parts = ip.split(".");
|
|
19
|
+
if (parts.length !== 4) {
|
|
20
|
+
return "";
|
|
26
21
|
}
|
|
27
|
-
|
|
28
|
-
|
|
22
|
+
var firstOctet = Number.parseInt(parts[0]);
|
|
23
|
+
if (Number.isNaN(firstOctet) || firstOctet < 0 || firstOctet > 255) {
|
|
24
|
+
return "";
|
|
29
25
|
}
|
|
30
|
-
|
|
31
|
-
|
|
26
|
+
|
|
27
|
+
// Check each class range
|
|
28
|
+
switch (true) {
|
|
29
|
+
case firstOctet === 0:
|
|
30
|
+
{
|
|
31
|
+
return "";
|
|
32
|
+
}
|
|
33
|
+
// Reserved
|
|
34
|
+
case firstOctet < 128:
|
|
35
|
+
{
|
|
36
|
+
return "A";
|
|
37
|
+
}
|
|
38
|
+
// 1-127
|
|
39
|
+
case firstOctet < 192:
|
|
40
|
+
{
|
|
41
|
+
return "B";
|
|
42
|
+
}
|
|
43
|
+
// 128-191
|
|
44
|
+
case firstOctet < 224:
|
|
45
|
+
{
|
|
46
|
+
return "C";
|
|
47
|
+
}
|
|
48
|
+
// 192-223
|
|
49
|
+
case firstOctet < 240:
|
|
50
|
+
{
|
|
51
|
+
return "D";
|
|
52
|
+
}
|
|
53
|
+
// 224-239
|
|
54
|
+
default:
|
|
55
|
+
{
|
|
56
|
+
return "E";
|
|
57
|
+
}
|
|
58
|
+
// 240-255
|
|
32
59
|
}
|
|
33
|
-
return "";
|
|
34
60
|
};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
* @param {string} ip -
|
|
4
|
-
* @param {string} subnetMask -
|
|
5
|
-
* @returns {number}
|
|
2
|
+
* Calculates the network address from an IP address and subnet mask
|
|
3
|
+
* @param {string} ip - IPv4 address (e.g., "192.168.1.1")
|
|
4
|
+
* @param {string} subnetMask - Subnet mask (e.g., "255.255.255.0")
|
|
5
|
+
* @returns {number} Network address as a 32-bit unsigned integer
|
|
6
|
+
* @throws {Error} If IP address or subnet mask is invalid
|
|
6
7
|
*/
|
|
7
8
|
export declare const getNetworkAddress: (ip: string, subnetMask: string) => number;
|