@nfdi4plants/arctrl 1.0.7 → 1.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/ARC.js +47 -11
- package/Contract/Contract.js +3 -3
- package/Contracts/Contracts.ArcTypes.js +30 -18
- package/Contracts/Contracts.Git.js +4 -4
- package/FileSystem/Commit.js +2 -2
- package/FileSystem/FileSystem.js +4 -4
- package/FileSystem/FileSystemTree.js +8 -8
- package/FileSystem/Path.js +2 -2
- package/FileSystemTree.js +1 -1
- package/ISA/ISA/ArcTypes/ArcTable.js +23 -31
- package/ISA/ISA/ArcTypes/ArcTableAux.js +27 -16
- package/ISA/ISA/ArcTypes/ArcTables.js +11 -11
- package/ISA/ISA/ArcTypes/ArcTypes.js +118 -83
- package/ISA/ISA/ArcTypes/CompositeCell.js +4 -4
- package/ISA/ISA/ArcTypes/CompositeColumn.js +8 -7
- package/ISA/ISA/ArcTypes/CompositeHeader.js +5 -5
- package/ISA/ISA/ArcTypes/CompositeRow.js +1 -1
- package/ISA/ISA/Builder/Types.js +5 -5
- package/ISA/ISA/Fable.js +6 -6
- package/ISA/ISA/Helper.js +15 -13
- package/ISA/ISA/Identifier.js +1 -1
- package/ISA/ISA/JsonTypes/Assay.js +8 -8
- package/ISA/ISA/JsonTypes/AssayMaterials.js +4 -4
- package/ISA/ISA/JsonTypes/ColumnIndex.js +5 -5
- package/ISA/ISA/JsonTypes/Comment.js +3 -3
- package/ISA/ISA/JsonTypes/CommentList.js +4 -4
- package/ISA/ISA/JsonTypes/Component.js +4 -4
- package/ISA/ISA/JsonTypes/Data.js +4 -4
- package/ISA/ISA/JsonTypes/DataFile.js +2 -2
- package/ISA/ISA/JsonTypes/Factor.js +6 -6
- package/ISA/ISA/JsonTypes/FactorValue.js +5 -5
- package/ISA/ISA/JsonTypes/Investigation.js +6 -6
- package/ISA/ISA/JsonTypes/Material.js +5 -5
- package/ISA/ISA/JsonTypes/MaterialAttribute.js +3 -3
- package/ISA/ISA/JsonTypes/MaterialAttributeValue.js +5 -5
- package/ISA/ISA/JsonTypes/MaterialType.js +2 -2
- package/ISA/ISA/JsonTypes/OntologyAnnotation.js +6 -6
- package/ISA/ISA/JsonTypes/OntologySourceReference.js +6 -6
- package/ISA/ISA/JsonTypes/Person.js +23 -8
- package/ISA/ISA/JsonTypes/Process.js +13 -13
- package/ISA/ISA/JsonTypes/ProcessInput.js +5 -5
- package/ISA/ISA/JsonTypes/ProcessOutput.js +5 -5
- package/ISA/ISA/JsonTypes/ProcessParameterValue.js +5 -5
- package/ISA/ISA/JsonTypes/ProcessSequence.js +6 -6
- package/ISA/ISA/JsonTypes/Protocol.js +6 -6
- package/ISA/ISA/JsonTypes/ProtocolParameter.js +3 -3
- package/ISA/ISA/JsonTypes/Publication.js +6 -6
- package/ISA/ISA/JsonTypes/Sample.js +5 -5
- package/ISA/ISA/JsonTypes/Source.js +5 -5
- package/ISA/ISA/JsonTypes/Study.js +8 -8
- package/ISA/ISA/JsonTypes/StudyMaterials.js +4 -4
- package/ISA/ISA/JsonTypes/Value.js +22 -29
- package/ISA/ISA/Regex.js +3 -3
- package/ISA/ISA.Json/ArcTypes/ArcAssay.js +157 -65
- package/ISA/ISA.Json/ArcTypes/ArcInvestigation.js +78 -49
- package/ISA/ISA.Json/ArcTypes/ArcStudy.js +136 -24
- package/ISA/ISA.Json/ArcTypes/ArcTable.js +183 -21
- package/ISA/ISA.Json/ArcTypes/CellTable.js +40 -0
- package/ISA/ISA.Json/ArcTypes/CompositeCell.js +34 -23
- package/ISA/ISA.Json/ArcTypes/CompositeHeader.js +18 -46
- package/ISA/ISA.Json/ArcTypes/IOType.js +11 -13
- package/ISA/ISA.Json/ArcTypes/OATable.js +42 -0
- package/ISA/ISA.Json/Assay.js +71 -47
- package/ISA/ISA.Json/Comment.js +31 -35
- package/ISA/ISA.Json/ConverterOptions.js +19 -1
- package/ISA/ISA.Json/Data.js +119 -137
- package/ISA/ISA.Json/Decode.js +51 -36
- package/ISA/ISA.Json/Factor.js +90 -90
- package/ISA/ISA.Json/GEncode.js +31 -6
- package/ISA/ISA.Json/Investigation.js +54 -79
- package/ISA/ISA.Json/Material.js +103 -104
- package/ISA/ISA.Json/Ontology.js +99 -92
- package/ISA/ISA.Json/Person.js +47 -65
- package/ISA/ISA.Json/Process.js +144 -130
- package/ISA/ISA.Json/Protocol.js +144 -105
- package/ISA/ISA.Json/Publication.js +34 -40
- package/ISA/ISA.Json/StringTable.js +44 -0
- package/ISA/ISA.Json/Study.js +70 -96
- package/ISA/ISA.Json/context/rocrate/isa_assay_context.js +34 -0
- package/ISA/ISA.Json/context/rocrate/isa_comment_context.js +23 -0
- package/ISA/ISA.Json/context/rocrate/isa_component_context.js +24 -0
- package/ISA/ISA.Json/context/rocrate/isa_data_context.js +25 -0
- package/ISA/ISA.Json/context/rocrate/isa_factor_context.js +25 -0
- package/ISA/ISA.Json/context/rocrate/isa_factor_value_context.js +25 -0
- package/ISA/ISA.Json/context/rocrate/isa_investigation_context.js +33 -0
- package/ISA/ISA.Json/context/rocrate/isa_material_attribute_context.js +23 -0
- package/ISA/ISA.Json/context/rocrate/isa_material_attribute_value_context.js +25 -0
- package/ISA/ISA.Json/context/rocrate/isa_material_context.js +26 -0
- package/ISA/ISA.Json/context/rocrate/isa_ontology_annotation_context.js +25 -0
- package/ISA/ISA.Json/context/rocrate/isa_ontology_source_reference_context.js +26 -0
- package/ISA/ISA.Json/context/rocrate/isa_organization_context.js +22 -0
- package/ISA/ISA.Json/context/rocrate/isa_person_context.js +31 -0
- package/ISA/ISA.Json/context/rocrate/isa_process_context.js +31 -0
- package/ISA/ISA.Json/context/rocrate/isa_process_parameter_value_context.js +25 -0
- package/ISA/ISA.Json/context/rocrate/isa_protocol_context.js +30 -0
- package/ISA/ISA.Json/context/rocrate/isa_protocol_parameter_context.js +23 -0
- package/ISA/ISA.Json/context/rocrate/isa_publication_context.js +27 -0
- package/ISA/ISA.Json/context/rocrate/isa_sample_context.js +26 -0
- package/ISA/ISA.Json/context/rocrate/isa_source_context.js +25 -0
- package/ISA/ISA.Json/context/rocrate/isa_study_context.js +42 -0
- package/ISA/ISA.Json/context/rocrate/rocrate_context.js +25 -0
- package/ISA/ISA.Spreadsheet/AnnotationTable/ArcTable.js +56 -43
- package/ISA/ISA.Spreadsheet/AnnotationTable/CompositeCell.js +3 -3
- package/ISA/ISA.Spreadsheet/AnnotationTable/CompositeColumn.js +11 -11
- package/ISA/ISA.Spreadsheet/AnnotationTable/CompositeHeader.js +5 -5
- package/ISA/ISA.Spreadsheet/ArcAssay.js +100 -88
- package/ISA/ISA.Spreadsheet/ArcInvestigation.js +12 -12
- package/ISA/ISA.Spreadsheet/ArcStudy.js +36 -24
- package/ISA/ISA.Spreadsheet/CollectionAux.js +8 -8
- package/ISA/ISA.Spreadsheet/Metadata/Assays.js +5 -5
- package/ISA/ISA.Spreadsheet/Metadata/Comment.js +31 -20
- package/ISA/ISA.Spreadsheet/Metadata/Contacts.js +5 -5
- package/ISA/ISA.Spreadsheet/Metadata/Conversions.js +5 -5
- package/ISA/ISA.Spreadsheet/Metadata/DesignDescriptors.js +1 -1
- package/ISA/ISA.Spreadsheet/Metadata/Factors.js +5 -5
- package/ISA/ISA.Spreadsheet/Metadata/OntologyAnnotation.js +5 -5
- package/ISA/ISA.Spreadsheet/Metadata/OntologySourceReference.js +5 -5
- package/ISA/ISA.Spreadsheet/Metadata/Protocols.js +5 -5
- package/ISA/ISA.Spreadsheet/Metadata/Publication.js +5 -5
- package/ISA/ISA.Spreadsheet/Metadata/SparseTable.js +28 -23
- package/ISA/ISA.Spreadsheet/Metadata/Study.js +8 -8
- package/README.md +20 -3
- package/SemVer.js +6 -6
- package/Templates/Template.Json.js +43 -36
- package/Templates/Template.Spreadsheet.js +12 -12
- package/Templates/Template.Web.js +4 -4
- package/Templates/Template.js +7 -7
- package/Templates/Templates.js +7 -7
- package/WebRequest/WebRequest.Node.js +15 -0
- package/WebRequest/WebRequest.js +10 -29
- package/fable_modules/Fable.Fetch.2.6.0/Fetch.fs.js +7 -7
- package/fable_modules/Fable.Promise.2.2.2/Promise.fs.js +3 -3
- package/fable_modules/Fable.SimpleHttp.3.5.0/Http.fs.js +8 -8
- package/fable_modules/Fable.SimpleHttp.3.5.0/Types.fs.js +2 -2
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Cells/FsCell.fs.js +14 -14
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Cells/FsCellsCollection.fs.js +6 -6
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/CellBuilder.fs.js +4 -4
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/ColumnBuilder.fs.js +3 -3
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/DSL.fs.js +2 -2
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/Expression.fs.js +1 -1
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/RowBuilder.fs.js +3 -3
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/SheetBuilder.fs.js +3 -3
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/TableBuilder.fs.js +3 -3
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/Transform.fs.js +6 -6
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/Types.fs.js +4 -4
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/WorkbookBuilder.fs.js +3 -3
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/FsAddress.fs +22 -8
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/FsAddress.fs.js +24 -14
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/FsColumn.fs.js +3 -3
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/FsRow.fs.js +3 -3
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/FsWorkbook.fs.js +6 -6
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/FsWorksheet.fs +12 -6
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/FsWorksheet.fs.js +21 -17
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Ranges/FsRange.fs.js +3 -3
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Ranges/FsRangeAddress.fs.js +4 -3
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Ranges/FsRangeBase.fs.js +3 -3
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Ranges/FsRangeColumn.fs.js +3 -3
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Ranges/FsRangeRow.fs.js +1 -1
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/SheetBuilder.fs.js +8 -8
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Tables/FsTable.fs.js +7 -7
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Tables/FsTableField.fs.js +4 -4
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Tables/FsTableRow.fs.js +1 -1
- package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/obj/Release/netstandard2.0/FsSpreadsheet.AssemblyInfo.fs +3 -3
- package/fable_modules/Thoth.Json.Core.0.2.1/Decode.fs +1390 -0
- package/fable_modules/Thoth.Json.Core.0.2.1/Decode.fs.js +1230 -0
- package/fable_modules/Thoth.Json.Core.0.2.1/Encode.fs +233 -0
- package/fable_modules/Thoth.Json.Core.0.2.1/Encode.fs.js +113 -0
- package/fable_modules/Thoth.Json.Core.0.2.1/Thoth.Json.Core.fableproj +28 -0
- package/fable_modules/Thoth.Json.Core.0.2.1/Types.fs +76 -0
- package/fable_modules/Thoth.Json.Core.0.2.1/Types.fs.js +33 -0
- package/fable_modules/Thoth.Json.Core.0.2.1/obj/Debug/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.fs +3 -0
- package/fable_modules/{Thoth.Json.10.1.0/obj/Release/netstandard2.0/Thoth.Json.AssemblyInfo.fs → Thoth.Json.Core.0.2.1/obj/Debug/netstandard2.0/Thoth.Json.Core.AssemblyInfo.fs} +8 -7
- package/fable_modules/Thoth.Json.JavaScript.0.1.0/Decode.fs +79 -0
- package/fable_modules/Thoth.Json.JavaScript.0.1.0/Decode.fs.js +85 -0
- package/fable_modules/Thoth.Json.JavaScript.0.1.0/Encode.fs +32 -0
- package/fable_modules/Thoth.Json.JavaScript.0.1.0/Encode.fs.js +45 -0
- package/fable_modules/Thoth.Json.JavaScript.0.1.0/Thoth.Json.JavaScript.fableproj +21 -0
- package/fable_modules/Thoth.Json.JavaScript.0.1.0/obj/Debug/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.fs +3 -0
- package/fable_modules/Thoth.Json.JavaScript.0.1.0/obj/Debug/netstandard2.0/Thoth.Json.JavaScript.AssemblyInfo.fs +18 -0
- package/fable_modules/Thoth.Json.JavaScript.0.1.0/obj/Release/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.fs +3 -0
- package/fable_modules/Thoth.Json.JavaScript.0.1.0/obj/Release/netstandard2.0/Thoth.Json.JavaScript.AssemblyInfo.fs +19 -0
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Array.d.ts +4 -1
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Array.js +124 -86
- package/fable_modules/fable-library-js.4.13.0/CHANGELOG.md +29 -0
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Choice.d.ts +0 -17
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Choice.js +0 -43
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Date.js +3 -2
- package/fable_modules/fable-library-js.4.13.0/FSharp.Core.CompilerServices.d.ts +12 -0
- package/fable_modules/fable-library-js.4.13.0/FSharp.Core.CompilerServices.js +27 -0
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/List.js +3 -3
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Map.js +3 -3
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/MutableMap.js +2 -1
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/MutableSet.js +2 -1
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Random.js +7 -7
- package/fable_modules/fable-library-js.4.13.0/Result.d.ts +37 -0
- package/fable_modules/fable-library-js.4.13.0/Result.js +165 -0
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Set.js +2 -2
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/String.d.ts +1 -0
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/String.js +8 -5
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/System.Collections.Generic.d.ts +15 -7
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/System.Collections.Generic.js +46 -36
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/System.Text.d.ts +9 -1
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/System.Text.js +60 -8
- package/fable_modules/fable-library-js.4.13.0/big.d.ts +338 -0
- package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/package.json +4 -3
- package/fable_modules/project_cracked.json +1 -1
- package/package.json +1 -1
- package/ISA/ISA.Json/Validation/Fable.js +0 -69
- package/ISA/ISA.Json/Validation/JsonSchemaValidation.js +0 -88
- package/ISA/ISA.Json/Validation/ValidationResult.js +0 -45
- package/fable_modules/Thoth.Json.10.1.0/Decode.fs +0 -1366
- package/fable_modules/Thoth.Json.10.1.0/Decode.fs.js +0 -1798
- package/fable_modules/Thoth.Json.10.1.0/Encode.fs +0 -621
- package/fable_modules/Thoth.Json.10.1.0/Encode.fs.js +0 -472
- package/fable_modules/Thoth.Json.10.1.0/Extra.fs +0 -31
- package/fable_modules/Thoth.Json.10.1.0/Extra.fs.js +0 -8
- package/fable_modules/Thoth.Json.10.1.0/Thoth.Json.fableproj +0 -30
- package/fable_modules/Thoth.Json.10.1.0/Types.fs +0 -59
- package/fable_modules/Thoth.Json.10.1.0/Types.fs.js +0 -98
- package/fable_modules/Thoth.Json.10.1.0/package.json +0 -5
- package/fable_modules/fable-library.4.5.0/CHANGELOG.md +0 -11
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Cells/FsCell.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Cells/FsCellsCollection.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/CellBuilder.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/ColumnBuilder.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/DSL.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/Expression.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/Operators.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/Operators.fs.js +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/RowBuilder.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/SheetBuilder.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/TableBuilder.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/Transform.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/Types.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/DSL/WorkbookBuilder.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/FsColumn.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/FsRow.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/FsSpreadsheet.fableproj +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/FsWorkbook.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Ranges/FsRange.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Ranges/FsRangeAddress.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Ranges/FsRangeBase.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Ranges/FsRangeColumn.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Ranges/FsRangeRow.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/SheetBuilder.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Tables/FsTable.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Tables/FsTableField.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/Tables/FsTableRow.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/obj/Debug/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/obj/Debug/netstandard2.0/FsSpreadsheet.AssemblyInfo.fs +0 -0
- /package/fable_modules/{FsSpreadsheet.5.1.2 → FsSpreadsheet.5.1.3}/obj/Release/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.fs +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Async.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Async.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/AsyncBuilder.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/AsyncBuilder.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/BigInt.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/BigInt.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/BitConverter.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/BitConverter.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Boolean.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Boolean.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Char.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Char.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Date.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/DateOffset.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/DateOffset.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/DateOnly.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/DateOnly.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Decimal.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Decimal.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Double.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Double.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Encoding.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Encoding.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Event.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Event.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/FSharp.Collections.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/FSharp.Collections.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/FSharp.Core.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/FSharp.Core.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Global.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Global.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Guid.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Guid.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Int32.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Int32.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/List.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Long.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Long.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/MailboxProcessor.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/MailboxProcessor.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Map.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/MapUtil.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/MapUtil.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/MutableMap.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/MutableSet.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Native.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Native.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Numeric.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Numeric.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Observable.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Observable.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Option.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Option.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/README.md +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Random.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Range.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Range.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Reflection.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Reflection.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/RegExp.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/RegExp.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Seq.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Seq.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Seq2.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Seq2.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Set.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/SystemException.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/SystemException.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/TimeOnly.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/TimeOnly.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/TimeSpan.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/TimeSpan.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Timer.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Timer.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Types.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Types.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Unicode.13.0.0.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Unicode.13.0.0.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Uri.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Uri.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Util.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/Util.js +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/lib/big.d.ts +0 -0
- /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.13.0}/lib/big.js +0 -0
package/ISA/ISA.Json/Protocol.js
CHANGED
|
@@ -1,19 +1,25 @@
|
|
|
1
|
-
import { value as
|
|
1
|
+
import { value as value_13 } from "../../fable_modules/fable-library-js.4.13.0/Option.js";
|
|
2
2
|
import { URIModule_toString } from "../ISA/JsonTypes/URI.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { empty, singleton, append, delay, toList } from "../../fable_modules/fable-library.4.
|
|
7
|
-
import { ConverterOptions__set_IncludeType_Z1FBCCD16, ConverterOptions__set_SetID_Z1FBCCD16, ConverterOptions_$ctor, ConverterOptions__get_IncludeType, ConverterOptions__get_SetID } from "./ConverterOptions.js";
|
|
8
|
-
import { tryInclude } from "./GEncode.js";
|
|
3
|
+
import { ofArray, choose } from "../../fable_modules/fable-library-js.4.13.0/List.js";
|
|
4
|
+
import { equals } from "../../fable_modules/fable-library-js.4.13.0/Util.js";
|
|
5
|
+
import { Json } from "../../fable_modules/Thoth.Json.Core.0.2.1/Types.fs.js";
|
|
6
|
+
import { empty, singleton, append, delay, toList } from "../../fable_modules/fable-library-js.4.13.0/Seq.js";
|
|
7
|
+
import { ConverterOptions__set_IncludeContext_Z1FBCCD16, ConverterOptions__set_IncludeType_Z1FBCCD16, ConverterOptions__set_SetID_Z1FBCCD16, ConverterOptions_$ctor, ConverterOptions__get_IncludeContext, ConverterOptions__get_IncludeType, ConverterOptions__get_SetID } from "./ConverterOptions.js";
|
|
8
|
+
import { tryIncludeList, tryInclude } from "./GEncode.js";
|
|
9
|
+
import { list as list_1 } from "../../fable_modules/Thoth.Json.Core.0.2.1/Encode.fs.js";
|
|
9
10
|
import { OntologyAnnotation_decoder, OntologyAnnotation_encoder } from "./Ontology.js";
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
11
|
+
import { context_jsonvalue } from "./context/rocrate/isa_protocol_parameter_context.js";
|
|
12
|
+
import { list as list_2, string, object } from "../../fable_modules/Thoth.Json.Core.0.2.1/Decode.fs.js";
|
|
13
|
+
import { uri } from "./Decode.js";
|
|
12
14
|
import { ProtocolParameter } from "../ISA/JsonTypes/ProtocolParameter.js";
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
+
import { fromString } from "../../fable_modules/Thoth.Json.JavaScript.0.1.0/Decode.fs.js";
|
|
16
|
+
import { replace, printf, toText } from "../../fable_modules/fable-library-js.4.13.0/String.js";
|
|
17
|
+
import { toString } from "../../fable_modules/Thoth.Json.JavaScript.0.1.0/Encode.fs.js";
|
|
18
|
+
import { context_jsonvalue as context_jsonvalue_1 } from "./context/rocrate/isa_component_context.js";
|
|
19
|
+
import { Result_Map } from "../../fable_modules/fable-library-js.4.13.0/Result.js";
|
|
15
20
|
import { Component, Component_decomposeName_Z721C83C5 } from "../ISA/JsonTypes/Component.js";
|
|
16
|
-
import { decoder as
|
|
21
|
+
import { decoder as decoder_1, encoder } from "./Comment.js";
|
|
22
|
+
import { context_jsonvalue as context_jsonvalue_2 } from "./context/rocrate/isa_protocol_context.js";
|
|
17
23
|
import { Protocol } from "../ISA/JsonTypes/Protocol.js";
|
|
18
24
|
|
|
19
25
|
export function ProtocolParameter_genID(pp) {
|
|
@@ -35,7 +41,7 @@ export function ProtocolParameter_genID(pp) {
|
|
|
35
41
|
}
|
|
36
42
|
switch (matchResult) {
|
|
37
43
|
case 0:
|
|
38
|
-
return "#Param_" +
|
|
44
|
+
return "#Param_" + value_13(n_1.ID);
|
|
39
45
|
default:
|
|
40
46
|
return "#EmptyProtocolParameter";
|
|
41
47
|
}
|
|
@@ -46,36 +52,32 @@ export function ProtocolParameter_genID(pp) {
|
|
|
46
52
|
}
|
|
47
53
|
|
|
48
54
|
export function ProtocolParameter_encoder(options, oa) {
|
|
49
|
-
return
|
|
55
|
+
return new Json(5, [choose((tupledArg) => {
|
|
50
56
|
const v = tupledArg[1];
|
|
51
|
-
if (equals(v,
|
|
57
|
+
if (equals(v, new Json(3, []))) {
|
|
52
58
|
return void 0;
|
|
53
59
|
}
|
|
54
60
|
else {
|
|
55
61
|
return [tupledArg[0], v];
|
|
56
62
|
}
|
|
57
|
-
}, toList(delay(() =>
|
|
58
|
-
let value, s;
|
|
59
|
-
return append(ConverterOptions__get_SetID(options) ? singleton(["@id", (value = ProtocolParameter_genID(oa), (typeof value === "string") ? ((s = value, s)) : nil)]) : singleton(tryInclude("@id", (value_2) => {
|
|
60
|
-
let s_1;
|
|
61
|
-
const value_3 = value_2;
|
|
62
|
-
return (typeof value_3 === "string") ? ((s_1 = value_3, s_1)) : nil;
|
|
63
|
-
}, oa["ID"])), delay(() => {
|
|
64
|
-
let value_5, s_2;
|
|
65
|
-
return append(ConverterOptions__get_IncludeType(options) ? singleton(["@type", (value_5 = "ProtocolParameter", (typeof value_5 === "string") ? ((s_2 = value_5, s_2)) : nil)]) : empty(), delay(() => singleton(tryInclude("parameterName", (oa_1) => OntologyAnnotation_encoder(options, oa_1), oa["ParameterName"]))));
|
|
66
|
-
}));
|
|
67
|
-
}))));
|
|
63
|
+
}, toList(delay(() => append(ConverterOptions__get_SetID(options) ? singleton(["@id", new Json(0, [ProtocolParameter_genID(oa)])]) : singleton(tryInclude("@id", (value_1) => (new Json(0, [value_1])), oa.ID)), delay(() => append(ConverterOptions__get_IncludeType(options) ? singleton(["@type", list_1(ofArray([new Json(0, ["ProtocolParameter"]), new Json(0, ["ArcProtocolParameter"])]))]) : empty(), delay(() => append(singleton(tryInclude("parameterName", (oa_1) => OntologyAnnotation_encoder(options, oa_1), oa.ParameterName)), delay(() => (ConverterOptions__get_IncludeContext(options) ? singleton(["@context", context_jsonvalue]) : empty()))))))))))]);
|
|
68
64
|
}
|
|
69
65
|
|
|
70
66
|
export function ProtocolParameter_decoder(options) {
|
|
71
|
-
return (
|
|
67
|
+
return object((get$) => {
|
|
72
68
|
let objectArg, arg_3, objectArg_1;
|
|
73
|
-
return new ProtocolParameter((objectArg = get$.Optional, objectArg.Field("@id", uri)), (arg_3 = OntologyAnnotation_decoder(options), (objectArg_1 = get$.Optional, objectArg_1.Field("parameterName",
|
|
74
|
-
}
|
|
69
|
+
return new ProtocolParameter((objectArg = get$.Optional, objectArg.Field("@id", uri)), (arg_3 = OntologyAnnotation_decoder(options), (objectArg_1 = get$.Optional, objectArg_1.Field("parameterName", arg_3))));
|
|
70
|
+
});
|
|
75
71
|
}
|
|
76
72
|
|
|
77
73
|
export function ProtocolParameter_fromJsonString(s) {
|
|
78
|
-
|
|
74
|
+
const matchValue = fromString(ProtocolParameter_decoder(ConverterOptions_$ctor()), s);
|
|
75
|
+
if (matchValue.tag === 1) {
|
|
76
|
+
throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
|
|
77
|
+
}
|
|
78
|
+
else {
|
|
79
|
+
return matchValue.fields[0];
|
|
80
|
+
}
|
|
79
81
|
}
|
|
80
82
|
|
|
81
83
|
export function ProtocolParameter_toString(p) {
|
|
@@ -85,11 +87,16 @@ export function ProtocolParameter_toString(p) {
|
|
|
85
87
|
/**
|
|
86
88
|
* exports in json-ld format
|
|
87
89
|
*/
|
|
88
|
-
export function
|
|
90
|
+
export function ProtocolParameter_toJsonldString(p) {
|
|
89
91
|
let returnVal;
|
|
90
92
|
return toString(2, ProtocolParameter_encoder((returnVal = ConverterOptions_$ctor(), ((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), returnVal)), p));
|
|
91
93
|
}
|
|
92
94
|
|
|
95
|
+
export function ProtocolParameter_toJsonldStringWithContext(a) {
|
|
96
|
+
let returnVal;
|
|
97
|
+
return toString(2, ProtocolParameter_encoder((returnVal = ConverterOptions_$ctor(), (((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), ConverterOptions__set_IncludeContext_Z1FBCCD16(returnVal, true)), returnVal)), a));
|
|
98
|
+
}
|
|
99
|
+
|
|
93
100
|
export function Component_genID(c) {
|
|
94
101
|
const matchValue = c.ComponentName;
|
|
95
102
|
if (matchValue == null) {
|
|
@@ -101,48 +108,47 @@ export function Component_genID(c) {
|
|
|
101
108
|
}
|
|
102
109
|
|
|
103
110
|
export function Component_encoder(options, oa) {
|
|
104
|
-
return
|
|
111
|
+
return new Json(5, [choose((tupledArg) => {
|
|
105
112
|
const v = tupledArg[1];
|
|
106
|
-
if (equals(v,
|
|
113
|
+
if (equals(v, new Json(3, []))) {
|
|
107
114
|
return void 0;
|
|
108
115
|
}
|
|
109
116
|
else {
|
|
110
117
|
return [tupledArg[0], v];
|
|
111
118
|
}
|
|
112
|
-
}, toList(delay(() =>
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
}
|
|
136
|
-
return new Component(c.ComponentName, patternInput[0], patternInput[1], c.ComponentType);
|
|
137
|
-
}, object_19((get$) => {
|
|
138
|
-
let objectArg, arg_3, objectArg_1;
|
|
139
|
-
return new Component((objectArg = get$.Optional, objectArg.Field("componentName", uri)), void 0, void 0, (arg_3 = OntologyAnnotation_decoder(options), (objectArg_1 = get$.Optional, objectArg_1.Field("componentType", uncurry2(arg_3)))));
|
|
140
|
-
}, s, json));
|
|
119
|
+
}, toList(delay(() => append(ConverterOptions__get_SetID(options) ? singleton(["@id", new Json(0, [Component_genID(oa)])]) : empty(), delay(() => append(ConverterOptions__get_IncludeType(options) ? singleton(["@type", list_1(ofArray([new Json(0, ["Component"]), new Json(0, ["ArcComponent"])]))]) : empty(), delay(() => append(singleton(tryInclude("componentName", (value_3) => (new Json(0, [value_3])), oa.ComponentName)), delay(() => append(singleton(tryInclude("componentType", (oa_1) => OntologyAnnotation_encoder(options, oa_1), oa.ComponentType)), delay(() => (ConverterOptions__get_IncludeContext(options) ? singleton(["@context", context_jsonvalue_1]) : empty()))))))))))))]);
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
export function Component_decoder(options) {
|
|
123
|
+
return {
|
|
124
|
+
Decode(s, json) {
|
|
125
|
+
return Result_Map((c) => {
|
|
126
|
+
let patternInput;
|
|
127
|
+
const matchValue = c.ComponentName;
|
|
128
|
+
if (matchValue == null) {
|
|
129
|
+
patternInput = [void 0, void 0];
|
|
130
|
+
}
|
|
131
|
+
else {
|
|
132
|
+
const tupledArg = Component_decomposeName_Z721C83C5(matchValue);
|
|
133
|
+
patternInput = [tupledArg[0], tupledArg[1]];
|
|
134
|
+
}
|
|
135
|
+
return new Component(c.ComponentName, patternInput[0], patternInput[1], c.ComponentType);
|
|
136
|
+
}, object((get$) => {
|
|
137
|
+
let objectArg, arg_3, objectArg_1;
|
|
138
|
+
return new Component((objectArg = get$.Optional, objectArg.Field("componentName", uri)), void 0, void 0, (arg_3 = OntologyAnnotation_decoder(options), (objectArg_1 = get$.Optional, objectArg_1.Field("componentType", arg_3))));
|
|
139
|
+
}).Decode(s, json));
|
|
140
|
+
},
|
|
141
|
+
};
|
|
141
142
|
}
|
|
142
143
|
|
|
143
144
|
export function Component_fromJsonString(s) {
|
|
144
|
-
|
|
145
|
-
|
|
145
|
+
const matchValue = fromString(Component_decoder(ConverterOptions_$ctor()), s);
|
|
146
|
+
if (matchValue.tag === 1) {
|
|
147
|
+
throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
|
|
148
|
+
}
|
|
149
|
+
else {
|
|
150
|
+
return matchValue.fields[0];
|
|
151
|
+
}
|
|
146
152
|
}
|
|
147
153
|
|
|
148
154
|
export function Component_toJsonString(p) {
|
|
@@ -152,19 +158,67 @@ export function Component_toJsonString(p) {
|
|
|
152
158
|
/**
|
|
153
159
|
* exports in json-ld format
|
|
154
160
|
*/
|
|
155
|
-
export function
|
|
161
|
+
export function Component_toJsonldString(p) {
|
|
156
162
|
let returnVal;
|
|
157
163
|
return toString(2, Component_encoder((returnVal = ConverterOptions_$ctor(), ((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), returnVal)), p));
|
|
158
164
|
}
|
|
159
165
|
|
|
160
|
-
export function
|
|
166
|
+
export function Component_toJsonldStringWithContext(a) {
|
|
167
|
+
let returnVal;
|
|
168
|
+
return toString(2, Component_encoder((returnVal = ConverterOptions_$ctor(), (((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), ConverterOptions__set_IncludeContext_Z1FBCCD16(returnVal, true)), returnVal)), a));
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
export function Protocol_genID(studyName, assayName, processName, p) {
|
|
161
172
|
const matchValue = p.ID;
|
|
162
173
|
if (matchValue == null) {
|
|
163
174
|
const matchValue_1 = p.Uri;
|
|
164
175
|
if (matchValue_1 == null) {
|
|
165
176
|
const matchValue_2 = p.Name;
|
|
166
177
|
if (matchValue_2 == null) {
|
|
167
|
-
|
|
178
|
+
let matchResult, an, pn, sn, pn_1, sn_1, pn_2;
|
|
179
|
+
if (studyName == null) {
|
|
180
|
+
if (assayName == null) {
|
|
181
|
+
if (processName != null) {
|
|
182
|
+
matchResult = 2;
|
|
183
|
+
pn_2 = processName;
|
|
184
|
+
}
|
|
185
|
+
else {
|
|
186
|
+
matchResult = 3;
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
else {
|
|
190
|
+
matchResult = 3;
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
else if (assayName == null) {
|
|
194
|
+
if (processName != null) {
|
|
195
|
+
matchResult = 1;
|
|
196
|
+
pn_1 = processName;
|
|
197
|
+
sn_1 = studyName;
|
|
198
|
+
}
|
|
199
|
+
else {
|
|
200
|
+
matchResult = 3;
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
else if (processName != null) {
|
|
204
|
+
matchResult = 0;
|
|
205
|
+
an = assayName;
|
|
206
|
+
pn = processName;
|
|
207
|
+
sn = studyName;
|
|
208
|
+
}
|
|
209
|
+
else {
|
|
210
|
+
matchResult = 3;
|
|
211
|
+
}
|
|
212
|
+
switch (matchResult) {
|
|
213
|
+
case 0:
|
|
214
|
+
return (((("#Protocol_" + replace(sn, " ", "_")) + "_") + replace(an, " ", "_")) + "_") + replace(pn, " ", "_");
|
|
215
|
+
case 1:
|
|
216
|
+
return (("#Protocol_" + replace(sn_1, " ", "_")) + "_") + replace(pn_1, " ", "_");
|
|
217
|
+
case 2:
|
|
218
|
+
return "#Protocol_" + replace(pn_2, " ", "_");
|
|
219
|
+
default:
|
|
220
|
+
return "#EmptyProtocol";
|
|
221
|
+
}
|
|
168
222
|
}
|
|
169
223
|
else {
|
|
170
224
|
return "#Protocol_" + replace(matchValue_2, " ", "_");
|
|
@@ -179,64 +233,49 @@ export function Protocol_genID(p) {
|
|
|
179
233
|
}
|
|
180
234
|
}
|
|
181
235
|
|
|
182
|
-
export function Protocol_encoder(options, oa) {
|
|
183
|
-
return
|
|
236
|
+
export function Protocol_encoder(options, studyName, assayName, processName, oa) {
|
|
237
|
+
return new Json(5, [choose((tupledArg) => {
|
|
184
238
|
const v = tupledArg[1];
|
|
185
|
-
if (equals(v,
|
|
239
|
+
if (equals(v, new Json(3, []))) {
|
|
186
240
|
return void 0;
|
|
187
241
|
}
|
|
188
242
|
else {
|
|
189
243
|
return [tupledArg[0], v];
|
|
190
244
|
}
|
|
191
|
-
}, toList(delay(() =>
|
|
192
|
-
let value, s;
|
|
193
|
-
return append(ConverterOptions__get_SetID(options) ? singleton(["@id", (value = Protocol_genID(oa), (typeof value === "string") ? ((s = value, s)) : nil)]) : singleton(tryInclude("@id", (value_2) => {
|
|
194
|
-
let s_1;
|
|
195
|
-
const value_3 = value_2;
|
|
196
|
-
return (typeof value_3 === "string") ? ((s_1 = value_3, s_1)) : nil;
|
|
197
|
-
}, oa["ID"])), delay(() => {
|
|
198
|
-
let value_5, s_2;
|
|
199
|
-
return append(ConverterOptions__get_IncludeType(options) ? singleton(["@type", (value_5 = "Protocol", (typeof value_5 === "string") ? ((s_2 = value_5, s_2)) : nil)]) : empty(), delay(() => append(singleton(tryInclude("name", (value_7) => {
|
|
200
|
-
let s_3;
|
|
201
|
-
const value_8 = value_7;
|
|
202
|
-
return (typeof value_8 === "string") ? ((s_3 = value_8, s_3)) : nil;
|
|
203
|
-
}, oa["Name"])), delay(() => append(singleton(tryInclude("protocolType", (oa_1) => OntologyAnnotation_encoder(options, oa_1), oa["ProtocolType"])), delay(() => append(singleton(tryInclude("description", (value_10) => {
|
|
204
|
-
let s_4;
|
|
205
|
-
const value_11 = value_10;
|
|
206
|
-
return (typeof value_11 === "string") ? ((s_4 = value_11, s_4)) : nil;
|
|
207
|
-
}, oa["Description"])), delay(() => append(singleton(tryInclude("uri", (value_13) => {
|
|
208
|
-
let s_5;
|
|
209
|
-
const value_14 = value_13;
|
|
210
|
-
return (typeof value_14 === "string") ? ((s_5 = value_14, s_5)) : nil;
|
|
211
|
-
}, oa["Uri"])), delay(() => append(singleton(tryInclude("version", (value_16) => {
|
|
212
|
-
let s_6;
|
|
213
|
-
const value_17 = value_16;
|
|
214
|
-
return (typeof value_17 === "string") ? ((s_6 = value_17, s_6)) : nil;
|
|
215
|
-
}, oa["Version"])), delay(() => append(singleton(tryInclude("parameters", (oa_2) => ProtocolParameter_encoder(options, oa_2), oa["Parameters"])), delay(() => append(singleton(tryInclude("components", (oa_3) => Component_encoder(options, oa_3), oa["Components"])), delay(() => singleton(tryInclude("comments", (comment) => encoder(options, comment), oa["Comments"]))))))))))))))))));
|
|
216
|
-
}));
|
|
217
|
-
}))));
|
|
245
|
+
}, toList(delay(() => append(ConverterOptions__get_SetID(options) ? singleton(["@id", new Json(0, [Protocol_genID(studyName, assayName, processName, oa)])]) : singleton(tryInclude("@id", (value_1) => (new Json(0, [value_1])), oa.ID)), delay(() => append(ConverterOptions__get_IncludeType(options) ? singleton(["@type", list_1(ofArray([new Json(0, ["Protocol"]), new Json(0, ["ArcProtocol"])]))]) : empty(), delay(() => append(singleton(tryInclude("name", (value_5) => (new Json(0, [value_5])), oa.Name)), delay(() => append(singleton(tryInclude("protocolType", (oa_1) => OntologyAnnotation_encoder(options, oa_1), oa.ProtocolType)), delay(() => append(singleton(tryInclude("description", (value_7) => (new Json(0, [value_7])), oa.Description)), delay(() => append(singleton(tryInclude("uri", (value_9) => (new Json(0, [value_9])), oa.Uri)), delay(() => append(singleton(tryInclude("version", (value_11) => (new Json(0, [value_11])), oa.Version)), delay(() => append(singleton(tryIncludeList("parameters", (oa_2) => ProtocolParameter_encoder(options, oa_2), oa.Parameters)), delay(() => append(singleton(tryIncludeList("components", (oa_3) => Component_encoder(options, oa_3), oa.Components)), delay(() => append(singleton(tryIncludeList("comments", (comment) => encoder(options, comment), oa.Comments)), delay(() => (ConverterOptions__get_IncludeContext(options) ? singleton(["@context", context_jsonvalue_2]) : empty()))))))))))))))))))))))))]);
|
|
218
246
|
}
|
|
219
247
|
|
|
220
248
|
export function Protocol_decoder(options) {
|
|
221
|
-
return (
|
|
222
|
-
let objectArg, objectArg_1, arg_5, objectArg_2, objectArg_3, objectArg_4, objectArg_5, arg_13,
|
|
223
|
-
return new Protocol((objectArg = get$.Optional, objectArg.Field("@id", uri)), (objectArg_1 = get$.Optional, objectArg_1.Field("name", string)), (arg_5 = OntologyAnnotation_decoder(options), (objectArg_2 = get$.Optional, objectArg_2.Field("protocolType",
|
|
224
|
-
}
|
|
249
|
+
return object((get$) => {
|
|
250
|
+
let objectArg, objectArg_1, arg_5, objectArg_2, objectArg_3, objectArg_4, objectArg_5, arg_13, objectArg_6, arg_15, objectArg_7, arg_17, objectArg_8;
|
|
251
|
+
return new Protocol((objectArg = get$.Optional, objectArg.Field("@id", uri)), (objectArg_1 = get$.Optional, objectArg_1.Field("name", string)), (arg_5 = OntologyAnnotation_decoder(options), (objectArg_2 = get$.Optional, objectArg_2.Field("protocolType", arg_5))), (objectArg_3 = get$.Optional, objectArg_3.Field("description", string)), (objectArg_4 = get$.Optional, objectArg_4.Field("uri", uri)), (objectArg_5 = get$.Optional, objectArg_5.Field("version", string)), (arg_13 = list_2(ProtocolParameter_decoder(options)), (objectArg_6 = get$.Optional, objectArg_6.Field("parameters", arg_13))), (arg_15 = list_2(Component_decoder(options)), (objectArg_7 = get$.Optional, objectArg_7.Field("components", arg_15))), (arg_17 = list_2(decoder_1(options)), (objectArg_8 = get$.Optional, objectArg_8.Field("comments", arg_17))));
|
|
252
|
+
});
|
|
225
253
|
}
|
|
226
254
|
|
|
227
255
|
export function Protocol_fromJsonString(s) {
|
|
228
|
-
|
|
256
|
+
const matchValue = fromString(Protocol_decoder(ConverterOptions_$ctor()), s);
|
|
257
|
+
if (matchValue.tag === 1) {
|
|
258
|
+
throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
|
|
259
|
+
}
|
|
260
|
+
else {
|
|
261
|
+
return matchValue.fields[0];
|
|
262
|
+
}
|
|
229
263
|
}
|
|
230
264
|
|
|
231
265
|
export function Protocol_toJsonString(p) {
|
|
232
|
-
return toString(2, Protocol_encoder(ConverterOptions_$ctor(), p));
|
|
266
|
+
return toString(2, Protocol_encoder(ConverterOptions_$ctor(), void 0, void 0, void 0, p));
|
|
233
267
|
}
|
|
234
268
|
|
|
235
269
|
/**
|
|
236
270
|
* exports in json-ld format
|
|
237
271
|
*/
|
|
238
|
-
export function
|
|
272
|
+
export function Protocol_toJsonldString(p) {
|
|
273
|
+
let returnVal;
|
|
274
|
+
return toString(2, Protocol_encoder((returnVal = ConverterOptions_$ctor(), ((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), returnVal)), void 0, void 0, void 0, p));
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
export function Protocol_toJsonldStringWithContext(a) {
|
|
239
278
|
let returnVal;
|
|
240
|
-
return toString(2, Protocol_encoder((returnVal = ConverterOptions_$ctor(), ((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), returnVal)),
|
|
279
|
+
return toString(2, Protocol_encoder((returnVal = ConverterOptions_$ctor(), (((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), ConverterOptions__set_IncludeContext_Z1FBCCD16(returnVal, true)), returnVal)), void 0, void 0, void 0, a));
|
|
241
280
|
}
|
|
242
281
|
|
|
@@ -1,15 +1,18 @@
|
|
|
1
|
-
import { replace } from "../../fable_modules/fable-library.4.
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { empty, singleton, append, delay, toList } from "../../fable_modules/fable-library.4.
|
|
6
|
-
import { ConverterOptions__set_IncludeType_Z1FBCCD16, ConverterOptions__set_SetID_Z1FBCCD16, ConverterOptions_$ctor, ConverterOptions__get_IncludeType, ConverterOptions__get_SetID } from "./ConverterOptions.js";
|
|
7
|
-
import { tryInclude } from "./GEncode.js";
|
|
1
|
+
import { printf, toText, replace } from "../../fable_modules/fable-library-js.4.13.0/String.js";
|
|
2
|
+
import { ofArray, choose } from "../../fable_modules/fable-library-js.4.13.0/List.js";
|
|
3
|
+
import { equals } from "../../fable_modules/fable-library-js.4.13.0/Util.js";
|
|
4
|
+
import { Json } from "../../fable_modules/Thoth.Json.Core.0.2.1/Types.fs.js";
|
|
5
|
+
import { empty, singleton, append, delay, toList } from "../../fable_modules/fable-library-js.4.13.0/Seq.js";
|
|
6
|
+
import { ConverterOptions__set_IncludeContext_Z1FBCCD16, ConverterOptions__set_IncludeType_Z1FBCCD16, ConverterOptions__set_SetID_Z1FBCCD16, ConverterOptions_$ctor, ConverterOptions__get_IncludeContext, ConverterOptions__get_IncludeType, ConverterOptions__get_SetID } from "./ConverterOptions.js";
|
|
7
|
+
import { tryIncludeArray, tryInclude } from "./GEncode.js";
|
|
8
8
|
import { OntologyAnnotation_decoder, OntologyAnnotation_encoder } from "./Ontology.js";
|
|
9
9
|
import { decoder as decoder_2, encoder as encoder_1 } from "./Comment.js";
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
10
|
+
import { context_jsonvalue } from "./context/rocrate/isa_publication_context.js";
|
|
11
|
+
import { uri, object } from "./Decode.js";
|
|
12
|
+
import { array, string } from "../../fable_modules/Thoth.Json.Core.0.2.1/Decode.fs.js";
|
|
12
13
|
import { Publication } from "../ISA/JsonTypes/Publication.js";
|
|
14
|
+
import { fromString } from "../../fable_modules/Thoth.Json.JavaScript.0.1.0/Decode.fs.js";
|
|
15
|
+
import { toString } from "../../fable_modules/Thoth.Json.JavaScript.0.1.0/Encode.fs.js";
|
|
13
16
|
|
|
14
17
|
export function genID(p) {
|
|
15
18
|
const matchValue = p.DOI;
|
|
@@ -34,48 +37,34 @@ export function genID(p) {
|
|
|
34
37
|
}
|
|
35
38
|
|
|
36
39
|
export function encoder(options, oa) {
|
|
37
|
-
return
|
|
40
|
+
return new Json(5, [choose((tupledArg) => {
|
|
38
41
|
const v = tupledArg[1];
|
|
39
|
-
if (equals(v,
|
|
42
|
+
if (equals(v, new Json(3, []))) {
|
|
40
43
|
return void 0;
|
|
41
44
|
}
|
|
42
45
|
else {
|
|
43
46
|
return [tupledArg[0], v];
|
|
44
47
|
}
|
|
45
|
-
}, toList(delay(() =>
|
|
46
|
-
let value, s;
|
|
47
|
-
return append(ConverterOptions__get_SetID(options) ? singleton(["@id", (value = genID(oa), (typeof value === "string") ? ((s = value, s)) : nil)]) : empty(), delay(() => {
|
|
48
|
-
let value_2, s_1;
|
|
49
|
-
return append(ConverterOptions__get_IncludeType(options) ? singleton(["@type", (value_2 = "Publication", (typeof value_2 === "string") ? ((s_1 = value_2, s_1)) : nil)]) : empty(), delay(() => append(singleton(tryInclude("pubMedID", (value_4) => {
|
|
50
|
-
let s_2;
|
|
51
|
-
const value_5 = value_4;
|
|
52
|
-
return (typeof value_5 === "string") ? ((s_2 = value_5, s_2)) : nil;
|
|
53
|
-
}, oa["PubMedID"])), delay(() => append(singleton(tryInclude("doi", (value_7) => {
|
|
54
|
-
let s_3;
|
|
55
|
-
const value_8 = value_7;
|
|
56
|
-
return (typeof value_8 === "string") ? ((s_3 = value_8, s_3)) : nil;
|
|
57
|
-
}, oa["DOI"])), delay(() => append(singleton(tryInclude("authorList", (value_10) => {
|
|
58
|
-
let s_4;
|
|
59
|
-
const value_11 = value_10;
|
|
60
|
-
return (typeof value_11 === "string") ? ((s_4 = value_11, s_4)) : nil;
|
|
61
|
-
}, oa["Authors"])), delay(() => append(singleton(tryInclude("title", (value_13) => {
|
|
62
|
-
let s_5;
|
|
63
|
-
const value_14 = value_13;
|
|
64
|
-
return (typeof value_14 === "string") ? ((s_5 = value_14, s_5)) : nil;
|
|
65
|
-
}, oa["Title"])), delay(() => append(singleton(tryInclude("status", (oa_1) => OntologyAnnotation_encoder(options, oa_1), oa["Status"])), delay(() => singleton(tryInclude("comments", (comment) => encoder_1(options, comment), oa["Comments"]))))))))))))));
|
|
66
|
-
}));
|
|
67
|
-
}))));
|
|
48
|
+
}, toList(delay(() => append(ConverterOptions__get_SetID(options) ? singleton(["@id", new Json(0, [genID(oa)])]) : empty(), delay(() => append(ConverterOptions__get_IncludeType(options) ? singleton(["@type", new Json(0, ["Publication"])]) : empty(), delay(() => append(singleton(tryInclude("pubMedID", (value_2) => (new Json(0, [value_2])), oa.PubMedID)), delay(() => append(singleton(tryInclude("doi", (value_4) => (new Json(0, [value_4])), oa.DOI)), delay(() => append(singleton(tryInclude("authorList", (value_6) => (new Json(0, [value_6])), oa.Authors)), delay(() => append(singleton(tryInclude("title", (value_8) => (new Json(0, [value_8])), oa.Title)), delay(() => append(singleton(tryInclude("status", (oa_1) => OntologyAnnotation_encoder(options, oa_1), oa.Status)), delay(() => append(singleton(tryIncludeArray("comments", (comment) => encoder_1(options, comment), oa.Comments)), delay(() => (ConverterOptions__get_IncludeContext(options) ? singleton(["@context", context_jsonvalue]) : empty()))))))))))))))))))))]);
|
|
68
49
|
}
|
|
69
50
|
|
|
51
|
+
export const allowedFields = ofArray(["@id", "pubMedID", "doi", "authorList", "title", "status", "comments", "@type", "@context"]);
|
|
52
|
+
|
|
70
53
|
export function decoder(options) {
|
|
71
|
-
return (
|
|
72
|
-
let objectArg, objectArg_1, objectArg_2, objectArg_3, arg_9, objectArg_4, arg_11,
|
|
73
|
-
return new Publication((objectArg = get$.Optional, objectArg.Field("pubMedID", uri)), (objectArg_1 = get$.Optional, objectArg_1.Field("doi", string)), (objectArg_2 = get$.Optional, objectArg_2.Field("authorList", string)), (objectArg_3 = get$.Optional, objectArg_3.Field("title", string)), (arg_9 = OntologyAnnotation_decoder(options), (objectArg_4 = get$.Optional, objectArg_4.Field("status",
|
|
74
|
-
}
|
|
54
|
+
return object(allowedFields, (get$) => {
|
|
55
|
+
let objectArg, objectArg_1, objectArg_2, objectArg_3, arg_9, objectArg_4, arg_11, objectArg_5;
|
|
56
|
+
return new Publication((objectArg = get$.Optional, objectArg.Field("pubMedID", uri)), (objectArg_1 = get$.Optional, objectArg_1.Field("doi", string)), (objectArg_2 = get$.Optional, objectArg_2.Field("authorList", string)), (objectArg_3 = get$.Optional, objectArg_3.Field("title", string)), (arg_9 = OntologyAnnotation_decoder(options), (objectArg_4 = get$.Optional, objectArg_4.Field("status", arg_9))), (arg_11 = array(decoder_2(options)), (objectArg_5 = get$.Optional, objectArg_5.Field("comments", arg_11))));
|
|
57
|
+
});
|
|
75
58
|
}
|
|
76
59
|
|
|
77
60
|
export function fromJsonString(s) {
|
|
78
|
-
|
|
61
|
+
const matchValue = fromString(decoder(ConverterOptions_$ctor()), s);
|
|
62
|
+
if (matchValue.tag === 1) {
|
|
63
|
+
throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
|
|
64
|
+
}
|
|
65
|
+
else {
|
|
66
|
+
return matchValue.fields[0];
|
|
67
|
+
}
|
|
79
68
|
}
|
|
80
69
|
|
|
81
70
|
export function toJsonString(p) {
|
|
@@ -85,8 +74,13 @@ export function toJsonString(p) {
|
|
|
85
74
|
/**
|
|
86
75
|
* exports in json-ld format
|
|
87
76
|
*/
|
|
88
|
-
export function
|
|
77
|
+
export function toJsonldString(p) {
|
|
89
78
|
let returnVal;
|
|
90
79
|
return toString(2, encoder((returnVal = ConverterOptions_$ctor(), ((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), returnVal)), p));
|
|
91
80
|
}
|
|
92
81
|
|
|
82
|
+
export function toJsonldStringWithContext(a) {
|
|
83
|
+
let returnVal;
|
|
84
|
+
return toString(2, encoder((returnVal = ConverterOptions_$ctor(), (((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), ConverterOptions__set_IncludeContext_Z1FBCCD16(returnVal, true)), returnVal)), a));
|
|
85
|
+
}
|
|
86
|
+
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { item, map, setItem, fill } from "../../fable_modules/fable-library-js.4.13.0/Array.js";
|
|
2
|
+
import { iterate } from "../../fable_modules/fable-library-js.4.13.0/Seq.js";
|
|
3
|
+
import { Json } from "../../fable_modules/Thoth.Json.Core.0.2.1/Types.fs.js";
|
|
4
|
+
import { int, string, array as array_1 } from "../../fable_modules/Thoth.Json.Core.0.2.1/Decode.fs.js";
|
|
5
|
+
import { Dict_tryFind } from "../ISA/Helper.js";
|
|
6
|
+
import { addToDict } from "../../fable_modules/fable-library-js.4.13.0/MapUtil.js";
|
|
7
|
+
import { FSharpResult$2 } from "../../fable_modules/fable-library-js.4.13.0/Result.js";
|
|
8
|
+
|
|
9
|
+
export function StringTable_arrayFromMap(otm) {
|
|
10
|
+
const a = fill(new Array(otm.size), 0, otm.size, "");
|
|
11
|
+
iterate((kv) => {
|
|
12
|
+
setItem(a, kv[1], kv[0]);
|
|
13
|
+
}, otm);
|
|
14
|
+
return a;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export function StringTable_encoder(ot) {
|
|
18
|
+
return new Json(6, [map((value) => (new Json(0, [value])), ot)]);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export const StringTable_decoder = array_1(string);
|
|
22
|
+
|
|
23
|
+
export function StringTable_encodeString(otm, s) {
|
|
24
|
+
const matchValue = Dict_tryFind(s, otm);
|
|
25
|
+
if (matchValue == null) {
|
|
26
|
+
const i_1 = otm.size | 0;
|
|
27
|
+
addToDict(otm, s, i_1);
|
|
28
|
+
return new Json(7, [i_1 >>> 0]);
|
|
29
|
+
}
|
|
30
|
+
else {
|
|
31
|
+
const i = matchValue | 0;
|
|
32
|
+
return new Json(7, [i >>> 0]);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export function StringTable_decodeString(ot) {
|
|
37
|
+
return {
|
|
38
|
+
Decode(s, json) {
|
|
39
|
+
const matchValue = int.Decode(s, json);
|
|
40
|
+
return (matchValue.tag === 1) ? (new FSharpResult$2(1, [matchValue.fields[0]])) : (new FSharpResult$2(0, [item(matchValue.fields[0], ot)]));
|
|
41
|
+
},
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
|