@glutinum/cli 0.13.0 → 0.14.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +19 -1
- package/dist/Glutinum.Converter/Abbreviations.js +246 -0
- package/dist/Glutinum.Converter/FsharpAST.js +87 -28
- package/dist/Glutinum.Converter/Generate.js +55 -8
- package/dist/Glutinum.Converter/GlueAST.js +333 -34
- package/dist/Glutinum.Converter/Log.js +7 -8
- package/dist/Glutinum.Converter/Merge.js +683 -31
- package/dist/Glutinum.Converter/Packages.js +308 -0
- package/dist/Glutinum.Converter/Printer.js +323 -186
- package/dist/Glutinum.Converter/Read.js +279 -6
- package/dist/Glutinum.Converter/Reader/ClassDeclaration.js +13 -7
- package/dist/Glutinum.Converter/Reader/Declaration.js +102 -17
- package/dist/Glutinum.Converter/Reader/Documentation.js +168 -73
- package/dist/Glutinum.Converter/Reader/EnumDeclaration.js +7 -51
- package/dist/Glutinum.Converter/Reader/ExportAssignment.js +64 -15
- package/dist/Glutinum.Converter/Reader/ExportDeclaration.js +165 -0
- package/dist/Glutinum.Converter/Reader/FunctionDeclaration.js +30 -5
- package/dist/Glutinum.Converter/Reader/IndexedAccessType.js +122 -4
- package/dist/Glutinum.Converter/Reader/InterfaceDeclaration.js +83 -7
- package/dist/Glutinum.Converter/Reader/MappedTypeNode.js +8 -8
- package/dist/Glutinum.Converter/Reader/ModuleDeclaration.js +11 -9
- package/dist/Glutinum.Converter/Reader/NamedTupleMember.js +3 -2
- package/dist/Glutinum.Converter/Reader/Node.js +24 -10
- package/dist/Glutinum.Converter/Reader/Parameters.js +110 -7
- package/dist/Glutinum.Converter/Reader/Report.js +31 -12
- package/dist/Glutinum.Converter/Reader/TypeAliasDeclaration.js +4 -3
- package/dist/Glutinum.Converter/Reader/TypeNode.js +1524 -253
- package/dist/Glutinum.Converter/Reader/TypeOperatorNode.js +75 -20
- package/dist/Glutinum.Converter/Reader/TypeParameters.js +8 -5
- package/dist/Glutinum.Converter/Reader/TypeQueryNode.js +184 -50
- package/dist/Glutinum.Converter/Reader/TypeScriptReader.js +32 -13
- package/dist/Glutinum.Converter/Reader/Types.js +180 -0
- package/dist/Glutinum.Converter/Reader/UnionTypeNode.js +99 -43
- package/dist/Glutinum.Converter/Reader/Utils.js +1143 -55
- package/dist/Glutinum.Converter/Reader/VariableStatement.js +59 -14
- package/dist/Glutinum.Converter/Transform.js +8292 -1119
- package/dist/Glutinum.Converter/TypeScript.Extensions.js +3 -3
- package/dist/Glutinum.Converter/TypeScript.js +3 -3
- package/dist/Glutinum.Converter/Utils/Keywords.js +6 -6
- package/dist/Glutinum.Converter/Utils/List.js +3 -3
- package/dist/Glutinum.Converter/Utils/Naming.js +61 -12
- package/dist/Glutinum.Converter/Utils/String.js +7 -3
- package/dist/Program.js +230 -72
- package/dist/fable_modules/Fable.Promise.3.2.1/AsyncIterable.fs +89 -0
- package/dist/fable_modules/{Fable.Promise.3.2.0 → Fable.Promise.3.2.1}/AsyncIterable.fs.js +29 -29
- package/dist/fable_modules/Fable.Promise.3.2.1/Fable.Promise.fableproj +25 -0
- package/dist/fable_modules/{Fable.Promise.3.2.0 → Fable.Promise.3.2.1}/Promise.fs +842 -766
- package/dist/fable_modules/{Fable.Promise.3.2.0 → Fable.Promise.3.2.1}/Promise.fs.js +26 -12
- package/dist/fable_modules/{Fable.Promise.3.2.0 → Fable.Promise.3.2.1}/PromiseImpl.fs +31 -31
- package/dist/fable_modules/{Fable.Promise.3.2.0 → Fable.Promise.3.2.1}/PromiseImpl.fs.js +5 -5
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/Array.fs +235 -0
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/Array.fs.js +384 -0
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AssemblyInfo.fs +4 -4
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/Async.fs +89 -9
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/Async.fs.js +13 -12
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncOption.fs +50 -4
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncOptionCE.fs +30 -39
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncOptionCE.fs.js +10 -10
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncResult.fs +52 -8
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncResultCE.fs +26 -42
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncResultCE.fs.js +3 -3
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncResultOption.fs +17 -5
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/AsyncResultOption.fs.js +26 -0
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncResultOptionCE.fs +31 -33
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncResultOptionCE.fs.js +3 -3
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncValidation.fs +1 -6
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncValidationCE.fs +10 -18
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncValidationCE.fs.js +3 -3
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/FsToolkit.ErrorHandling.fableproj +69 -0
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/List.fs +68 -10
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/List.fs.js +47 -41
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/Nullness.fs +81 -0
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/Option.fs +133 -2
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/OptionCE.fs +139 -0
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/OptionCE.fs.js +48 -0
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/OptionOp.fs +3 -3
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/ParallelAsyncResult.fs +88 -0
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/ParallelAsyncResult.fs.js +30 -0
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/ParallelAsyncResultCE.fs +200 -0
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/ParallelAsyncResultCE.fs.js +18 -0
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/ParallelAsyncValidation.fs +34 -0
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/ParallelAsyncValidationCE.fs +244 -0
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/ParallelAsyncValidationCE.fs.js +18 -0
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/Result.fs +87 -0
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/Result.fs.js +8 -8
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ResultCE.fs +8 -23
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ResultCE.fs.js +5 -5
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ResultOption.fs +1 -1
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ResultOption.fs.js +10 -10
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ResultOptionCE.fs +7 -18
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ResultOptionCE.fs.js +3 -3
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/Seq.fs +503 -0
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/Seq.fs.js +295 -0
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/Validation.fs +0 -5
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ValidationCE.fs +7 -13
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ValidationCE.fs.js +3 -3
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ValueOption.fs +1 -4
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/ValueTaskValueOption.fs +102 -0
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/ValueTaskValueOptionCE.fs +587 -0
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/ValueTaskValueOptionOp.fs +10 -0
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/obj/Debug/netstandard2.1/FsToolkit.ErrorHandling.AssemblyInfo.fs +3 -3
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/obj/Release/net9.0/.NETCoreApp,Version=v9.0.AssemblyAttributes.fs +3 -0
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0/obj/Release/netstandard2.1 → FsToolkit.ErrorHandling.5.2.0/obj/Release/net9.0}/FsToolkit.ErrorHandling.AssemblyInfo.fs +4 -4
- package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/obj/Release/netstandard2.0/FsToolkit.ErrorHandling.AssemblyInfo.fs +4 -4
- package/dist/fable_modules/FsToolkit.ErrorHandling.5.2.0/obj/Release/netstandard2.1/FsToolkit.ErrorHandling.AssemblyInfo.fs +20 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Array.js +192 -86
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Async.js +58 -53
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/AsyncBuilder.js +29 -8
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/BigInt.js +71 -46
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/BitConverter.js +2 -2
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Boolean.js +4 -3
- package/dist/fable_modules/fable-library-js.5.17.2/CHANGELOG.md +348 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Char.js +64 -31
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Choice.js +2 -2
- package/dist/fable_modules/fable-library-js.5.17.2/CollectionUtil.js +182 -0
- package/dist/fable_modules/fable-library-js.5.17.2/ConditionalWeakTable.js +21 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Date.js +197 -112
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/DateOffset.js +46 -62
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/DateOnly.js +6 -6
- package/dist/fable_modules/fable-library-js.5.17.2/DateOnlyTemporal.js +146 -0
- package/dist/fable_modules/fable-library-js.5.17.2/DateTimeFormat.js +523 -0
- package/dist/fable_modules/fable-library-js.5.17.2/DateTimeOffsetTemporal.js +283 -0
- package/dist/fable_modules/fable-library-js.5.17.2/DateTimeTemporal.js +243 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Decimal.js +39 -13
- package/dist/fable_modules/fable-library-js.5.17.2/Directory.js +11 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Double.js +10 -3
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Encoding.js +20 -8
- package/dist/fable_modules/fable-library-js.5.17.2/Environment.js +3 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Event.js +10 -1
- package/dist/fable_modules/fable-library-js.5.17.2/FSharp.Collections.js +45 -0
- package/dist/fable_modules/fable-library-js.5.17.2/FSharp.Core.js +156 -0
- package/dist/fable_modules/fable-library-js.5.17.2/File.js +27 -0
- package/dist/fable_modules/fable-library-js.5.17.2/Global.js +29 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Guid.js +33 -12
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Int32.js +17 -17
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/List.js +170 -106
- package/dist/fable_modules/fable-library-js.5.17.2/Long.js +38 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/MailboxProcessor.js +13 -6
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Map.js +65 -61
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/MapUtil.js +22 -4
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/MutableMap.js +28 -16
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/MutableSet.js +7 -7
- package/dist/fable_modules/fable-library-js.5.17.2/Native.js +14 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Numeric.js +44 -3
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Observable.js +5 -3
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Option.js +11 -20
- package/dist/fable_modules/fable-library-js.5.17.2/Path.js +31 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Random.js +22 -20
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Range.js +12 -12
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Reflection.js +50 -22
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/RegExp.js +68 -30
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Result.js +6 -6
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Seq.js +229 -104
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Seq2.js +1 -1
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Set.js +153 -113
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/String.js +238 -50
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/System.Collections.Generic.js +30 -14
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/System.Text.js +69 -31
- package/dist/fable_modules/fable-library-js.5.17.2/System.js +289 -0
- package/dist/fable_modules/fable-library-js.5.17.2/Task.js +27 -0
- package/dist/fable_modules/fable-library-js.5.17.2/TaskBuilder.js +72 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/TimeOnly.js +6 -6
- package/dist/fable_modules/fable-library-js.5.17.2/TimeOnlyTemporal.js +142 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/TimeSpan.js +18 -15
- package/dist/fable_modules/fable-library-js.5.17.2/TimeSpanTemporal.js +259 -0
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Types.js +14 -24
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Uri.js +44 -21
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Util.js +49 -12
- package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/lib/big.js +14 -11
- package/dist/fable_modules/fable-library-js.5.17.2/package.json +24 -0
- package/dist/fable_modules/fable-library-js.5.17.2/quotation.js +682 -0
- package/package.json +4 -4
- package/src/Glutinum.Converter/js/bootstrap.js +109 -2
- package/src/Glutinum.Converter/js/host.js +144 -0
- package/src/Glutinum.Converter/js/npm.js +137 -0
- package/src/Glutinum.Converter/js/resolve.js +402 -0
- package/dist/Glutinum.Converter/FsharpAST.js.map +0 -1
- package/dist/Glutinum.Converter/Generate.js.map +0 -1
- package/dist/Glutinum.Converter/GlueAST.js.map +0 -1
- package/dist/Glutinum.Converter/Log.js.map +0 -1
- package/dist/Glutinum.Converter/Merge.js.map +0 -1
- package/dist/Glutinum.Converter/Printer.js.map +0 -1
- package/dist/Glutinum.Converter/Read.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/ClassDeclaration.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/Declaration.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/Documentation.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/EnumDeclaration.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/ExportAssignment.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/FunctionDeclaration.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/IndexedAccessType.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/InterfaceDeclaration.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/MappedTypeNode.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/ModuleDeclaration.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/NamedTupleMember.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/Node.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/Parameters.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/Report.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/TypeAliasDeclaration.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/TypeNode.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/TypeOperatorNode.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/TypeParameters.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/TypeQueryNode.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/TypeScriptReader.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/UnionTypeNode.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/Utils.js.map +0 -1
- package/dist/Glutinum.Converter/Reader/VariableStatement.js.map +0 -1
- package/dist/Glutinum.Converter/Transform.js.map +0 -1
- package/dist/Glutinum.Converter/TypeScript.Extensions.js.map +0 -1
- package/dist/Glutinum.Converter/TypeScript.js.map +0 -1
- package/dist/Glutinum.Converter/Utils/Keywords.js.map +0 -1
- package/dist/Glutinum.Converter/Utils/List.js.map +0 -1
- package/dist/Glutinum.Converter/Utils/Naming.js.map +0 -1
- package/dist/Glutinum.Converter/Utils/String.js.map +0 -1
- package/dist/Program.js.map +0 -1
- package/dist/fable_modules/Fable.Promise.3.2.0/AsyncIterable.fs +0 -57
- package/dist/fable_modules/Fable.Promise.3.2.0/AsyncIterable.fs.js.map +0 -1
- package/dist/fable_modules/Fable.Promise.3.2.0/Fable.Promise.fableproj +0 -20
- package/dist/fable_modules/Fable.Promise.3.2.0/Promise.fs.js.map +0 -1
- package/dist/fable_modules/Fable.Promise.3.2.0/PromiseImpl.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/Async.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/AsyncOptionCE.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/AsyncResultCE.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/AsyncResultOption.fs.js +0 -26
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/AsyncResultOption.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/AsyncResultOptionCE.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/AsyncValidationCE.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/FsToolkit.ErrorHandling.fableproj +0 -51
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/List.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/OptionCE.fs +0 -186
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/OptionCE.fs.js +0 -18
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/OptionCE.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/Result.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/ResultCE.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/ResultOption.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/ResultOptionCE.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/Seq.fs +0 -19
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/Seq.fs.js +0 -31
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/Seq.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/Shims.fs +0 -22
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/Shims.fs.js +0 -18
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/Shims.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/ValidationCE.fs.js.map +0 -1
- package/dist/fable_modules/FsToolkit.ErrorHandling.4.16.0/ValueOptionCE.fs +0 -165
- package/dist/fable_modules/fable-library-js.4.14.0/Array.d.ts +0 -123
- package/dist/fable_modules/fable-library-js.4.14.0/Async.d.ts +0 -32
- package/dist/fable_modules/fable-library-js.4.14.0/AsyncBuilder.d.ts +0 -59
- package/dist/fable_modules/fable-library-js.4.14.0/BigInt.d.ts +0 -115
- package/dist/fable_modules/fable-library-js.4.14.0/BitConverter.d.ts +0 -27
- package/dist/fable_modules/fable-library-js.4.14.0/Boolean.d.ts +0 -3
- package/dist/fable_modules/fable-library-js.4.14.0/CHANGELOG.md +0 -37
- package/dist/fable_modules/fable-library-js.4.14.0/Char.d.ts +0 -65
- package/dist/fable_modules/fable-library-js.4.14.0/Choice.d.ts +0 -121
- package/dist/fable_modules/fable-library-js.4.14.0/Date.d.ts +0 -70
- package/dist/fable_modules/fable-library-js.4.14.0/DateOffset.d.ts +0 -63
- package/dist/fable_modules/fable-library-js.4.14.0/DateOnly.d.ts +0 -18
- package/dist/fable_modules/fable-library-js.4.14.0/Decimal.d.ts +0 -45
- package/dist/fable_modules/fable-library-js.4.14.0/Double.d.ts +0 -11
- package/dist/fable_modules/fable-library-js.4.14.0/Encoding.d.ts +0 -12
- package/dist/fable_modules/fable-library-js.4.14.0/Event.d.ts +0 -31
- package/dist/fable_modules/fable-library-js.4.14.0/FSharp.Collections.d.ts +0 -7
- package/dist/fable_modules/fable-library-js.4.14.0/FSharp.Collections.js +0 -27
- package/dist/fable_modules/fable-library-js.4.14.0/FSharp.Core.CompilerServices.d.ts +0 -12
- package/dist/fable_modules/fable-library-js.4.14.0/FSharp.Core.d.ts +0 -17
- package/dist/fable_modules/fable-library-js.4.14.0/FSharp.Core.js +0 -69
- package/dist/fable_modules/fable-library-js.4.14.0/Global.d.ts +0 -24
- package/dist/fable_modules/fable-library-js.4.14.0/Global.js +0 -8
- package/dist/fable_modules/fable-library-js.4.14.0/Guid.d.ts +0 -10
- package/dist/fable_modules/fable-library-js.4.14.0/Int32.d.ts +0 -28
- package/dist/fable_modules/fable-library-js.4.14.0/List.d.ts +0 -143
- package/dist/fable_modules/fable-library-js.4.14.0/Long.d.ts +0 -3
- package/dist/fable_modules/fable-library-js.4.14.0/Long.js +0 -46
- package/dist/fable_modules/fable-library-js.4.14.0/MailboxProcessor.d.ts +0 -25
- package/dist/fable_modules/fable-library-js.4.14.0/Map.d.ts +0 -178
- package/dist/fable_modules/fable-library-js.4.14.0/MapUtil.d.ts +0 -10
- package/dist/fable_modules/fable-library-js.4.14.0/MutableMap.d.ts +0 -52
- package/dist/fable_modules/fable-library-js.4.14.0/MutableSet.d.ts +0 -39
- package/dist/fable_modules/fable-library-js.4.14.0/Native.d.ts +0 -2
- package/dist/fable_modules/fable-library-js.4.14.0/Native.js +0 -8
- package/dist/fable_modules/fable-library-js.4.14.0/Numeric.d.ts +0 -19
- package/dist/fable_modules/fable-library-js.4.14.0/Observable.d.ts +0 -32
- package/dist/fable_modules/fable-library-js.4.14.0/Option.d.ts +0 -28
- package/dist/fable_modules/fable-library-js.4.14.0/Random.d.ts +0 -37
- package/dist/fable_modules/fable-library-js.4.14.0/Range.d.ts +0 -12
- package/dist/fable_modules/fable-library-js.4.14.0/Reflection.d.ts +0 -119
- package/dist/fable_modules/fable-library-js.4.14.0/RegExp.d.ts +0 -10
- package/dist/fable_modules/fable-library-js.4.14.0/Result.d.ts +0 -37
- package/dist/fable_modules/fable-library-js.4.14.0/Seq.d.ts +0 -165
- package/dist/fable_modules/fable-library-js.4.14.0/Seq2.d.ts +0 -18
- package/dist/fable_modules/fable-library-js.4.14.0/Set.d.ts +0 -190
- package/dist/fable_modules/fable-library-js.4.14.0/String.d.ts +0 -50
- package/dist/fable_modules/fable-library-js.4.14.0/System.Collections.Generic.d.ts +0 -79
- package/dist/fable_modules/fable-library-js.4.14.0/System.Text.d.ts +0 -38
- package/dist/fable_modules/fable-library-js.4.14.0/SystemException.d.ts +0 -5
- package/dist/fable_modules/fable-library-js.4.14.0/SystemException.js +0 -5
- package/dist/fable_modules/fable-library-js.4.14.0/TimeOnly.d.ts +0 -15
- package/dist/fable_modules/fable-library-js.4.14.0/TimeSpan.d.ts +0 -34
- package/dist/fable_modules/fable-library-js.4.14.0/Timer.d.ts +0 -19
- package/dist/fable_modules/fable-library-js.4.14.0/Types.d.ts +0 -58
- package/dist/fable_modules/fable-library-js.4.14.0/Unicode.13.0.0.d.ts +0 -2
- package/dist/fable_modules/fable-library-js.4.14.0/Uri.d.ts +0 -29
- package/dist/fable_modules/fable-library-js.4.14.0/Util.d.ts +0 -207
- package/dist/fable_modules/fable-library-js.4.14.0/lib/big.d.ts +0 -5
- package/dist/fable_modules/fable-library-js.4.14.0/package.json +0 -24
- package/dist/fable_modules/project_cracked.json +0 -1
- /package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncOptionOp.fs +0 -0
- /package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncResultOp.fs +0 -0
- /package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncResultOptionOp.fs +0 -0
- /package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/AsyncValidationOp.fs +0 -0
- /package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ResultOp.fs +0 -0
- /package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ResultOptionOp.fs +0 -0
- /package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/ValidationOp.fs +0 -0
- /package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/obj/Debug/netstandard2.1/.NETStandard,Version=v2.1.AssemblyAttributes.fs +0 -0
- /package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/obj/Release/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.fs +0 -0
- /package/dist/fable_modules/{FsToolkit.ErrorHandling.4.16.0 → FsToolkit.ErrorHandling.5.2.0}/obj/Release/netstandard2.1/.NETStandard,Version=v2.1.AssemblyAttributes.fs +0 -0
- /package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/FSharp.Core.CompilerServices.js +0 -0
- /package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/README.md +0 -0
- /package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Timer.js +0 -0
- /package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/Unicode.13.0.0.js +0 -0
- /package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/big.d.ts +0 -0
package/dist/fable_modules/{fable-library-js.4.14.0 → fable-library-js.5.17.2}/System.Text.js
RENAMED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { replace, format, substring, isNullOrEmpty, join } from "./String.js";
|
|
1
|
+
import { replace, format, replicate, substring, isNullOrEmpty, join } from "./String.js";
|
|
2
2
|
import { class_type } from "./Reflection.js";
|
|
3
|
-
import { clear, int32ToString } from "./Util.js";
|
|
4
3
|
import { toString } from "./Types.js";
|
|
4
|
+
import { Exception, clear, int64ToString, int32ToString, int16ToString } from "./Util.js";
|
|
5
|
+
import { setItem, item } from "./Array.js";
|
|
5
6
|
export class StringBuilder {
|
|
6
7
|
constructor(value, capacity) {
|
|
7
8
|
this.buf = [];
|
|
@@ -15,7 +16,7 @@ export class StringBuilder {
|
|
|
15
16
|
}
|
|
16
17
|
}
|
|
17
18
|
export function StringBuilder_$reflection() {
|
|
18
|
-
return class_type("System.Text.StringBuilder",
|
|
19
|
+
return class_type("System.Text.StringBuilder", undefined, StringBuilder);
|
|
19
20
|
}
|
|
20
21
|
export function StringBuilder_$ctor_Z18115A39(value, capacity) {
|
|
21
22
|
return new StringBuilder(value, capacity);
|
|
@@ -30,21 +31,58 @@ export function StringBuilder_$ctor() {
|
|
|
30
31
|
return StringBuilder_$ctor_Z18115A39("", 16);
|
|
31
32
|
}
|
|
32
33
|
export function StringBuilder__Append_Z721C83C5(x, s) {
|
|
33
|
-
void (x.buf.push(s));
|
|
34
|
+
void (x.buf.push(toString(s)));
|
|
34
35
|
return x;
|
|
35
36
|
}
|
|
36
37
|
export function StringBuilder__Append_487EF8FB(x, s, startIndex, count) {
|
|
37
|
-
void (x.buf.push(substring(s, startIndex, count)));
|
|
38
|
+
void (x.buf.push(substring(toString(s), startIndex, count)));
|
|
38
39
|
return x;
|
|
39
40
|
}
|
|
40
41
|
export function StringBuilder__Append_244C7CD6(x, c) {
|
|
41
42
|
void (x.buf.push(c));
|
|
42
43
|
return x;
|
|
43
44
|
}
|
|
45
|
+
export function StringBuilder__Append_61B1CA(x, c, repeatCount) {
|
|
46
|
+
const s = replicate(repeatCount, c);
|
|
47
|
+
void (x.buf.push(s));
|
|
48
|
+
return x;
|
|
49
|
+
}
|
|
50
|
+
export function StringBuilder__Append_Z510FF069(x, o) {
|
|
51
|
+
void (x.buf.push(o.toString()));
|
|
52
|
+
return x;
|
|
53
|
+
}
|
|
54
|
+
export function StringBuilder__Append_244D3E44(x, o) {
|
|
55
|
+
void (x.buf.push(o.toString()));
|
|
56
|
+
return x;
|
|
57
|
+
}
|
|
58
|
+
export function StringBuilder__Append_Z524259E6(x, o) {
|
|
59
|
+
void (x.buf.push(int16ToString(o)));
|
|
60
|
+
return x;
|
|
61
|
+
}
|
|
62
|
+
export function StringBuilder__Append_Z6EF82811(x, o) {
|
|
63
|
+
void (x.buf.push(o.toString()));
|
|
64
|
+
return x;
|
|
65
|
+
}
|
|
44
66
|
export function StringBuilder__Append_Z524259A4(x, o) {
|
|
45
67
|
void (x.buf.push(int32ToString(o)));
|
|
46
68
|
return x;
|
|
47
69
|
}
|
|
70
|
+
export function StringBuilder__Append_Z6EF827D7(x, o) {
|
|
71
|
+
void (x.buf.push(o.toString()));
|
|
72
|
+
return x;
|
|
73
|
+
}
|
|
74
|
+
export function StringBuilder__Append_Z524259C1(x, o) {
|
|
75
|
+
void (x.buf.push(int64ToString(o)));
|
|
76
|
+
return x;
|
|
77
|
+
}
|
|
78
|
+
export function StringBuilder__Append_Z6EF827B6(x, o) {
|
|
79
|
+
void (x.buf.push(o.toString()));
|
|
80
|
+
return x;
|
|
81
|
+
}
|
|
82
|
+
export function StringBuilder__Append_Z7138B98C(x, o) {
|
|
83
|
+
void (x.buf.push(o.toString()));
|
|
84
|
+
return x;
|
|
85
|
+
}
|
|
48
86
|
export function StringBuilder__Append_5E38073B(x, o) {
|
|
49
87
|
void (x.buf.push(o.toString()));
|
|
50
88
|
return x;
|
|
@@ -62,7 +100,7 @@ export function StringBuilder__Append_Z372E4D23(x, cs) {
|
|
|
62
100
|
return x;
|
|
63
101
|
}
|
|
64
102
|
export function StringBuilder__Append_43A65C09(x, s) {
|
|
65
|
-
void (x.buf.push(toString(
|
|
103
|
+
void (x.buf.push(s.toString()));
|
|
66
104
|
return x;
|
|
67
105
|
}
|
|
68
106
|
export function StringBuilder__AppendFormat_433E080(x, fmt, o) {
|
|
@@ -112,51 +150,51 @@ export function StringBuilder__Clear(x) {
|
|
|
112
150
|
}
|
|
113
151
|
export function StringBuilder__get_Chars_Z524259A4(x, index) {
|
|
114
152
|
let len = 0;
|
|
115
|
-
let i =
|
|
116
|
-
while ((
|
|
153
|
+
let i = 0;
|
|
154
|
+
while ((i < x.buf.length) && ((len + item(i, x.buf).length) <= index)) {
|
|
155
|
+
len = ((len + item(i, x.buf).length) | 0);
|
|
117
156
|
i = ((i + 1) | 0);
|
|
118
|
-
len = ((len + x.buf[i].length) | 0);
|
|
119
157
|
}
|
|
120
|
-
if ((
|
|
121
|
-
throw new
|
|
158
|
+
if ((index < 0) ? true : (i >= x.buf.length)) {
|
|
159
|
+
throw new Exception("Index was outside the bounds of the array");
|
|
122
160
|
}
|
|
123
161
|
else {
|
|
124
|
-
const pos = (
|
|
125
|
-
return x.buf[
|
|
162
|
+
const pos = (index - len) | 0;
|
|
163
|
+
return item(i, x.buf)[pos];
|
|
126
164
|
}
|
|
127
165
|
}
|
|
128
166
|
export function StringBuilder__set_Chars_413E0D0A(x, index, value) {
|
|
129
167
|
let len = 0;
|
|
130
|
-
let i =
|
|
131
|
-
while ((
|
|
168
|
+
let i = 0;
|
|
169
|
+
while ((i < x.buf.length) && ((len + item(i, x.buf).length) <= index)) {
|
|
170
|
+
len = ((len + item(i, x.buf).length) | 0);
|
|
132
171
|
i = ((i + 1) | 0);
|
|
133
|
-
len = ((len + x.buf[i].length) | 0);
|
|
134
172
|
}
|
|
135
|
-
if ((
|
|
136
|
-
throw new
|
|
173
|
+
if ((index < 0) ? true : (i >= x.buf.length)) {
|
|
174
|
+
throw new Exception("Index was outside the bounds of the array");
|
|
137
175
|
}
|
|
138
176
|
else {
|
|
139
|
-
const pos = (
|
|
140
|
-
x.buf
|
|
177
|
+
const pos = (index - len) | 0;
|
|
178
|
+
setItem(x.buf, i, (item(i, x.buf).slice(0, (pos - 1) + 1) + value) + item(i, x.buf).slice(pos + 1, item(i, x.buf).length));
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
export function StringBuilder__get_Length(x) {
|
|
182
|
+
let len = 0;
|
|
183
|
+
for (let i = x.buf.length - 1; i >= 0; i--) {
|
|
184
|
+
len = ((len + item(i, x.buf).length) | 0);
|
|
141
185
|
}
|
|
186
|
+
return len | 0;
|
|
142
187
|
}
|
|
143
188
|
export function StringBuilder__Replace_Z766F94C0(x, oldValue, newValue) {
|
|
144
189
|
for (let i = x.buf.length - 1; i >= 0; i--) {
|
|
145
|
-
x.buf
|
|
190
|
+
setItem(x.buf, i, replace(item(i, x.buf), oldValue, newValue));
|
|
146
191
|
}
|
|
147
192
|
return x;
|
|
148
193
|
}
|
|
149
194
|
export function StringBuilder__Replace_Z384F8060(x, oldValue, newValue) {
|
|
150
|
-
const str = replace(toString(
|
|
195
|
+
const str = replace(x.toString(), oldValue, newValue);
|
|
151
196
|
return StringBuilder__Append_Z721C83C5(StringBuilder__Clear(x), str);
|
|
152
197
|
}
|
|
153
|
-
export function
|
|
154
|
-
|
|
155
|
-
for (let i = x.buf.length - 1; i >= 0; i--) {
|
|
156
|
-
len = ((len + x.buf[i].length) | 0);
|
|
157
|
-
}
|
|
158
|
-
return len | 0;
|
|
159
|
-
}
|
|
160
|
-
export function StringBuilder__ToString_Z37302880(x, firstIndex, length) {
|
|
161
|
-
return substring(toString(x), firstIndex, length);
|
|
198
|
+
export function StringBuilder__ToString_Z37302880(x, startIndex, length) {
|
|
199
|
+
return substring(x.toString(), startIndex, length);
|
|
162
200
|
}
|
|
@@ -0,0 +1,289 @@
|
|
|
1
|
+
import { defaultOf, Exception } from "./Util.js";
|
|
2
|
+
import { class_type } from "./Reflection.js";
|
|
3
|
+
import { SR_Arg_ArgumentOutOfRangeException, SR_ArgumentNull_Generic, SR_Arg_ArgumentException, SR_Arg_ParamName_Name, SR_Arg_TimeoutException, SR_Arg_StackOverflowException, SR_Arg_RankException, SR_Arg_OverflowException, SR_Arg_OutOfMemoryException, SR_Arg_NullReferenceException, SR_Arg_NotSupportedException, SR_Arg_NotImplementedException, SR_Arg_NotFiniteNumberException, SR_Arg_InvalidOperationException, SR_Arg_IndexOutOfRangeException, SR_Arg_FormatException, SR_Arg_DivideByZero, SR_Arg_ArithmeticException, SR_Arg_ApplicationException, SR_Arg_SystemException } from "./Global.js";
|
|
4
|
+
import { isNullOrEmpty } from "./String.js";
|
|
5
|
+
export class SystemException extends Exception {
|
|
6
|
+
constructor(message) {
|
|
7
|
+
super(message);
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
export function SystemException_$reflection() {
|
|
11
|
+
return class_type("System.SystemException", undefined, SystemException, class_type("System.Exception"));
|
|
12
|
+
}
|
|
13
|
+
export function SystemException_$ctor_Z721C83C5(message) {
|
|
14
|
+
return new SystemException(message);
|
|
15
|
+
}
|
|
16
|
+
export function SystemException_$ctor() {
|
|
17
|
+
return SystemException_$ctor_Z721C83C5(SR_Arg_SystemException);
|
|
18
|
+
}
|
|
19
|
+
export class ApplicationException extends Exception {
|
|
20
|
+
constructor(message) {
|
|
21
|
+
super(message);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
export function ApplicationException_$reflection() {
|
|
25
|
+
return class_type("System.ApplicationException", undefined, ApplicationException, class_type("System.Exception"));
|
|
26
|
+
}
|
|
27
|
+
export function ApplicationException_$ctor_Z721C83C5(message) {
|
|
28
|
+
return new ApplicationException(message);
|
|
29
|
+
}
|
|
30
|
+
export function ApplicationException_$ctor() {
|
|
31
|
+
return ApplicationException_$ctor_Z721C83C5(SR_Arg_ApplicationException);
|
|
32
|
+
}
|
|
33
|
+
export class ArithmeticException extends Exception {
|
|
34
|
+
constructor(message) {
|
|
35
|
+
super(message);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
export function ArithmeticException_$reflection() {
|
|
39
|
+
return class_type("System.ArithmeticException", undefined, ArithmeticException, class_type("System.Exception"));
|
|
40
|
+
}
|
|
41
|
+
export function ArithmeticException_$ctor_Z721C83C5(message) {
|
|
42
|
+
return new ArithmeticException(message);
|
|
43
|
+
}
|
|
44
|
+
export function ArithmeticException_$ctor() {
|
|
45
|
+
return ArithmeticException_$ctor_Z721C83C5(SR_Arg_ArithmeticException);
|
|
46
|
+
}
|
|
47
|
+
export class DivideByZeroException extends Exception {
|
|
48
|
+
constructor(message) {
|
|
49
|
+
super(message);
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
export function DivideByZeroException_$reflection() {
|
|
53
|
+
return class_type("System.DivideByZeroException", undefined, DivideByZeroException, class_type("System.Exception"));
|
|
54
|
+
}
|
|
55
|
+
export function DivideByZeroException_$ctor_Z721C83C5(message) {
|
|
56
|
+
return new DivideByZeroException(message);
|
|
57
|
+
}
|
|
58
|
+
export function DivideByZeroException_$ctor() {
|
|
59
|
+
return DivideByZeroException_$ctor_Z721C83C5(SR_Arg_DivideByZero);
|
|
60
|
+
}
|
|
61
|
+
export class FormatException extends Exception {
|
|
62
|
+
constructor(message) {
|
|
63
|
+
super(message);
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
export function FormatException_$reflection() {
|
|
67
|
+
return class_type("System.FormatException", undefined, FormatException, class_type("System.Exception"));
|
|
68
|
+
}
|
|
69
|
+
export function FormatException_$ctor_Z721C83C5(message) {
|
|
70
|
+
return new FormatException(message);
|
|
71
|
+
}
|
|
72
|
+
export function FormatException_$ctor() {
|
|
73
|
+
return FormatException_$ctor_Z721C83C5(SR_Arg_FormatException);
|
|
74
|
+
}
|
|
75
|
+
export class IndexOutOfRangeException extends Exception {
|
|
76
|
+
constructor(message) {
|
|
77
|
+
super(message);
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
export function IndexOutOfRangeException_$reflection() {
|
|
81
|
+
return class_type("System.IndexOutOfRangeException", undefined, IndexOutOfRangeException, class_type("System.Exception"));
|
|
82
|
+
}
|
|
83
|
+
export function IndexOutOfRangeException_$ctor_Z721C83C5(message) {
|
|
84
|
+
return new IndexOutOfRangeException(message);
|
|
85
|
+
}
|
|
86
|
+
export function IndexOutOfRangeException_$ctor() {
|
|
87
|
+
return IndexOutOfRangeException_$ctor_Z721C83C5(SR_Arg_IndexOutOfRangeException);
|
|
88
|
+
}
|
|
89
|
+
export class InvalidOperationException extends Exception {
|
|
90
|
+
constructor(message) {
|
|
91
|
+
super(message);
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
export function InvalidOperationException_$reflection() {
|
|
95
|
+
return class_type("System.InvalidOperationException", undefined, InvalidOperationException, class_type("System.Exception"));
|
|
96
|
+
}
|
|
97
|
+
export function InvalidOperationException_$ctor_Z721C83C5(message) {
|
|
98
|
+
return new InvalidOperationException(message);
|
|
99
|
+
}
|
|
100
|
+
export function InvalidOperationException_$ctor() {
|
|
101
|
+
return InvalidOperationException_$ctor_Z721C83C5(SR_Arg_InvalidOperationException);
|
|
102
|
+
}
|
|
103
|
+
export class NotFiniteNumberException extends Exception {
|
|
104
|
+
constructor(message) {
|
|
105
|
+
super(message);
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
export function NotFiniteNumberException_$reflection() {
|
|
109
|
+
return class_type("System.NotFiniteNumberException", undefined, NotFiniteNumberException, class_type("System.Exception"));
|
|
110
|
+
}
|
|
111
|
+
export function NotFiniteNumberException_$ctor_Z721C83C5(message) {
|
|
112
|
+
return new NotFiniteNumberException(message);
|
|
113
|
+
}
|
|
114
|
+
export function NotFiniteNumberException_$ctor() {
|
|
115
|
+
return NotFiniteNumberException_$ctor_Z721C83C5(SR_Arg_NotFiniteNumberException);
|
|
116
|
+
}
|
|
117
|
+
export class NotImplementedException extends Exception {
|
|
118
|
+
constructor(message) {
|
|
119
|
+
super(message);
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
export function NotImplementedException_$reflection() {
|
|
123
|
+
return class_type("System.NotImplementedException", undefined, NotImplementedException, class_type("System.Exception"));
|
|
124
|
+
}
|
|
125
|
+
export function NotImplementedException_$ctor_Z721C83C5(message) {
|
|
126
|
+
return new NotImplementedException(message);
|
|
127
|
+
}
|
|
128
|
+
export function NotImplementedException_$ctor() {
|
|
129
|
+
return NotImplementedException_$ctor_Z721C83C5(SR_Arg_NotImplementedException);
|
|
130
|
+
}
|
|
131
|
+
export class NotSupportedException extends Exception {
|
|
132
|
+
constructor(message) {
|
|
133
|
+
super(message);
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
export function NotSupportedException_$reflection() {
|
|
137
|
+
return class_type("System.NotSupportedException", undefined, NotSupportedException, class_type("System.Exception"));
|
|
138
|
+
}
|
|
139
|
+
export function NotSupportedException_$ctor_Z721C83C5(message) {
|
|
140
|
+
return new NotSupportedException(message);
|
|
141
|
+
}
|
|
142
|
+
export function NotSupportedException_$ctor() {
|
|
143
|
+
return NotSupportedException_$ctor_Z721C83C5(SR_Arg_NotSupportedException);
|
|
144
|
+
}
|
|
145
|
+
export class NullReferenceException extends Exception {
|
|
146
|
+
constructor(message) {
|
|
147
|
+
super(message);
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
export function NullReferenceException_$reflection() {
|
|
151
|
+
return class_type("System.NullReferenceException", undefined, NullReferenceException, class_type("System.Exception"));
|
|
152
|
+
}
|
|
153
|
+
export function NullReferenceException_$ctor_Z721C83C5(message) {
|
|
154
|
+
return new NullReferenceException(message);
|
|
155
|
+
}
|
|
156
|
+
export function NullReferenceException_$ctor() {
|
|
157
|
+
return NullReferenceException_$ctor_Z721C83C5(SR_Arg_NullReferenceException);
|
|
158
|
+
}
|
|
159
|
+
export class OutOfMemoryException extends Exception {
|
|
160
|
+
constructor(message) {
|
|
161
|
+
super(message);
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
export function OutOfMemoryException_$reflection() {
|
|
165
|
+
return class_type("System.OutOfMemoryException", undefined, OutOfMemoryException, class_type("System.Exception"));
|
|
166
|
+
}
|
|
167
|
+
export function OutOfMemoryException_$ctor_Z721C83C5(message) {
|
|
168
|
+
return new OutOfMemoryException(message);
|
|
169
|
+
}
|
|
170
|
+
export function OutOfMemoryException_$ctor() {
|
|
171
|
+
return OutOfMemoryException_$ctor_Z721C83C5(SR_Arg_OutOfMemoryException);
|
|
172
|
+
}
|
|
173
|
+
export class OverflowException extends Exception {
|
|
174
|
+
constructor(message) {
|
|
175
|
+
super(message);
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
export function OverflowException_$reflection() {
|
|
179
|
+
return class_type("System.OverflowException", undefined, OverflowException, class_type("System.Exception"));
|
|
180
|
+
}
|
|
181
|
+
export function OverflowException_$ctor_Z721C83C5(message) {
|
|
182
|
+
return new OverflowException(message);
|
|
183
|
+
}
|
|
184
|
+
export function OverflowException_$ctor() {
|
|
185
|
+
return OverflowException_$ctor_Z721C83C5(SR_Arg_OverflowException);
|
|
186
|
+
}
|
|
187
|
+
export class RankException extends Exception {
|
|
188
|
+
constructor(message) {
|
|
189
|
+
super(message);
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
export function RankException_$reflection() {
|
|
193
|
+
return class_type("System.RankException", undefined, RankException, class_type("System.Exception"));
|
|
194
|
+
}
|
|
195
|
+
export function RankException_$ctor_Z721C83C5(message) {
|
|
196
|
+
return new RankException(message);
|
|
197
|
+
}
|
|
198
|
+
export function RankException_$ctor() {
|
|
199
|
+
return RankException_$ctor_Z721C83C5(SR_Arg_RankException);
|
|
200
|
+
}
|
|
201
|
+
export class StackOverflowException extends Exception {
|
|
202
|
+
constructor(message) {
|
|
203
|
+
super(message);
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
export function StackOverflowException_$reflection() {
|
|
207
|
+
return class_type("System.StackOverflowException", undefined, StackOverflowException, class_type("System.Exception"));
|
|
208
|
+
}
|
|
209
|
+
export function StackOverflowException_$ctor_Z721C83C5(message) {
|
|
210
|
+
return new StackOverflowException(message);
|
|
211
|
+
}
|
|
212
|
+
export function StackOverflowException_$ctor() {
|
|
213
|
+
return StackOverflowException_$ctor_Z721C83C5(SR_Arg_StackOverflowException);
|
|
214
|
+
}
|
|
215
|
+
export class TimeoutException extends Exception {
|
|
216
|
+
constructor(message) {
|
|
217
|
+
super(message);
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
export function TimeoutException_$reflection() {
|
|
221
|
+
return class_type("System.TimeoutException", undefined, TimeoutException, class_type("System.Exception"));
|
|
222
|
+
}
|
|
223
|
+
export function TimeoutException_$ctor_Z721C83C5(message) {
|
|
224
|
+
return new TimeoutException(message);
|
|
225
|
+
}
|
|
226
|
+
export function TimeoutException_$ctor() {
|
|
227
|
+
return TimeoutException_$ctor_Z721C83C5(SR_Arg_TimeoutException);
|
|
228
|
+
}
|
|
229
|
+
export class ArgumentException extends Exception {
|
|
230
|
+
constructor(message, paramName, innerException) {
|
|
231
|
+
super(isNullOrEmpty(paramName) ? message : (((message + SR_Arg_ParamName_Name) + paramName) + "\')"), innerException);
|
|
232
|
+
this.paramName = paramName;
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
export function ArgumentException_$reflection() {
|
|
236
|
+
return class_type("System.ArgumentException", undefined, ArgumentException, class_type("System.Exception"));
|
|
237
|
+
}
|
|
238
|
+
export function ArgumentException_$ctor_Z60A2B367(message, paramName, innerException) {
|
|
239
|
+
return new ArgumentException(message, paramName, innerException);
|
|
240
|
+
}
|
|
241
|
+
export function ArgumentException_$ctor() {
|
|
242
|
+
return ArgumentException_$ctor_Z60A2B367(SR_Arg_ArgumentException, "", defaultOf());
|
|
243
|
+
}
|
|
244
|
+
export function ArgumentException_$ctor_Z721C83C5(message) {
|
|
245
|
+
return ArgumentException_$ctor_Z60A2B367(message, "", defaultOf());
|
|
246
|
+
}
|
|
247
|
+
export function ArgumentException_$ctor_Z384F8060(message, paramName) {
|
|
248
|
+
return ArgumentException_$ctor_Z60A2B367(message, paramName, defaultOf());
|
|
249
|
+
}
|
|
250
|
+
export function ArgumentException_$ctor_68CE3CA2(message, innerException) {
|
|
251
|
+
return ArgumentException_$ctor_Z60A2B367(message, "", innerException);
|
|
252
|
+
}
|
|
253
|
+
export function ArgumentException__get_ParamName(_) {
|
|
254
|
+
return _.paramName;
|
|
255
|
+
}
|
|
256
|
+
export class ArgumentNullException extends ArgumentException {
|
|
257
|
+
constructor(paramName, message) {
|
|
258
|
+
super(message, paramName, defaultOf());
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
export function ArgumentNullException_$reflection() {
|
|
262
|
+
return class_type("System.ArgumentNullException", undefined, ArgumentNullException, ArgumentException_$reflection());
|
|
263
|
+
}
|
|
264
|
+
export function ArgumentNullException_$ctor_Z384F8060(paramName, message) {
|
|
265
|
+
return new ArgumentNullException(paramName, message);
|
|
266
|
+
}
|
|
267
|
+
export function ArgumentNullException_$ctor_Z721C83C5(paramName) {
|
|
268
|
+
return ArgumentNullException_$ctor_Z384F8060(paramName, SR_ArgumentNull_Generic);
|
|
269
|
+
}
|
|
270
|
+
export function ArgumentNullException_$ctor() {
|
|
271
|
+
return ArgumentNullException_$ctor_Z721C83C5("");
|
|
272
|
+
}
|
|
273
|
+
export class ArgumentOutOfRangeException extends ArgumentException {
|
|
274
|
+
constructor(paramName, message) {
|
|
275
|
+
super(message, paramName, defaultOf());
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
export function ArgumentOutOfRangeException_$reflection() {
|
|
279
|
+
return class_type("System.ArgumentOutOfRangeException", undefined, ArgumentOutOfRangeException, ArgumentException_$reflection());
|
|
280
|
+
}
|
|
281
|
+
export function ArgumentOutOfRangeException_$ctor_Z384F8060(paramName, message) {
|
|
282
|
+
return new ArgumentOutOfRangeException(paramName, message);
|
|
283
|
+
}
|
|
284
|
+
export function ArgumentOutOfRangeException_$ctor_Z721C83C5(paramName) {
|
|
285
|
+
return ArgumentOutOfRangeException_$ctor_Z384F8060(paramName, SR_Arg_ArgumentOutOfRangeException);
|
|
286
|
+
}
|
|
287
|
+
export function ArgumentOutOfRangeException_$ctor() {
|
|
288
|
+
return ArgumentOutOfRangeException_$ctor_Z721C83C5("");
|
|
289
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { OperationCanceledException } from "./AsyncBuilder.js";
|
|
2
|
+
export class TaskCompletionSource {
|
|
3
|
+
constructor() {
|
|
4
|
+
this.task = new Promise((resolve, reject) => {
|
|
5
|
+
this._resolve = resolve;
|
|
6
|
+
this._reject = reject;
|
|
7
|
+
});
|
|
8
|
+
}
|
|
9
|
+
SetResult(value) { this._resolve(value); }
|
|
10
|
+
SetException(error) { this._reject(error); }
|
|
11
|
+
SetCancelled() { this._reject(new OperationCanceledException()); }
|
|
12
|
+
get_Task() { return this.task; }
|
|
13
|
+
}
|
|
14
|
+
export function fromResult(value) {
|
|
15
|
+
return Promise.resolve(value);
|
|
16
|
+
}
|
|
17
|
+
export function zero() {
|
|
18
|
+
return Promise.resolve();
|
|
19
|
+
}
|
|
20
|
+
// Task<T> = Promise<T> in JS/TS. GetAwaiter/GetResult return the Promise itself;
|
|
21
|
+
// callers should use Async.AwaitTask to extract the value in an async context.
|
|
22
|
+
export function getAwaiter(t) {
|
|
23
|
+
return t;
|
|
24
|
+
}
|
|
25
|
+
export function getResult(t) {
|
|
26
|
+
return t;
|
|
27
|
+
}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import { zero } from "./Task.js";
|
|
2
|
+
export class TaskBuilder {
|
|
3
|
+
Bind(computation, binder) {
|
|
4
|
+
return computation.then(binder);
|
|
5
|
+
}
|
|
6
|
+
Combine(computation1, computation2) {
|
|
7
|
+
return computation1.then(computation2);
|
|
8
|
+
}
|
|
9
|
+
Delay(generator) {
|
|
10
|
+
return generator;
|
|
11
|
+
}
|
|
12
|
+
For(sequence, body) {
|
|
13
|
+
const iter = sequence[Symbol.iterator]();
|
|
14
|
+
let cur = iter.next();
|
|
15
|
+
return this.While(() => !cur.done, this.Delay(() => {
|
|
16
|
+
const res = body(cur.value);
|
|
17
|
+
cur = iter.next();
|
|
18
|
+
return res;
|
|
19
|
+
}));
|
|
20
|
+
}
|
|
21
|
+
Return(value) {
|
|
22
|
+
return Promise.resolve(value);
|
|
23
|
+
}
|
|
24
|
+
ReturnFrom(computation) {
|
|
25
|
+
return computation;
|
|
26
|
+
}
|
|
27
|
+
TryFinally(computation, compensation) {
|
|
28
|
+
try {
|
|
29
|
+
return computation().finally(compensation);
|
|
30
|
+
}
|
|
31
|
+
catch (e) {
|
|
32
|
+
compensation();
|
|
33
|
+
return Promise.reject(e);
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
TryWith(computation, catchHandler) {
|
|
37
|
+
try {
|
|
38
|
+
return computation().catch(catchHandler);
|
|
39
|
+
}
|
|
40
|
+
catch (e) {
|
|
41
|
+
try {
|
|
42
|
+
return catchHandler(e);
|
|
43
|
+
}
|
|
44
|
+
catch (e2) {
|
|
45
|
+
return Promise.reject(e2);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
Using(resource, binder) {
|
|
50
|
+
return this.TryFinally(() => binder(resource), () => resource.Dispose());
|
|
51
|
+
}
|
|
52
|
+
While(guard, computation) {
|
|
53
|
+
return (async () => {
|
|
54
|
+
while (guard()) {
|
|
55
|
+
await computation();
|
|
56
|
+
}
|
|
57
|
+
})();
|
|
58
|
+
}
|
|
59
|
+
Zero() {
|
|
60
|
+
return zero();
|
|
61
|
+
}
|
|
62
|
+
Run(computation) {
|
|
63
|
+
try {
|
|
64
|
+
return computation();
|
|
65
|
+
}
|
|
66
|
+
catch (e) {
|
|
67
|
+
return Promise.reject(e);
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
export const singleton = new TaskBuilder();
|
|
72
|
+
export function task() { return singleton; }
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { hours, minutes, seconds, milliseconds } from "./TimeSpan.js";
|
|
2
|
-
import { padWithZeros } from "./Util.js";
|
|
2
|
+
import { Exception, DateTimeKind, padWithZeros } from "./Util.js";
|
|
3
3
|
const millisecondsPerDay = 86400000;
|
|
4
4
|
export function create(h = 0, m = 0, s = 0, ms = 0) {
|
|
5
5
|
if (h < 0 || m < 0 || s < 0 || ms < 0)
|
|
6
|
-
throw new
|
|
6
|
+
throw new Exception("The parameters describe an unrepresentable TimeOnly.");
|
|
7
7
|
return h * 3600000 + m * 60000 + s * 1000 + ms;
|
|
8
8
|
}
|
|
9
9
|
export function fromTicks(ticks) {
|
|
@@ -11,11 +11,11 @@ export function fromTicks(ticks) {
|
|
|
11
11
|
}
|
|
12
12
|
export function fromTimeSpan(timeSpan) {
|
|
13
13
|
if (timeSpan < 0 || timeSpan >= millisecondsPerDay)
|
|
14
|
-
throw new
|
|
14
|
+
throw new Exception("The TimeSpan describes an unrepresentable TimeOnly.");
|
|
15
15
|
return timeSpan;
|
|
16
16
|
}
|
|
17
17
|
export function fromDateTime(d) {
|
|
18
|
-
return d.kind ===
|
|
18
|
+
return d.kind === DateTimeKind.Utc
|
|
19
19
|
? create(d.getUTCHours(), d.getUTCMinutes(), d.getUTCSeconds(), d.getUTCMilliseconds())
|
|
20
20
|
: create(d.getHours(), d.getMinutes(), d.getSeconds(), d.getMilliseconds());
|
|
21
21
|
}
|
|
@@ -55,7 +55,7 @@ export function isBetween(t, start, end) {
|
|
|
55
55
|
}
|
|
56
56
|
export function toString(t, format = "t", _provider) {
|
|
57
57
|
if (["r", "R", "o", "O", "t", "T"].indexOf(format) === -1) {
|
|
58
|
-
throw new
|
|
58
|
+
throw new Exception("Custom formats are not supported");
|
|
59
59
|
}
|
|
60
60
|
const base = `${padWithZeros(hours(t), 2)}:${padWithZeros(minutes(t), 2)}`;
|
|
61
61
|
if (format === "t")
|
|
@@ -106,7 +106,7 @@ export function parse(str) {
|
|
|
106
106
|
}
|
|
107
107
|
return create(h, m, s, Math.trunc(ms));
|
|
108
108
|
}
|
|
109
|
-
throw new
|
|
109
|
+
throw new Exception(`String '${str}' was not recognized as a valid TimeOnly.`);
|
|
110
110
|
}
|
|
111
111
|
export function tryParse(v, defValue) {
|
|
112
112
|
try {
|