@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/Data.js
CHANGED
|
@@ -1,59 +1,62 @@
|
|
|
1
|
+
import { ErrorReason$1, Json } from "../../fable_modules/Thoth.Json.Core.0.2.1/Types.fs.js";
|
|
2
|
+
import { list as list_2, string } from "../../fable_modules/Thoth.Json.Core.0.2.1/Decode.fs.js";
|
|
3
|
+
import { FSharpResult$2 } from "../../fable_modules/fable-library-js.4.13.0/Result.js";
|
|
1
4
|
import { DataFile } from "../ISA/JsonTypes/DataFile.js";
|
|
2
|
-
import {
|
|
3
|
-
import { list as list_1, object as object_11, string } from "../../fable_modules/Thoth.Json.10.1.0/Decode.fs.js";
|
|
4
|
-
import { FSharpResult$2 } from "../../fable_modules/fable-library.4.5.0/Choice.js";
|
|
5
|
-
import { ErrorReason } from "../../fable_modules/Thoth.Json.10.1.0/Types.fs.js";
|
|
5
|
+
import { printf, toText, replace } from "../../fable_modules/fable-library-js.4.13.0/String.js";
|
|
6
6
|
import { URIModule_toString } from "../ISA/JsonTypes/URI.js";
|
|
7
|
-
import { ofArray, choose } from "../../fable_modules/fable-library.4.
|
|
8
|
-
import {
|
|
9
|
-
import { empty, singleton, append, delay, toList } from "../../fable_modules/fable-library.4.
|
|
10
|
-
import { ConverterOptions__set_IncludeType_Z1FBCCD16, ConverterOptions__set_SetID_Z1FBCCD16, ConverterOptions_$ctor, ConverterOptions__get_IncludeType, ConverterOptions__get_SetID } from "./ConverterOptions.js";
|
|
11
|
-
import { tryInclude } from "./GEncode.js";
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
7
|
+
import { ofArray, choose } from "../../fable_modules/fable-library-js.4.13.0/List.js";
|
|
8
|
+
import { equals } from "../../fable_modules/fable-library-js.4.13.0/Util.js";
|
|
9
|
+
import { empty, singleton, append, delay, toList } from "../../fable_modules/fable-library-js.4.13.0/Seq.js";
|
|
10
|
+
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";
|
|
11
|
+
import { tryIncludeList, tryInclude } from "./GEncode.js";
|
|
12
|
+
import { list as list_1 } from "../../fable_modules/Thoth.Json.Core.0.2.1/Encode.fs.js";
|
|
13
|
+
import { decoder as decoder_1, encoder } from "./Comment.js";
|
|
14
|
+
import { context_jsonvalue } from "./context/rocrate/isa_data_context.js";
|
|
15
|
+
import { uri, object } from "./Decode.js";
|
|
14
16
|
import { Data } from "../ISA/JsonTypes/Data.js";
|
|
15
|
-
import {
|
|
17
|
+
import { fromString } from "../../fable_modules/Thoth.Json.JavaScript.0.1.0/Decode.fs.js";
|
|
18
|
+
import { toString } from "../../fable_modules/Thoth.Json.JavaScript.0.1.0/Encode.fs.js";
|
|
16
19
|
import { MaterialAttributeValue_decoder, MaterialAttributeValue_encoder } from "./Material.js";
|
|
20
|
+
import { context_jsonvalue as context_jsonvalue_1 } from "./context/rocrate/isa_source_context.js";
|
|
17
21
|
import { Source } from "../ISA/JsonTypes/Source.js";
|
|
18
22
|
import { FactorValue_decoder, FactorValue_encoder } from "./Factor.js";
|
|
23
|
+
import { context_jsonvalue as context_jsonvalue_2 } from "./context/rocrate/isa_sample_context.js";
|
|
19
24
|
import { Sample } from "../ISA/JsonTypes/Sample.js";
|
|
20
25
|
|
|
21
26
|
export function DataFile_encoder(options, value) {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
return "Derived Data File";
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
export function DataFile_decoder(options, s, json) {
|
|
39
|
-
const matchValue = string(s, json);
|
|
40
|
-
if (matchValue.tag === 1) {
|
|
41
|
-
return new FSharpResult$2(1, [matchValue.fields[0]]);
|
|
42
|
-
}
|
|
43
|
-
else {
|
|
44
|
-
switch (matchValue.fields[0]) {
|
|
45
|
-
case "Raw Data File":
|
|
46
|
-
return new FSharpResult$2(0, [new DataFile(0, [])]);
|
|
47
|
-
case "Derived Data File":
|
|
48
|
-
return new FSharpResult$2(0, [new DataFile(1, [])]);
|
|
49
|
-
case "Image File":
|
|
50
|
-
return new FSharpResult$2(0, [new DataFile(2, [])]);
|
|
51
|
-
default: {
|
|
52
|
-
const s_1 = matchValue.fields[0];
|
|
53
|
-
return new FSharpResult$2(1, [[`Could not parse ${s_1}.`, new ErrorReason(0, [s_1, nil])]]);
|
|
27
|
+
switch (value.tag) {
|
|
28
|
+
case 1:
|
|
29
|
+
return new Json(0, ["Derived Data File"]);
|
|
30
|
+
case 2:
|
|
31
|
+
return new Json(0, ["Image File"]);
|
|
32
|
+
default:
|
|
33
|
+
return new Json(0, ["Raw Data File"]);
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export function DataFile_decoder(options) {
|
|
38
|
+
return {
|
|
39
|
+
Decode(s, json) {
|
|
40
|
+
const matchValue = string.Decode(s, json);
|
|
41
|
+
if (matchValue.tag === 1) {
|
|
42
|
+
return new FSharpResult$2(1, [matchValue.fields[0]]);
|
|
54
43
|
}
|
|
55
|
-
|
|
56
|
-
|
|
44
|
+
else {
|
|
45
|
+
switch (matchValue.fields[0]) {
|
|
46
|
+
case "Raw Data File":
|
|
47
|
+
return new FSharpResult$2(0, [new DataFile(0, [])]);
|
|
48
|
+
case "Derived Data File":
|
|
49
|
+
return new FSharpResult$2(0, [new DataFile(1, [])]);
|
|
50
|
+
case "Image File":
|
|
51
|
+
return new FSharpResult$2(0, [new DataFile(2, [])]);
|
|
52
|
+
default: {
|
|
53
|
+
const s_1 = matchValue.fields[0];
|
|
54
|
+
return new FSharpResult$2(1, [[`Could not parse ${s_1}.`, new ErrorReason$1(0, [s_1, json])]]);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
};
|
|
57
60
|
}
|
|
58
61
|
|
|
59
62
|
export function Data_genID(d) {
|
|
@@ -64,7 +67,7 @@ export function Data_genID(d) {
|
|
|
64
67
|
return "#EmptyData";
|
|
65
68
|
}
|
|
66
69
|
else {
|
|
67
|
-
return matchValue_1;
|
|
70
|
+
return replace(matchValue_1, " ", "_");
|
|
68
71
|
}
|
|
69
72
|
}
|
|
70
73
|
else {
|
|
@@ -73,46 +76,34 @@ export function Data_genID(d) {
|
|
|
73
76
|
}
|
|
74
77
|
|
|
75
78
|
export function Data_encoder(options, oa) {
|
|
76
|
-
return
|
|
79
|
+
return new Json(5, [choose((tupledArg) => {
|
|
77
80
|
const v = tupledArg[1];
|
|
78
|
-
if (equals(v,
|
|
81
|
+
if (equals(v, new Json(3, []))) {
|
|
79
82
|
return void 0;
|
|
80
83
|
}
|
|
81
84
|
else {
|
|
82
85
|
return [tupledArg[0], v];
|
|
83
86
|
}
|
|
84
|
-
}, toList(delay(() =>
|
|
85
|
-
let value, s;
|
|
86
|
-
return append(ConverterOptions__get_SetID(options) ? singleton(["@id", (value = Data_genID(oa), (typeof value === "string") ? ((s = value, s)) : nil)]) : singleton(tryInclude("@id", (value_2) => {
|
|
87
|
-
let s_1;
|
|
88
|
-
const value_3 = value_2;
|
|
89
|
-
return (typeof value_3 === "string") ? ((s_1 = value_3, s_1)) : nil;
|
|
90
|
-
}, oa["ID"])), delay(() => {
|
|
91
|
-
let value_5, s_2;
|
|
92
|
-
return append(ConverterOptions__get_IncludeType(options) ? singleton(["@type", (value_5 = "Data", (typeof value_5 === "string") ? ((s_2 = value_5, s_2)) : nil)]) : empty(), delay(() => append(singleton(tryInclude("name", (value_7) => {
|
|
93
|
-
let s_3;
|
|
94
|
-
const value_8 = value_7;
|
|
95
|
-
return (typeof value_8 === "string") ? ((s_3 = value_8, s_3)) : nil;
|
|
96
|
-
}, oa["Name"])), delay(() => append(singleton(tryInclude("type", (value_10) => DataFile_encoder(options, value_10), oa["DataType"])), delay(() => singleton(tryInclude("comments", (comment) => encoder(options, comment), oa["Comments"]))))))));
|
|
97
|
-
}));
|
|
98
|
-
}))));
|
|
87
|
+
}, toList(delay(() => append(ConverterOptions__get_SetID(options) ? singleton(["@id", new Json(0, [Data_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, ["Data"]), new Json(0, ["ArcData"])]))]) : empty(), delay(() => append(singleton(tryInclude("name", (value_5) => (new Json(0, [value_5])), oa.Name)), delay(() => append(singleton(tryInclude("type", (value_7) => DataFile_encoder(options, value_7), oa.DataType)), delay(() => append(singleton(tryIncludeList("comments", (comment) => encoder(options, comment), oa.Comments)), delay(() => (ConverterOptions__get_IncludeContext(options) ? singleton(["@context", context_jsonvalue]) : empty()))))))))))))))]);
|
|
99
88
|
}
|
|
100
89
|
|
|
101
|
-
export
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
return
|
|
107
|
-
|
|
108
|
-
return new Data((objectArg = get$.Optional, objectArg.Field("@id", uri)), (objectArg_1 = get$.Optional, objectArg_1.Field("name", string)), (objectArg_2 = get$.Optional, objectArg_2.Field("type", (s_2, json_2) => DataFile_decoder(options, s_2, json_2))), (arg_7 = ((decoder = decoder_3(options), (path_1) => ((value_1) => list_1(uncurry2(decoder), path_1, value_1)))), (objectArg_3 = get$.Optional, objectArg_3.Field("comments", uncurry2(arg_7)))));
|
|
109
|
-
}, s, json);
|
|
110
|
-
}
|
|
90
|
+
export const Data_allowedFields = ofArray(["@id", "name", "type", "comments", "@type", "@context"]);
|
|
91
|
+
|
|
92
|
+
export function Data_decoder(options) {
|
|
93
|
+
return object(Data_allowedFields, (get$) => {
|
|
94
|
+
let objectArg, objectArg_1, arg_5, objectArg_2, arg_7, objectArg_3;
|
|
95
|
+
return new Data((objectArg = get$.Optional, objectArg.Field("@id", uri)), (objectArg_1 = get$.Optional, objectArg_1.Field("name", string)), (arg_5 = DataFile_decoder(options), (objectArg_2 = get$.Optional, objectArg_2.Field("type", arg_5))), (arg_7 = list_2(decoder_1(options)), (objectArg_3 = get$.Optional, objectArg_3.Field("comments", arg_7))));
|
|
96
|
+
});
|
|
111
97
|
}
|
|
112
98
|
|
|
113
99
|
export function Data_fromJsonString(s) {
|
|
114
|
-
|
|
115
|
-
|
|
100
|
+
const matchValue = fromString(Data_decoder(ConverterOptions_$ctor()), s);
|
|
101
|
+
if (matchValue.tag === 1) {
|
|
102
|
+
throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
|
|
103
|
+
}
|
|
104
|
+
else {
|
|
105
|
+
return matchValue.fields[0];
|
|
106
|
+
}
|
|
116
107
|
}
|
|
117
108
|
|
|
118
109
|
export function Data_toJsonString(m) {
|
|
@@ -122,11 +113,16 @@ export function Data_toJsonString(m) {
|
|
|
122
113
|
/**
|
|
123
114
|
* exports in json-ld format
|
|
124
115
|
*/
|
|
125
|
-
export function
|
|
116
|
+
export function Data_toJsonldString(d) {
|
|
126
117
|
let returnVal;
|
|
127
118
|
return toString(2, Data_encoder((returnVal = ConverterOptions_$ctor(), ((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), returnVal)), d));
|
|
128
119
|
}
|
|
129
120
|
|
|
121
|
+
export function Data_toJsonldStringWithContext(a) {
|
|
122
|
+
let returnVal;
|
|
123
|
+
return toString(2, Data_encoder((returnVal = ConverterOptions_$ctor(), (((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), ConverterOptions__set_IncludeContext_Z1FBCCD16(returnVal, true)), returnVal)), a));
|
|
124
|
+
}
|
|
125
|
+
|
|
130
126
|
export function Source_genID(s) {
|
|
131
127
|
const matchValue = s.ID;
|
|
132
128
|
if (matchValue == null) {
|
|
@@ -144,46 +140,34 @@ export function Source_genID(s) {
|
|
|
144
140
|
}
|
|
145
141
|
|
|
146
142
|
export function Source_encoder(options, oa) {
|
|
147
|
-
return
|
|
143
|
+
return new Json(5, [choose((tupledArg) => {
|
|
148
144
|
const v = tupledArg[1];
|
|
149
|
-
if (equals(v,
|
|
145
|
+
if (equals(v, new Json(3, []))) {
|
|
150
146
|
return void 0;
|
|
151
147
|
}
|
|
152
148
|
else {
|
|
153
149
|
return [tupledArg[0], v];
|
|
154
150
|
}
|
|
155
|
-
}, toList(delay(() =>
|
|
156
|
-
let value, s_1;
|
|
157
|
-
return append(ConverterOptions__get_SetID(options) ? singleton(["@id", (value = Source_genID(oa), (typeof value === "string") ? ((s_1 = value, s_1)) : nil)]) : singleton(tryInclude("@id", (value_2) => {
|
|
158
|
-
let s_2;
|
|
159
|
-
const value_3 = value_2;
|
|
160
|
-
return (typeof value_3 === "string") ? ((s_2 = value_3, s_2)) : nil;
|
|
161
|
-
}, oa["ID"])), delay(() => {
|
|
162
|
-
let value_5, s_3;
|
|
163
|
-
return append(ConverterOptions__get_IncludeType(options) ? singleton(["@type", (value_5 = "Source", (typeof value_5 === "string") ? ((s_3 = value_5, s_3)) : nil)]) : empty(), delay(() => append(singleton(tryInclude("name", (value_7) => {
|
|
164
|
-
let s_4;
|
|
165
|
-
const value_8 = value_7;
|
|
166
|
-
return (typeof value_8 === "string") ? ((s_4 = value_8, s_4)) : nil;
|
|
167
|
-
}, oa["Name"])), delay(() => singleton(tryInclude("characteristics", (oa_1) => MaterialAttributeValue_encoder(options, oa_1), oa["Characteristics"]))))));
|
|
168
|
-
}));
|
|
169
|
-
}))));
|
|
151
|
+
}, toList(delay(() => append(ConverterOptions__get_SetID(options) ? singleton(["@id", new Json(0, [Source_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, ["Source"]), new Json(0, ["ArcSource"])]))]) : empty(), delay(() => append(singleton(tryInclude("name", (value_5) => (new Json(0, [value_5])), oa.Name)), delay(() => append(singleton(tryIncludeList("characteristics", (oa_1) => MaterialAttributeValue_encoder(options, oa_1), oa.Characteristics)), delay(() => (ConverterOptions__get_IncludeContext(options) ? singleton(["@context", context_jsonvalue_1]) : empty()))))))))))))]);
|
|
170
152
|
}
|
|
171
153
|
|
|
172
|
-
export
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
return
|
|
178
|
-
|
|
179
|
-
return new Source((objectArg = get$.Optional, objectArg.Field("@id", uri)), (objectArg_1 = get$.Optional, objectArg_1.Field("name", string)), (arg_5 = ((decoder = MaterialAttributeValue_decoder(options), (path_1) => ((value_1) => list_1(uncurry2(decoder), path_1, value_1)))), (objectArg_2 = get$.Optional, objectArg_2.Field("characteristics", uncurry2(arg_5)))));
|
|
180
|
-
}, s, json);
|
|
181
|
-
}
|
|
154
|
+
export const Source_allowedFields = ofArray(["@id", "name", "characteristics", "@type", "@context"]);
|
|
155
|
+
|
|
156
|
+
export function Source_decoder(options) {
|
|
157
|
+
return object(Source_allowedFields, (get$) => {
|
|
158
|
+
let objectArg, objectArg_1, arg_5, objectArg_2;
|
|
159
|
+
return new Source((objectArg = get$.Optional, objectArg.Field("@id", uri)), (objectArg_1 = get$.Optional, objectArg_1.Field("name", string)), (arg_5 = list_2(MaterialAttributeValue_decoder(options)), (objectArg_2 = get$.Optional, objectArg_2.Field("characteristics", arg_5))));
|
|
160
|
+
});
|
|
182
161
|
}
|
|
183
162
|
|
|
184
163
|
export function Source_fromJsonString(s) {
|
|
185
|
-
|
|
186
|
-
|
|
164
|
+
const matchValue = fromString(Source_decoder(ConverterOptions_$ctor()), s);
|
|
165
|
+
if (matchValue.tag === 1) {
|
|
166
|
+
throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
|
|
167
|
+
}
|
|
168
|
+
else {
|
|
169
|
+
return matchValue.fields[0];
|
|
170
|
+
}
|
|
187
171
|
}
|
|
188
172
|
|
|
189
173
|
export function Source_toJsonString(m) {
|
|
@@ -193,11 +177,16 @@ export function Source_toJsonString(m) {
|
|
|
193
177
|
/**
|
|
194
178
|
* exports in json-ld format
|
|
195
179
|
*/
|
|
196
|
-
export function
|
|
180
|
+
export function Source_toJsonldString(s) {
|
|
197
181
|
let returnVal;
|
|
198
182
|
return toString(2, Source_encoder((returnVal = ConverterOptions_$ctor(), ((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), returnVal)), s));
|
|
199
183
|
}
|
|
200
184
|
|
|
185
|
+
export function Source_toJsonldStringWithContext(a) {
|
|
186
|
+
let returnVal;
|
|
187
|
+
return toString(2, Source_encoder((returnVal = ConverterOptions_$ctor(), (((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), ConverterOptions__set_IncludeContext_Z1FBCCD16(returnVal, true)), returnVal)), a));
|
|
188
|
+
}
|
|
189
|
+
|
|
201
190
|
export function Sample_genID(s) {
|
|
202
191
|
const matchValue = s.ID;
|
|
203
192
|
if (matchValue == null) {
|
|
@@ -215,46 +204,34 @@ export function Sample_genID(s) {
|
|
|
215
204
|
}
|
|
216
205
|
|
|
217
206
|
export function Sample_encoder(options, oa) {
|
|
218
|
-
return
|
|
207
|
+
return new Json(5, [choose((tupledArg) => {
|
|
219
208
|
const v = tupledArg[1];
|
|
220
|
-
if (equals(v,
|
|
209
|
+
if (equals(v, new Json(3, []))) {
|
|
221
210
|
return void 0;
|
|
222
211
|
}
|
|
223
212
|
else {
|
|
224
213
|
return [tupledArg[0], v];
|
|
225
214
|
}
|
|
226
|
-
}, toList(delay(() =>
|
|
227
|
-
let value, s_1;
|
|
228
|
-
return append(ConverterOptions__get_SetID(options) ? singleton(["@id", (value = Sample_genID(oa), (typeof value === "string") ? ((s_1 = value, s_1)) : nil)]) : singleton(tryInclude("@id", (value_2) => {
|
|
229
|
-
let s_2;
|
|
230
|
-
const value_3 = value_2;
|
|
231
|
-
return (typeof value_3 === "string") ? ((s_2 = value_3, s_2)) : nil;
|
|
232
|
-
}, oa["ID"])), delay(() => {
|
|
233
|
-
let value_5, s_3;
|
|
234
|
-
return append(ConverterOptions__get_IncludeType(options) ? singleton(["@type", (value_5 = "Sample", (typeof value_5 === "string") ? ((s_3 = value_5, s_3)) : nil)]) : empty(), delay(() => append(singleton(tryInclude("name", (value_7) => {
|
|
235
|
-
let s_4;
|
|
236
|
-
const value_8 = value_7;
|
|
237
|
-
return (typeof value_8 === "string") ? ((s_4 = value_8, s_4)) : nil;
|
|
238
|
-
}, oa["Name"])), delay(() => append(singleton(tryInclude("characteristics", (oa_1) => MaterialAttributeValue_encoder(options, oa_1), oa["Characteristics"])), delay(() => append(singleton(tryInclude("factorValues", (oa_2) => FactorValue_encoder(options, oa_2), oa["FactorValues"])), delay(() => singleton(tryInclude("derivesFrom", (oa_3) => Source_encoder(options, oa_3), oa["DerivesFrom"]))))))))));
|
|
239
|
-
}));
|
|
240
|
-
}))));
|
|
215
|
+
}, toList(delay(() => append(ConverterOptions__get_SetID(options) ? singleton(["@id", new Json(0, [Sample_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, ["Sample"]), new Json(0, ["ArcSample"])]))]) : empty(), delay(() => append(singleton(tryInclude("name", (value_5) => (new Json(0, [value_5])), oa.Name)), delay(() => append(singleton(tryIncludeList("characteristics", (oa_1) => MaterialAttributeValue_encoder(options, oa_1), oa.Characteristics)), delay(() => append(singleton(tryIncludeList("factorValues", (oa_2) => FactorValue_encoder(options, oa_2), oa.FactorValues)), delay(() => append(singleton(tryIncludeList("derivesFrom", (oa_3) => Source_encoder(options, oa_3), oa.DerivesFrom)), delay(() => (ConverterOptions__get_IncludeContext(options) ? singleton(["@context", context_jsonvalue_2]) : empty()))))))))))))))))]);
|
|
241
216
|
}
|
|
242
217
|
|
|
243
|
-
export
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
return
|
|
249
|
-
|
|
250
|
-
return new Sample((objectArg = get$.Optional, objectArg.Field("@id", uri)), (objectArg_1 = get$.Optional, objectArg_1.Field("name", string)), (arg_5 = ((decoder = MaterialAttributeValue_decoder(options), (path_1) => ((value_1) => list_1(uncurry2(decoder), path_1, value_1)))), (objectArg_2 = get$.Optional, objectArg_2.Field("characteristics", uncurry2(arg_5)))), (arg_7 = ((decoder_1 = FactorValue_decoder(options), (path_2) => ((value_2) => list_1(uncurry2(decoder_1), path_2, value_2)))), (objectArg_3 = get$.Optional, objectArg_3.Field("factorValues", uncurry2(arg_7)))), (objectArg_4 = get$.Optional, objectArg_4.Field("derivesFrom", (path_3, value_3) => list_1((s_2, json_2) => Source_decoder(options, s_2, json_2), path_3, value_3))));
|
|
251
|
-
}, s, json);
|
|
252
|
-
}
|
|
218
|
+
export const Sample_allowedFields = ofArray(["@id", "name", "characteristics", "factorValues", "derivesFrom", "@type", "@context"]);
|
|
219
|
+
|
|
220
|
+
export function Sample_decoder(options) {
|
|
221
|
+
return object(Sample_allowedFields, (get$) => {
|
|
222
|
+
let objectArg, objectArg_1, arg_5, objectArg_2, arg_7, objectArg_3, arg_9, objectArg_4;
|
|
223
|
+
return new Sample((objectArg = get$.Optional, objectArg.Field("@id", uri)), (objectArg_1 = get$.Optional, objectArg_1.Field("name", string)), (arg_5 = list_2(MaterialAttributeValue_decoder(options)), (objectArg_2 = get$.Optional, objectArg_2.Field("characteristics", arg_5))), (arg_7 = list_2(FactorValue_decoder(options)), (objectArg_3 = get$.Optional, objectArg_3.Field("factorValues", arg_7))), (arg_9 = list_2(Source_decoder(options)), (objectArg_4 = get$.Optional, objectArg_4.Field("derivesFrom", arg_9))));
|
|
224
|
+
});
|
|
253
225
|
}
|
|
254
226
|
|
|
255
227
|
export function Sample_fromJsonString(s) {
|
|
256
|
-
|
|
257
|
-
|
|
228
|
+
const matchValue = fromString(Sample_decoder(ConverterOptions_$ctor()), s);
|
|
229
|
+
if (matchValue.tag === 1) {
|
|
230
|
+
throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
|
|
231
|
+
}
|
|
232
|
+
else {
|
|
233
|
+
return matchValue.fields[0];
|
|
234
|
+
}
|
|
258
235
|
}
|
|
259
236
|
|
|
260
237
|
export function Sample_toJsonString(m) {
|
|
@@ -264,8 +241,13 @@ export function Sample_toJsonString(m) {
|
|
|
264
241
|
/**
|
|
265
242
|
* exports in json-ld format
|
|
266
243
|
*/
|
|
267
|
-
export function
|
|
244
|
+
export function Sample_toJsonldString(s) {
|
|
268
245
|
let returnVal;
|
|
269
246
|
return toString(2, Sample_encoder((returnVal = ConverterOptions_$ctor(), ((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), returnVal)), s));
|
|
270
247
|
}
|
|
271
248
|
|
|
249
|
+
export function Sample_toJsonldStringWithContext(a) {
|
|
250
|
+
let returnVal;
|
|
251
|
+
return toString(2, Sample_encoder((returnVal = ConverterOptions_$ctor(), (((ConverterOptions__set_SetID_Z1FBCCD16(returnVal, true), ConverterOptions__set_IncludeType_Z1FBCCD16(returnVal, true)), ConverterOptions__set_IncludeContext_Z1FBCCD16(returnVal, true)), returnVal)), a));
|
|
252
|
+
}
|
|
253
|
+
|
package/ISA/ISA.Json/Decode.js
CHANGED
|
@@ -1,46 +1,61 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
1
|
+
import { helpers as helpers_2 } from "../../fable_modules/Thoth.Json.JavaScript.0.1.0/Decode.fs.js";
|
|
2
|
+
import { Getters$2__get_Errors, Getters$2_$ctor_Z4BE6C149, string } from "../../fable_modules/Thoth.Json.Core.0.2.1/Decode.fs.js";
|
|
3
|
+
import { FSharpResult$2 } from "../../fable_modules/fable-library-js.4.13.0/Result.js";
|
|
4
|
+
import { printf, toText } from "../../fable_modules/fable-library-js.4.13.0/String.js";
|
|
5
|
+
import { ErrorReason$1 } from "../../fable_modules/Thoth.Json.Core.0.2.1/Types.fs.js";
|
|
6
|
+
import { exists } from "../../fable_modules/fable-library-js.4.13.0/Seq.js";
|
|
7
|
+
import { ofSeq, contains } from "../../fable_modules/fable-library-js.4.13.0/Set.js";
|
|
8
|
+
import { comparePrimitives } from "../../fable_modules/fable-library-js.4.13.0/Util.js";
|
|
9
|
+
import { head, length, isEmpty } from "../../fable_modules/fable-library-js.4.13.0/List.js";
|
|
10
|
+
|
|
11
|
+
export const helpers = helpers_2;
|
|
7
12
|
|
|
8
13
|
export function isURI(s) {
|
|
9
14
|
return true;
|
|
10
15
|
}
|
|
11
16
|
|
|
12
|
-
export
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
const matchValue = fromString(decoder, s);
|
|
28
|
-
if (matchValue.tag === 1) {
|
|
29
|
-
throw new Error(toText(printf("Error decoding string: %s"))(matchValue.fields[0]));
|
|
30
|
-
}
|
|
31
|
-
else {
|
|
32
|
-
return matchValue.fields[0];
|
|
33
|
-
}
|
|
34
|
-
}
|
|
17
|
+
export const uri = {
|
|
18
|
+
Decode(s, json) {
|
|
19
|
+
const matchValue = string.Decode(s, json);
|
|
20
|
+
if (matchValue.tag === 1) {
|
|
21
|
+
return new FSharpResult$2(1, [matchValue.fields[0]]);
|
|
22
|
+
}
|
|
23
|
+
else if (isURI(matchValue.fields[0])) {
|
|
24
|
+
return new FSharpResult$2(0, [matchValue.fields[0]]);
|
|
25
|
+
}
|
|
26
|
+
else {
|
|
27
|
+
const s_3 = matchValue.fields[0];
|
|
28
|
+
return new FSharpResult$2(1, [[s_3, new ErrorReason$1(6, [toText(printf("Expected URI, got %s"))(s_3)])]]);
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
};
|
|
35
32
|
|
|
36
|
-
export function
|
|
37
|
-
return
|
|
33
|
+
export function hasUnknownFields(helpers_1, knownFields, json) {
|
|
34
|
+
return exists((x) => !contains(x, knownFields), helpers_1.getProperties(json));
|
|
38
35
|
}
|
|
39
36
|
|
|
40
|
-
export function
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
37
|
+
export function object(allowedFields, builder) {
|
|
38
|
+
const allowedFields_1 = ofSeq(allowedFields, {
|
|
39
|
+
Compare: comparePrimitives,
|
|
40
|
+
});
|
|
41
|
+
return {
|
|
42
|
+
Decode(helpers_1, value) {
|
|
43
|
+
const getters = Getters$2_$ctor_Z4BE6C149(helpers_1, value);
|
|
44
|
+
if (hasUnknownFields(helpers_1, allowedFields_1, value)) {
|
|
45
|
+
return new FSharpResult$2(1, [["Unknown fields in object", new ErrorReason$1(0, ["", value])]]);
|
|
46
|
+
}
|
|
47
|
+
else {
|
|
48
|
+
const result = builder(getters);
|
|
49
|
+
const matchValue = Getters$2__get_Errors(getters);
|
|
50
|
+
if (!isEmpty(matchValue)) {
|
|
51
|
+
const errors = matchValue;
|
|
52
|
+
return (length(errors) > 1) ? (new FSharpResult$2(1, [["", new ErrorReason$1(7, [errors])]])) : (new FSharpResult$2(1, [head(matchValue)]));
|
|
53
|
+
}
|
|
54
|
+
else {
|
|
55
|
+
return new FSharpResult$2(0, [result]);
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
};
|
|
45
60
|
}
|
|
46
61
|
|