@nfdi4plants/arctrl 1.1.0 → 2.0.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (377) hide show
  1. package/ARC.js +53 -35
  2. package/{Contracts/Contracts.ARCtrl.js → Contract/ARC.js} +4 -2
  3. package/Contract/ArcAssay.js +102 -0
  4. package/Contract/ArcInvestigation.js +78 -0
  5. package/Contract/ArcStudy.js +102 -0
  6. package/Contract/Contract.js +3 -3
  7. package/{Contracts/Contracts.Git.js → Contract/Git.js} +5 -5
  8. package/{ISA/ISA/ArcTypes → Core}/ArcTypes.js +307 -295
  9. package/Core/Comment.js +97 -0
  10. package/{ISA/ISA/JsonTypes → Core}/CommentList.js +12 -18
  11. package/Core/Conversion.js +1056 -0
  12. package/Core/Helper/Collections.js +318 -0
  13. package/Core/Helper/HashCodes.js +39 -0
  14. package/{ISA/ISA → Core/Helper}/Identifier.js +67 -2
  15. package/{ISA/ISA → Core/Helper}/Regex.js +3 -3
  16. package/{SemVer.js → Core/Helper/SemVer.js} +8 -8
  17. package/{ISA/ISA/ArcTypes → Core}/IdentifierSetters.js +1 -1
  18. package/Core/OntologyAnnotation.js +186 -0
  19. package/Core/OntologySourceReference.js +92 -0
  20. package/Core/Person.js +194 -0
  21. package/Core/Process/ColumnIndex.js +248 -0
  22. package/Core/Process/Component.js +188 -0
  23. package/{ISA/ISA/JsonTypes → Core/Process}/Data.js +8 -8
  24. package/{ISA/ISA/JsonTypes → Core/Process}/DataFile.js +3 -3
  25. package/Core/Process/Factor.js +109 -0
  26. package/{ISA/ISA/JsonTypes → Core/Process}/FactorValue.js +32 -13
  27. package/{ISA/ISA/JsonTypes → Core/Process}/Material.js +9 -9
  28. package/{ISA/ISA/JsonTypes → Core/Process}/MaterialAttribute.js +17 -17
  29. package/{ISA/ISA/JsonTypes → Core/Process}/MaterialAttributeValue.js +35 -16
  30. package/{ISA/ISA/JsonTypes → Core/Process}/MaterialType.js +3 -3
  31. package/{ISA/ISA/JsonTypes → Core/Process}/Process.js +46 -79
  32. package/{ISA/ISA/JsonTypes → Core/Process}/ProcessInput.js +42 -42
  33. package/{ISA/ISA/JsonTypes → Core/Process}/ProcessOutput.js +36 -36
  34. package/{ISA/ISA/JsonTypes → Core/Process}/ProcessParameterValue.js +26 -7
  35. package/{ISA/ISA/JsonTypes → Core/Process}/ProcessSequence.js +21 -25
  36. package/{ISA/ISA/JsonTypes → Core/Process}/Protocol.js +26 -57
  37. package/{ISA/ISA/JsonTypes → Core/Process}/ProtocolParameter.js +10 -10
  38. package/{ISA/ISA/JsonTypes → Core/Process}/Sample.js +12 -12
  39. package/{ISA/ISA/JsonTypes → Core/Process}/Source.js +9 -9
  40. package/{ISA/ISA/JsonTypes → Core/Process}/Value.js +24 -31
  41. package/Core/Publication.js +116 -0
  42. package/{ISA/ISA/ArcTypes → Core/Table}/ArcTable.js +49 -155
  43. package/Core/Table/ArcTableAux.js +532 -0
  44. package/{ISA/ISA/ArcTypes → Core/Table}/ArcTables.js +20 -32
  45. package/{ISA/ISA/ArcTypes → Core/Table}/CompositeCell.js +19 -76
  46. package/{ISA/ISA/ArcTypes → Core/Table}/CompositeColumn.js +9 -8
  47. package/{ISA/ISA/ArcTypes → Core/Table}/CompositeHeader.js +14 -34
  48. package/{Templates → Core}/Template.js +16 -17
  49. package/Core/Templates.js +84 -0
  50. package/FileSystem/Commit.js +2 -2
  51. package/FileSystem/FileSystem.js +4 -4
  52. package/FileSystem/FileSystemTree.js +46 -8
  53. package/FileSystem/Path.js +10 -2
  54. package/Json/ARC.js +25 -0
  55. package/Json/Assay.js +202 -0
  56. package/Json/Comment.js +130 -0
  57. package/Json/ConverterOptions.js +18 -0
  58. package/Json/Decode.js +128 -0
  59. package/Json/Encode.js +45 -0
  60. package/Json/Investigation.js +220 -0
  61. package/Json/OntologyAnnotation.js +169 -0
  62. package/Json/OntologySourceReference.js +122 -0
  63. package/Json/Person.js +250 -0
  64. package/Json/Process/AssayMaterials.js +22 -0
  65. package/Json/Process/Component.js +79 -0
  66. package/Json/Process/Data.js +102 -0
  67. package/Json/Process/DataFile.js +81 -0
  68. package/Json/Process/Factor.js +48 -0
  69. package/Json/Process/FactorValue.js +53 -0
  70. package/Json/Process/Material.js +107 -0
  71. package/Json/Process/MaterialAttribute.js +45 -0
  72. package/Json/Process/MaterialAttributeValue.js +70 -0
  73. package/Json/Process/MaterialType.js +60 -0
  74. package/Json/Process/Process.js +107 -0
  75. package/Json/Process/ProcessInput.js +59 -0
  76. package/Json/Process/ProcessOutput.js +71 -0
  77. package/Json/Process/ProcessParameterValue.js +69 -0
  78. package/Json/Process/ProcessSequence.js +53 -0
  79. package/Json/Process/PropertyValue.js +82 -0
  80. package/Json/Process/Protocol.js +147 -0
  81. package/Json/Process/ProtocolParameter.js +45 -0
  82. package/Json/Process/Sample.js +134 -0
  83. package/Json/Process/Source.js +101 -0
  84. package/Json/Process/StudyMaterials.js +24 -0
  85. package/Json/Process/Value.js +42 -0
  86. package/Json/Publication.js +142 -0
  87. package/Json/StringTable.js +44 -0
  88. package/Json/Study.js +306 -0
  89. package/Json/Table/ArcTable.js +223 -0
  90. package/Json/Table/CellTable.js +40 -0
  91. package/Json/Table/CompositeCell.js +65 -0
  92. package/Json/Table/CompositeHeader.js +57 -0
  93. package/Json/Table/Compression.js +38 -0
  94. package/Json/Table/IOType.js +37 -0
  95. package/Json/Table/OATable.js +40 -0
  96. package/Json/Table/Templates.js +107 -0
  97. package/Json/context/rocrate/isa_assay_context.js +32 -0
  98. package/Json/context/rocrate/isa_comment_context.js +23 -0
  99. package/Json/context/rocrate/isa_component_context.js +24 -0
  100. package/Json/context/rocrate/isa_data_context.js +25 -0
  101. package/Json/context/rocrate/isa_factor_context.js +25 -0
  102. package/Json/context/rocrate/isa_factor_value_context.js +23 -0
  103. package/Json/context/rocrate/isa_investigation_context.js +33 -0
  104. package/Json/context/rocrate/isa_material_attribute_context.js +23 -0
  105. package/Json/context/rocrate/isa_material_attribute_value_context.js +23 -0
  106. package/Json/context/rocrate/isa_material_context.js +26 -0
  107. package/Json/context/rocrate/isa_ontology_annotation_context.js +23 -0
  108. package/Json/context/rocrate/isa_ontology_source_reference_context.js +26 -0
  109. package/Json/context/rocrate/isa_organization_context.js +22 -0
  110. package/Json/context/rocrate/isa_person_context.js +33 -0
  111. package/Json/context/rocrate/isa_process_context.js +29 -0
  112. package/Json/context/rocrate/isa_process_parameter_value_context.js +23 -0
  113. package/Json/context/rocrate/isa_protocol_context.js +28 -0
  114. package/Json/context/rocrate/isa_protocol_parameter_context.js +23 -0
  115. package/Json/context/rocrate/isa_publication_context.js +25 -0
  116. package/Json/context/rocrate/isa_sample_context.js +24 -0
  117. package/Json/context/rocrate/isa_source_context.js +25 -0
  118. package/Json/context/rocrate/isa_study_context.js +40 -0
  119. package/Json/context/rocrate/property_value_context.js +4 -0
  120. package/Json/context/rocrate/rocrate_context.js +23 -0
  121. package/Json.js +193 -0
  122. package/README.md +50 -12
  123. package/{ISA/ISA.Spreadsheet → Spreadsheet}/AnnotationTable/ArcTable.js +12 -12
  124. package/{ISA/ISA.Spreadsheet → Spreadsheet}/AnnotationTable/CompositeCell.js +8 -7
  125. package/Spreadsheet/AnnotationTable/CompositeColumn.js +59 -0
  126. package/{ISA/ISA.Spreadsheet → Spreadsheet}/AnnotationTable/CompositeHeader.js +10 -10
  127. package/{ISA/ISA.Spreadsheet → Spreadsheet}/ArcAssay.js +11 -11
  128. package/{ISA/ISA.Spreadsheet → Spreadsheet}/ArcInvestigation.js +34 -37
  129. package/{ISA/ISA.Spreadsheet → Spreadsheet}/ArcStudy.js +12 -12
  130. package/{ISA/ISA.Spreadsheet → Spreadsheet}/CollectionAux.js +8 -8
  131. package/{ISA/ISA.Spreadsheet → Spreadsheet}/Metadata/Assays.js +32 -32
  132. package/Spreadsheet/Metadata/Comment.js +71 -0
  133. package/{ISA/ISA.Spreadsheet → Spreadsheet}/Metadata/Contacts.js +28 -30
  134. package/{ISA/ISA.Spreadsheet → Spreadsheet}/Metadata/Conversions.js +22 -16
  135. package/{ISA/ISA.Spreadsheet → Spreadsheet}/Metadata/DesignDescriptors.js +1 -1
  136. package/{ISA/ISA.Spreadsheet → Spreadsheet}/Metadata/Factors.js +23 -22
  137. package/Spreadsheet/Metadata/OntologyAnnotation.js +64 -0
  138. package/{ISA/ISA.Spreadsheet → Spreadsheet}/Metadata/OntologySourceReference.js +22 -24
  139. package/{ISA/ISA.Spreadsheet → Spreadsheet}/Metadata/Protocols.js +17 -17
  140. package/{ISA/ISA.Spreadsheet → Spreadsheet}/Metadata/Publication.js +29 -31
  141. package/{ISA/ISA.Spreadsheet → Spreadsheet}/Metadata/SparseTable.js +34 -28
  142. package/{ISA/ISA.Spreadsheet → Spreadsheet}/Metadata/Study.js +38 -40
  143. package/{Templates/Template.Spreadsheet.js → Spreadsheet/Template.js} +31 -31
  144. package/Template.Web.js +27 -0
  145. package/WebRequest/WebRequest.Node.js +15 -0
  146. package/WebRequest/WebRequest.js +10 -29
  147. package/Xlsx.js +85 -0
  148. package/fable_modules/Fable.Fetch.2.6.0/Fetch.fs.js +7 -7
  149. package/fable_modules/Fable.Promise.2.2.2/Promise.fs.js +3 -3
  150. package/fable_modules/Fable.SimpleHttp.3.5.0/Http.fs.js +8 -8
  151. package/fable_modules/Fable.SimpleHttp.3.5.0/Types.fs.js +2 -2
  152. package/fable_modules/FsSpreadsheet.5.1.3/Cells/FsCell.fs.js +14 -14
  153. package/fable_modules/FsSpreadsheet.5.1.3/Cells/FsCellsCollection.fs.js +6 -6
  154. package/fable_modules/FsSpreadsheet.5.1.3/DSL/CellBuilder.fs.js +4 -4
  155. package/fable_modules/FsSpreadsheet.5.1.3/DSL/ColumnBuilder.fs.js +3 -3
  156. package/fable_modules/FsSpreadsheet.5.1.3/DSL/DSL.fs.js +2 -2
  157. package/fable_modules/FsSpreadsheet.5.1.3/DSL/Expression.fs.js +1 -1
  158. package/fable_modules/FsSpreadsheet.5.1.3/DSL/RowBuilder.fs.js +3 -3
  159. package/fable_modules/FsSpreadsheet.5.1.3/DSL/SheetBuilder.fs.js +3 -3
  160. package/fable_modules/FsSpreadsheet.5.1.3/DSL/TableBuilder.fs.js +3 -3
  161. package/fable_modules/FsSpreadsheet.5.1.3/DSL/Transform.fs.js +6 -6
  162. package/fable_modules/FsSpreadsheet.5.1.3/DSL/Types.fs.js +4 -4
  163. package/fable_modules/FsSpreadsheet.5.1.3/DSL/WorkbookBuilder.fs.js +3 -3
  164. package/fable_modules/FsSpreadsheet.5.1.3/FsAddress.fs.js +8 -8
  165. package/fable_modules/FsSpreadsheet.5.1.3/FsColumn.fs.js +3 -3
  166. package/fable_modules/FsSpreadsheet.5.1.3/FsRow.fs.js +3 -3
  167. package/fable_modules/FsSpreadsheet.5.1.3/FsWorkbook.fs.js +6 -6
  168. package/fable_modules/FsSpreadsheet.5.1.3/FsWorksheet.fs.js +9 -9
  169. package/fable_modules/FsSpreadsheet.5.1.3/Ranges/FsRange.fs.js +3 -3
  170. package/fable_modules/FsSpreadsheet.5.1.3/Ranges/FsRangeAddress.fs.js +4 -3
  171. package/fable_modules/FsSpreadsheet.5.1.3/Ranges/FsRangeBase.fs.js +3 -3
  172. package/fable_modules/FsSpreadsheet.5.1.3/Ranges/FsRangeColumn.fs.js +3 -3
  173. package/fable_modules/FsSpreadsheet.5.1.3/Ranges/FsRangeRow.fs.js +1 -1
  174. package/fable_modules/FsSpreadsheet.5.1.3/SheetBuilder.fs.js +8 -8
  175. package/fable_modules/FsSpreadsheet.5.1.3/Tables/FsTable.fs.js +7 -7
  176. package/fable_modules/FsSpreadsheet.5.1.3/Tables/FsTableField.fs.js +4 -4
  177. package/fable_modules/FsSpreadsheet.5.1.3/Tables/FsTableRow.fs.js +1 -1
  178. package/fable_modules/Thoth.Json.Core.0.2.1/Decode.fs +1390 -0
  179. package/fable_modules/Thoth.Json.Core.0.2.1/Decode.fs.js +1230 -0
  180. package/fable_modules/Thoth.Json.Core.0.2.1/Encode.fs +233 -0
  181. package/fable_modules/Thoth.Json.Core.0.2.1/Encode.fs.js +113 -0
  182. package/fable_modules/Thoth.Json.Core.0.2.1/Thoth.Json.Core.fableproj +28 -0
  183. package/fable_modules/Thoth.Json.Core.0.2.1/Types.fs +76 -0
  184. package/fable_modules/Thoth.Json.Core.0.2.1/Types.fs.js +33 -0
  185. package/fable_modules/Thoth.Json.Core.0.2.1/obj/Debug/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.fs +3 -0
  186. 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
  187. package/fable_modules/Thoth.Json.JavaScript.0.1.0/Decode.fs +79 -0
  188. package/fable_modules/Thoth.Json.JavaScript.0.1.0/Decode.fs.js +85 -0
  189. package/fable_modules/Thoth.Json.JavaScript.0.1.0/Encode.fs +32 -0
  190. package/fable_modules/Thoth.Json.JavaScript.0.1.0/Encode.fs.js +45 -0
  191. package/fable_modules/Thoth.Json.JavaScript.0.1.0/Thoth.Json.JavaScript.fableproj +21 -0
  192. package/fable_modules/Thoth.Json.JavaScript.0.1.0/obj/Debug/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.fs +3 -0
  193. package/fable_modules/Thoth.Json.JavaScript.0.1.0/obj/Debug/netstandard2.0/Thoth.Json.JavaScript.AssemblyInfo.fs +18 -0
  194. package/fable_modules/Thoth.Json.JavaScript.0.1.0/obj/Release/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.fs +3 -0
  195. package/fable_modules/Thoth.Json.JavaScript.0.1.0/obj/Release/netstandard2.0/Thoth.Json.JavaScript.AssemblyInfo.fs +19 -0
  196. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Array.d.ts +4 -1
  197. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Array.js +124 -86
  198. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Boolean.js +2 -2
  199. package/fable_modules/fable-library-js.4.16.0/CHANGELOG.md +47 -0
  200. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Choice.d.ts +0 -17
  201. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Choice.js +0 -43
  202. package/fable_modules/fable-library-js.4.16.0/ConditionalWeakTable.d.ts +9 -0
  203. package/fable_modules/fable-library-js.4.16.0/ConditionalWeakTable.js +21 -0
  204. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Date.js +340 -42
  205. package/fable_modules/fable-library-js.4.16.0/FSharp.Core.CompilerServices.d.ts +12 -0
  206. package/fable_modules/fable-library-js.4.16.0/FSharp.Core.CompilerServices.js +27 -0
  207. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/List.js +3 -3
  208. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Map.js +3 -3
  209. package/fable_modules/fable-library-js.4.16.0/MapUtil.d.ts +12 -0
  210. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/MapUtil.js +15 -0
  211. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/MutableMap.js +2 -1
  212. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/MutableSet.js +2 -1
  213. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Random.js +7 -7
  214. package/fable_modules/fable-library-js.4.16.0/Result.d.ts +37 -0
  215. package/fable_modules/fable-library-js.4.16.0/Result.js +165 -0
  216. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Set.js +2 -2
  217. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/String.d.ts +1 -0
  218. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/String.js +8 -5
  219. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/System.Collections.Generic.d.ts +15 -7
  220. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/System.Collections.Generic.js +46 -36
  221. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/System.Text.d.ts +9 -1
  222. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/System.Text.js +60 -8
  223. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Util.d.ts +6 -3
  224. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Util.js +2 -13
  225. package/fable_modules/fable-library-js.4.16.0/big.d.ts +338 -0
  226. package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/package.json +4 -3
  227. package/fable_modules/project_cracked.json +1 -1
  228. package/index.js +14 -12
  229. package/package.json +1 -1
  230. package/Contracts/Contracts.ArcTypes.js +0 -268
  231. package/FileSystemTree.js +0 -51
  232. package/ISA/ISA/ArcTypes/ArcTableAux.js +0 -1155
  233. package/ISA/ISA/ArcTypes/CompositeRow.js +0 -111
  234. package/ISA/ISA/Builder/Types.js +0 -243
  235. package/ISA/ISA/Fable.js +0 -123
  236. package/ISA/ISA/Helper.js +0 -503
  237. package/ISA/ISA/JsonTypes/Assay.js +0 -620
  238. package/ISA/ISA/JsonTypes/AssayMaterials.js +0 -39
  239. package/ISA/ISA/JsonTypes/ColumnIndex.js +0 -246
  240. package/ISA/ISA/JsonTypes/Comment.js +0 -58
  241. package/ISA/ISA/JsonTypes/Component.js +0 -165
  242. package/ISA/ISA/JsonTypes/Factor.js +0 -128
  243. package/ISA/ISA/JsonTypes/Investigation.js +0 -204
  244. package/ISA/ISA/JsonTypes/OntologyAnnotation.js +0 -196
  245. package/ISA/ISA/JsonTypes/OntologySourceReference.js +0 -85
  246. package/ISA/ISA/JsonTypes/Person.js +0 -137
  247. package/ISA/ISA/JsonTypes/Publication.js +0 -105
  248. package/ISA/ISA/JsonTypes/Study.js +0 -942
  249. package/ISA/ISA/JsonTypes/StudyMaterials.js +0 -45
  250. package/ISA/ISA/UIHelper.js +0 -19
  251. package/ISA/ISA.Json/ArcTypes/ArcAssay.js +0 -282
  252. package/ISA/ISA.Json/ArcTypes/ArcInvestigation.js +0 -93
  253. package/ISA/ISA.Json/ArcTypes/ArcStudy.js +0 -170
  254. package/ISA/ISA.Json/ArcTypes/ArcTable.js +0 -178
  255. package/ISA/ISA.Json/ArcTypes/CellTable.js +0 -46
  256. package/ISA/ISA.Json/ArcTypes/CompositeCell.js +0 -77
  257. package/ISA/ISA.Json/ArcTypes/CompositeHeader.js +0 -82
  258. package/ISA/ISA.Json/ArcTypes/IOType.js +0 -35
  259. package/ISA/ISA.Json/ArcTypes/OATable.js +0 -48
  260. package/ISA/ISA.Json/Assay.js +0 -105
  261. package/ISA/ISA.Json/Comment.js +0 -84
  262. package/ISA/ISA.Json/ConverterOptions.js +0 -33
  263. package/ISA/ISA.Json/Data.js +0 -271
  264. package/ISA/ISA.Json/Decode.js +0 -46
  265. package/ISA/ISA.Json/Factor.js +0 -194
  266. package/ISA/ISA.Json/GEncode.js +0 -15
  267. package/ISA/ISA.Json/Investigation.js +0 -114
  268. package/ISA/ISA.Json/Material.js +0 -233
  269. package/ISA/ISA.Json/Ontology.js +0 -223
  270. package/ISA/ISA.Json/Person.js +0 -204
  271. package/ISA/ISA.Json/Process.js +0 -291
  272. package/ISA/ISA.Json/Protocol.js +0 -242
  273. package/ISA/ISA.Json/Publication.js +0 -92
  274. package/ISA/ISA.Json/StringTable.js +0 -43
  275. package/ISA/ISA.Json/Study.js +0 -212
  276. package/ISA/ISA.Json/Validation/Fable.js +0 -69
  277. package/ISA/ISA.Json/Validation/JsonSchemaValidation.js +0 -88
  278. package/ISA/ISA.Json/Validation/ValidationResult.js +0 -45
  279. package/ISA/ISA.Spreadsheet/AnnotationTable/CompositeColumn.js +0 -59
  280. package/ISA/ISA.Spreadsheet/Metadata/Comment.js +0 -60
  281. package/ISA/ISA.Spreadsheet/Metadata/OntologyAnnotation.js +0 -65
  282. package/Path.js +0 -10
  283. package/Templates/Template.Json.js +0 -83
  284. package/Templates/Template.Web.js +0 -27
  285. package/Templates/Templates.js +0 -82
  286. package/fable_modules/Thoth.Json.10.1.0/Decode.fs +0 -1366
  287. package/fable_modules/Thoth.Json.10.1.0/Decode.fs.js +0 -1798
  288. package/fable_modules/Thoth.Json.10.1.0/Encode.fs +0 -621
  289. package/fable_modules/Thoth.Json.10.1.0/Encode.fs.js +0 -472
  290. package/fable_modules/Thoth.Json.10.1.0/Extra.fs +0 -31
  291. package/fable_modules/Thoth.Json.10.1.0/Extra.fs.js +0 -8
  292. package/fable_modules/Thoth.Json.10.1.0/Thoth.Json.fableproj +0 -30
  293. package/fable_modules/Thoth.Json.10.1.0/Types.fs +0 -59
  294. package/fable_modules/Thoth.Json.10.1.0/Types.fs.js +0 -98
  295. package/fable_modules/Thoth.Json.10.1.0/package.json +0 -5
  296. package/fable_modules/fable-library.4.5.0/CHANGELOG.md +0 -11
  297. package/fable_modules/fable-library.4.5.0/MapUtil.d.ts +0 -10
  298. /package/{ISA/ISA/JsonTypes → Core}/URI.js +0 -0
  299. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Async.d.ts +0 -0
  300. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Async.js +0 -0
  301. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/AsyncBuilder.d.ts +0 -0
  302. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/AsyncBuilder.js +0 -0
  303. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/BigInt.d.ts +0 -0
  304. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/BigInt.js +0 -0
  305. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/BitConverter.d.ts +0 -0
  306. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/BitConverter.js +0 -0
  307. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Boolean.d.ts +0 -0
  308. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Char.d.ts +0 -0
  309. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Char.js +0 -0
  310. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Date.d.ts +0 -0
  311. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/DateOffset.d.ts +0 -0
  312. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/DateOffset.js +0 -0
  313. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/DateOnly.d.ts +0 -0
  314. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/DateOnly.js +0 -0
  315. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Decimal.d.ts +0 -0
  316. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Decimal.js +0 -0
  317. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Double.d.ts +0 -0
  318. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Double.js +0 -0
  319. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Encoding.d.ts +0 -0
  320. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Encoding.js +0 -0
  321. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Event.d.ts +0 -0
  322. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Event.js +0 -0
  323. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/FSharp.Collections.d.ts +0 -0
  324. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/FSharp.Collections.js +0 -0
  325. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/FSharp.Core.d.ts +0 -0
  326. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/FSharp.Core.js +0 -0
  327. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Global.d.ts +0 -0
  328. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Global.js +0 -0
  329. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Guid.d.ts +0 -0
  330. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Guid.js +0 -0
  331. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Int32.d.ts +0 -0
  332. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Int32.js +0 -0
  333. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/List.d.ts +0 -0
  334. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Long.d.ts +0 -0
  335. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Long.js +0 -0
  336. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/MailboxProcessor.d.ts +0 -0
  337. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/MailboxProcessor.js +0 -0
  338. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Map.d.ts +0 -0
  339. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/MutableMap.d.ts +0 -0
  340. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/MutableSet.d.ts +0 -0
  341. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Native.d.ts +0 -0
  342. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Native.js +0 -0
  343. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Numeric.d.ts +0 -0
  344. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Numeric.js +0 -0
  345. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Observable.d.ts +0 -0
  346. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Observable.js +0 -0
  347. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Option.d.ts +0 -0
  348. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Option.js +0 -0
  349. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/README.md +0 -0
  350. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Random.d.ts +0 -0
  351. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Range.d.ts +0 -0
  352. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Range.js +0 -0
  353. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Reflection.d.ts +0 -0
  354. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Reflection.js +0 -0
  355. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/RegExp.d.ts +0 -0
  356. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/RegExp.js +0 -0
  357. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Seq.d.ts +0 -0
  358. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Seq.js +0 -0
  359. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Seq2.d.ts +0 -0
  360. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Seq2.js +0 -0
  361. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Set.d.ts +0 -0
  362. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/SystemException.d.ts +0 -0
  363. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/SystemException.js +0 -0
  364. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/TimeOnly.d.ts +0 -0
  365. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/TimeOnly.js +0 -0
  366. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/TimeSpan.d.ts +0 -0
  367. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/TimeSpan.js +0 -0
  368. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Timer.d.ts +0 -0
  369. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Timer.js +0 -0
  370. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Types.d.ts +0 -0
  371. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Types.js +0 -0
  372. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Unicode.13.0.0.d.ts +0 -0
  373. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Unicode.13.0.0.js +0 -0
  374. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Uri.d.ts +0 -0
  375. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/Uri.js +0 -0
  376. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/lib/big.d.ts +0 -0
  377. /package/fable_modules/{fable-library.4.5.0 → fable-library-js.4.16.0}/lib/big.js +0 -0
package/Json/Assay.js ADDED
@@ -0,0 +1,202 @@
1
+ import { empty, singleton, ofArray, choose } from "../fable_modules/fable-library-js.4.16.0/List.js";
2
+ import { equals } from "../fable_modules/fable-library-js.4.16.0/Util.js";
3
+ import { Json } from "../fable_modules/Thoth.Json.Core.0.2.1/Types.fs.js";
4
+ import { defaultSpaces, tryIncludeList, tryIncludeSeq, tryInclude } from "./Encode.js";
5
+ import { OntologyAnnotation_ISAJson_decoder, OntologyAnnotation_ISAJson_encoder, OntologyAnnotation_ROCrate_decoderDefinedTerm, OntologyAnnotation_ROCrate_decoderPropertyValue, OntologyAnnotation_ROCrate_encoderDefinedTerm, OntologyAnnotation_ROCrate_encoderPropertyValue, OntologyAnnotation_decoder, OntologyAnnotation_encoder } from "./OntologyAnnotation.js";
6
+ import { ArcTable_decoderCompressed, ArcTable_encoderCompressed, ArcTable_decoder, ArcTable_encoder } from "./Table/ArcTable.js";
7
+ import { Person_ROCrate_decoder, Person_ROCrate_encoder, Person_decoder, Person_encoder } from "./Person.js";
8
+ import { Comment_ISAJson_decoder, Comment_ISAJson_encoder, Comment_ROCrate_decoder, Comment_ROCrate_encoder, Comment_decoder, Comment_encoder } from "./Comment.js";
9
+ import { map as map_1, list as list_2, string, object } from "../fable_modules/Thoth.Json.Core.0.2.1/Decode.fs.js";
10
+ import { ArcAssay } from "../Core/ArcTypes.js";
11
+ import { bind, map, defaultArg, unwrap } from "../fable_modules/fable-library-js.4.16.0/Option.js";
12
+ import { Decode_objectNoAdditionalProperties, Decode_resizeArray } from "./Decode.js";
13
+ import { toFail, printf, toText, replace } from "../fable_modules/fable-library-js.4.16.0/String.js";
14
+ import { Assay_tryIdentifierFromFileName, createMissingIdentifier, Assay_fileNameFromIdentifier } from "../Core/Helper/Identifier.js";
15
+ import { JsonTypes_decomposeTechnologyPlatform, JsonTypes_composeTechnologyPlatform, ARCtrl_ArcTables__ArcTables_fromProcesses_Static_62A3309D, ARCtrl_ArcTables__ArcTables_GetProcesses } from "../Core/Conversion.js";
16
+ import { getUnits, getCharacteristics, getData } from "../Core/Process/ProcessSequence.js";
17
+ import { list as list_1 } from "../fable_modules/Thoth.Json.Core.0.2.1/Encode.fs.js";
18
+ import { Data_ISAJson_encoder, Data_ROCrate_encoder } from "./Process/Data.js";
19
+ import { Process_ISAJson_decoder, Process_ISAJson_encoder, Process_ROCrate_decoder, Process_ROCrate_encoder } from "./Process/Process.js";
20
+ import { context_jsonvalue } from "./context/rocrate/isa_assay_context.js";
21
+ import { encoder } from "./Process/AssayMaterials.js";
22
+ import { Option_fromValueWithDefault } from "../Core/Helper/Collections.js";
23
+ import { MaterialAttribute_ISAJson_encoder } from "./Process/MaterialAttribute.js";
24
+ import { fromString } from "../fable_modules/Thoth.Json.JavaScript.0.1.0/Decode.fs.js";
25
+ import { toString } from "../fable_modules/Thoth.Json.JavaScript.0.1.0/Encode.fs.js";
26
+ import { encode, decode } from "./Table/Compression.js";
27
+
28
+ export function Assay_encoder(assay) {
29
+ return new Json(5, [choose((tupledArg) => {
30
+ const v = tupledArg[1];
31
+ if (equals(v, new Json(3, []))) {
32
+ return void 0;
33
+ }
34
+ else {
35
+ return [tupledArg[0], v];
36
+ }
37
+ }, ofArray([["Identifier", new Json(0, [assay.Identifier])], tryInclude("MeasurementType", OntologyAnnotation_encoder, assay.MeasurementType), tryInclude("TechnologyType", OntologyAnnotation_encoder, assay.TechnologyType), tryInclude("TechnologyPlatform", OntologyAnnotation_encoder, assay.TechnologyPlatform), tryIncludeSeq("Tables", ArcTable_encoder, assay.Tables), tryIncludeSeq("Performers", Person_encoder, assay.Performers), tryIncludeSeq("Comments", Comment_encoder, assay.Comments)]))]);
38
+ }
39
+
40
+ export const Assay_decoder = object((get$) => {
41
+ let objectArg, objectArg_1, objectArg_2, objectArg_3, arg_9, objectArg_4, arg_11, objectArg_5, arg_13, objectArg_6;
42
+ return ArcAssay.create((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("MeasurementType", OntologyAnnotation_decoder))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("TechnologyType", OntologyAnnotation_decoder))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("TechnologyPlatform", OntologyAnnotation_decoder))), unwrap((arg_9 = Decode_resizeArray(ArcTable_decoder), (objectArg_4 = get$.Optional, objectArg_4.Field("Tables", arg_9)))), unwrap((arg_11 = Decode_resizeArray(Person_decoder), (objectArg_5 = get$.Optional, objectArg_5.Field("Performers", arg_11)))), unwrap((arg_13 = Decode_resizeArray(Comment_decoder), (objectArg_6 = get$.Optional, objectArg_6.Field("Comments", arg_13)))));
43
+ });
44
+
45
+ export function Assay_encoderCompressed(stringTable, oaTable, cellTable, assay) {
46
+ return new Json(5, [choose((tupledArg) => {
47
+ const v = tupledArg[1];
48
+ if (equals(v, new Json(3, []))) {
49
+ return void 0;
50
+ }
51
+ else {
52
+ return [tupledArg[0], v];
53
+ }
54
+ }, ofArray([["Identifier", new Json(0, [assay.Identifier])], tryInclude("MeasurementType", OntologyAnnotation_encoder, assay.MeasurementType), tryInclude("TechnologyType", OntologyAnnotation_encoder, assay.TechnologyType), tryInclude("TechnologyPlatform", OntologyAnnotation_encoder, assay.TechnologyPlatform), tryIncludeSeq("Tables", (table) => ArcTable_encoderCompressed(stringTable, oaTable, cellTable, table), assay.Tables), tryIncludeSeq("Performers", Person_encoder, assay.Performers), tryIncludeSeq("Comments", Comment_encoder, assay.Comments)]))]);
55
+ }
56
+
57
+ export function Assay_decoderCompressed(stringTable, oaTable, cellTable) {
58
+ return object((get$) => {
59
+ let objectArg, objectArg_1, objectArg_2, objectArg_3, arg_9, objectArg_4, arg_11, objectArg_5, arg_13, objectArg_6;
60
+ return ArcAssay.create((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("MeasurementType", OntologyAnnotation_decoder))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("TechnologyType", OntologyAnnotation_decoder))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("TechnologyPlatform", OntologyAnnotation_decoder))), unwrap((arg_9 = Decode_resizeArray(ArcTable_decoderCompressed(stringTable, oaTable, cellTable)), (objectArg_4 = get$.Optional, objectArg_4.Field("Tables", arg_9)))), unwrap((arg_11 = Decode_resizeArray(Person_decoder), (objectArg_5 = get$.Optional, objectArg_5.Field("Performers", arg_11)))), unwrap((arg_13 = Decode_resizeArray(Comment_decoder), (objectArg_6 = get$.Optional, objectArg_6.Field("Comments", arg_13)))));
61
+ });
62
+ }
63
+
64
+ export function Assay_ROCrate_genID(a) {
65
+ const matchValue = a.Identifier;
66
+ if (matchValue === "") {
67
+ return "#EmptyAssay";
68
+ }
69
+ else {
70
+ return `#assay/${replace(matchValue, " ", "_")}`;
71
+ }
72
+ }
73
+
74
+ export function Assay_ROCrate_encoder(studyName, a) {
75
+ let assayName;
76
+ const fileName = Assay_fileNameFromIdentifier(a.Identifier);
77
+ const processes = ARCtrl_ArcTables__ArcTables_GetProcesses(a);
78
+ const dataFiles = getData(processes);
79
+ return new Json(5, [choose((tupledArg) => {
80
+ const v = tupledArg[1];
81
+ if (equals(v, new Json(3, []))) {
82
+ return void 0;
83
+ }
84
+ else {
85
+ return [tupledArg[0], v];
86
+ }
87
+ }, ofArray([["@id", new Json(0, [Assay_ROCrate_genID(a)])], ["@type", list_1(singleton(new Json(0, ["Assay"])))], ["additionalType", new Json(0, ["Assay"])], ["identifier", new Json(0, [a.Identifier])], ["filename", new Json(0, [fileName])], tryInclude("measurementType", OntologyAnnotation_ROCrate_encoderPropertyValue, a.MeasurementType), tryInclude("technologyType", OntologyAnnotation_ROCrate_encoderDefinedTerm, a.TechnologyType), tryInclude("technologyPlatform", OntologyAnnotation_ROCrate_encoderDefinedTerm, a.TechnologyPlatform), tryIncludeSeq("performers", Person_ROCrate_encoder, a.Performers), tryIncludeList("dataFiles", Data_ROCrate_encoder, dataFiles), tryIncludeList("processSequence", (assayName = a.Identifier, (oa_5) => Process_ROCrate_encoder(studyName, assayName, oa_5)), processes), tryIncludeSeq("comments", Comment_ROCrate_encoder, a.Comments), ["@context", context_jsonvalue]]))]);
88
+ }
89
+
90
+ export const Assay_ROCrate_decoder = object((get$) => {
91
+ let objectArg, arg_3, objectArg_1, objectArg_2, objectArg_3, objectArg_4, arg_12, objectArg_5, arg_14, objectArg_6;
92
+ const identifier = defaultArg((objectArg = get$.Optional, objectArg.Field("identifier", string)), createMissingIdentifier());
93
+ const tables = map((arg_4) => {
94
+ const a = ARCtrl_ArcTables__ArcTables_fromProcesses_Static_62A3309D(arg_4);
95
+ return a.Tables;
96
+ }, (arg_3 = list_2(Process_ROCrate_decoder), (objectArg_1 = get$.Optional, objectArg_1.Field("processSequence", arg_3))));
97
+ return new ArcAssay(identifier, unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("measurementType", OntologyAnnotation_ROCrate_decoderPropertyValue))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("technologyType", OntologyAnnotation_ROCrate_decoderDefinedTerm))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("technologyPlatform", OntologyAnnotation_ROCrate_decoderDefinedTerm))), unwrap(tables), unwrap((arg_12 = Decode_resizeArray(Person_ROCrate_decoder), (objectArg_5 = get$.Optional, objectArg_5.Field("performers", arg_12)))), unwrap((arg_14 = Decode_resizeArray(Comment_ROCrate_decoder), (objectArg_6 = get$.Optional, objectArg_6.Field("comments", arg_14)))));
98
+ });
99
+
100
+ export function Assay_ISAJson_encoder(a) {
101
+ const fileName = Assay_fileNameFromIdentifier(a.Identifier);
102
+ const processes = ARCtrl_ArcTables__ArcTables_GetProcesses(a);
103
+ const dataFiles = getData(processes);
104
+ const characteristics = getCharacteristics(processes);
105
+ const units = getUnits(processes);
106
+ return new Json(5, [choose((tupledArg) => {
107
+ const v = tupledArg[1];
108
+ if (equals(v, new Json(3, []))) {
109
+ return void 0;
110
+ }
111
+ else {
112
+ return [tupledArg[0], v];
113
+ }
114
+ }, ofArray([["filename", new Json(0, [fileName])], tryInclude("measurementType", OntologyAnnotation_ISAJson_encoder, a.MeasurementType), tryInclude("technologyType", OntologyAnnotation_ISAJson_encoder, a.TechnologyType), tryInclude("technologyPlatform", (value_1) => (new Json(0, [value_1])), map(JsonTypes_composeTechnologyPlatform, a.TechnologyPlatform)), tryIncludeList("dataFiles", Data_ISAJson_encoder, dataFiles), tryInclude("materials", encoder, Option_fromValueWithDefault(empty(), processes)), tryIncludeList("characteristicCategories", MaterialAttribute_ISAJson_encoder, characteristics), tryIncludeList("unitCategories", OntologyAnnotation_ISAJson_encoder, units), tryIncludeList("processSequence", Process_ISAJson_encoder, processes), tryIncludeSeq("comments", Comment_ISAJson_encoder, a.Comments)]))]);
115
+ }
116
+
117
+ export const Assay_ISAJson_allowedFields = ofArray(["@id", "filename", "measurementType", "technologyType", "technologyPlatform", "dataFiles", "materials", "characteristicCategories", "unitCategories", "processSequence", "comments", "@type", "@context"]);
118
+
119
+ export const Assay_ISAJson_decoder = Decode_objectNoAdditionalProperties(Assay_ISAJson_allowedFields, (get$) => {
120
+ let objectArg, arg_3, objectArg_1, objectArg_2, objectArg_3, arg_10, objectArg_4, arg_12, objectArg_5;
121
+ const identifier = defaultArg(bind(Assay_tryIdentifierFromFileName, (objectArg = get$.Optional, objectArg.Field("filename", string))), createMissingIdentifier());
122
+ const tables = map((arg_4) => {
123
+ const a = ARCtrl_ArcTables__ArcTables_fromProcesses_Static_62A3309D(arg_4);
124
+ return a.Tables;
125
+ }, (arg_3 = list_2(Process_ISAJson_decoder), (objectArg_1 = get$.Optional, objectArg_1.Field("processSequence", arg_3))));
126
+ return new ArcAssay(identifier, unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("measurementType", OntologyAnnotation_ISAJson_decoder))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("technologyType", OntologyAnnotation_ISAJson_decoder))), unwrap((arg_10 = map_1(JsonTypes_decomposeTechnologyPlatform, string), (objectArg_4 = get$.Optional, objectArg_4.Field("technologyPlatform", arg_10)))), unwrap(tables), void 0, unwrap((arg_12 = Decode_resizeArray(Comment_ISAJson_decoder), (objectArg_5 = get$.Optional, objectArg_5.Field("comments", arg_12)))));
127
+ });
128
+
129
+ export function ARCtrl_ArcAssay__ArcAssay_fromJsonString_Static_Z721C83C5(s) {
130
+ const matchValue = fromString(Assay_decoder, s);
131
+ if (matchValue.tag === 1) {
132
+ throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
133
+ }
134
+ else {
135
+ return matchValue.fields[0];
136
+ }
137
+ }
138
+
139
+ export function ARCtrl_ArcAssay__ArcAssay_toJsonString_Static_71136F3F(spaces) {
140
+ return (obj) => {
141
+ const value = Assay_encoder(obj);
142
+ return toString(defaultSpaces(spaces), value);
143
+ };
144
+ }
145
+
146
+ export function ARCtrl_ArcAssay__ArcAssay_fromCompressedJsonString_Static_Z721C83C5(s) {
147
+ try {
148
+ const matchValue = fromString(decode(Assay_decoderCompressed), s);
149
+ if (matchValue.tag === 1) {
150
+ throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
151
+ }
152
+ else {
153
+ return matchValue.fields[0];
154
+ }
155
+ }
156
+ catch (e_1) {
157
+ const arg_1 = e_1.message;
158
+ return toFail(printf("Error. Unable to parse json string to ArcStudy: %s"))(arg_1);
159
+ }
160
+ }
161
+
162
+ export function ARCtrl_ArcAssay__ArcAssay_toCompressedJsonString_Static_71136F3F(spaces) {
163
+ return (obj) => toString(defaultArg(spaces, 0), encode(Assay_encoderCompressed, obj));
164
+ }
165
+
166
+ export function ARCtrl_ArcAssay__ArcAssay_fromROCrateJsonString_Static_Z721C83C5(s) {
167
+ const matchValue = fromString(Assay_ROCrate_decoder, s);
168
+ if (matchValue.tag === 1) {
169
+ throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
170
+ }
171
+ else {
172
+ return matchValue.fields[0];
173
+ }
174
+ }
175
+
176
+ /**
177
+ * exports in json-ld format
178
+ */
179
+ export function ARCtrl_ArcAssay__ArcAssay_toROCrateJsonString_Static_5CABCA47(studyName, spaces) {
180
+ return (obj) => {
181
+ const value = Assay_ROCrate_encoder(studyName, obj);
182
+ return toString(defaultSpaces(spaces), value);
183
+ };
184
+ }
185
+
186
+ export function ARCtrl_ArcAssay__ArcAssay_toISAJsonString_Static_71136F3F(spaces) {
187
+ return (obj) => {
188
+ const value = Assay_ISAJson_encoder(obj);
189
+ return toString(defaultSpaces(spaces), value);
190
+ };
191
+ }
192
+
193
+ export function ARCtrl_ArcAssay__ArcAssay_fromISAJsonString_Static_Z721C83C5(s) {
194
+ const matchValue = fromString(Assay_ISAJson_decoder, s);
195
+ if (matchValue.tag === 1) {
196
+ throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
197
+ }
198
+ else {
199
+ return matchValue.fields[0];
200
+ }
201
+ }
202
+
@@ -0,0 +1,130 @@
1
+ import { ofArray, choose } from "../fable_modules/fable-library-js.4.16.0/List.js";
2
+ import { equals } from "../fable_modules/fable-library-js.4.16.0/Util.js";
3
+ import { Json } from "../fable_modules/Thoth.Json.Core.0.2.1/Types.fs.js";
4
+ import { defaultSpaces, tryInclude } from "./Encode.js";
5
+ import { map, string, object } from "../fable_modules/Thoth.Json.Core.0.2.1/Decode.fs.js";
6
+ import { Comment$ } from "../Core/Comment.js";
7
+ import { value as value_6, unwrap } from "../fable_modules/fable-library-js.4.16.0/Option.js";
8
+ import { printf, toText, replace } from "../fable_modules/fable-library-js.4.16.0/String.js";
9
+ import { context_jsonvalue } from "./context/rocrate/isa_comment_context.js";
10
+ import { toString } from "../fable_modules/Thoth.Json.JavaScript.0.1.0/Encode.fs.js";
11
+ import { fromString } from "../fable_modules/Thoth.Json.JavaScript.0.1.0/Decode.fs.js";
12
+
13
+ export function Comment_encoder(comment) {
14
+ return new Json(5, [choose((tupledArg) => {
15
+ const v = tupledArg[1];
16
+ if (equals(v, new Json(3, []))) {
17
+ return void 0;
18
+ }
19
+ else {
20
+ return [tupledArg[0], v];
21
+ }
22
+ }, ofArray([tryInclude("name", (value) => (new Json(0, [value])), comment.Name), tryInclude("value", (value_2) => (new Json(0, [value_2])), comment.Value)]))]);
23
+ }
24
+
25
+ export const Comment_decoder = object((get$) => {
26
+ let objectArg, objectArg_1;
27
+ return new Comment$(unwrap((objectArg = get$.Optional, objectArg.Field("name", string))), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("value", string))));
28
+ });
29
+
30
+ export function Comment_ROCrate_genID(c) {
31
+ const matchValue = c.Name;
32
+ if (matchValue == null) {
33
+ return "#EmptyComment";
34
+ }
35
+ else {
36
+ const n = matchValue;
37
+ const v = (c.Value != null) ? ("_" + replace(value_6(c.Value), " ", "_")) : "";
38
+ return ("#Comment_" + replace(n, " ", "_")) + v;
39
+ }
40
+ }
41
+
42
+ export function Comment_ROCrate_encoder(comment) {
43
+ return new Json(5, [choose((tupledArg) => {
44
+ const v = tupledArg[1];
45
+ if (equals(v, new Json(3, []))) {
46
+ return void 0;
47
+ }
48
+ else {
49
+ return [tupledArg[0], v];
50
+ }
51
+ }, ofArray([["@id", new Json(0, [Comment_ROCrate_genID(comment)])], ["@type", new Json(0, ["Comment"])], tryInclude("name", (value_2) => (new Json(0, [value_2])), comment.Name), tryInclude("value", (value_4) => (new Json(0, [value_4])), comment.Value), ["@context", context_jsonvalue]]))]);
52
+ }
53
+
54
+ export const Comment_ROCrate_decoder = object((get$) => {
55
+ let objectArg, objectArg_1;
56
+ return new Comment$(unwrap((objectArg = get$.Optional, objectArg.Field("name", string))), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("value", string))));
57
+ });
58
+
59
+ export function Comment_ROCrate_encoderDisambiguatingDescription(comment) {
60
+ return new Json(0, [toString(0, Comment_ROCrate_encoder(comment))]);
61
+ }
62
+
63
+ export const Comment_ROCrate_decoderDisambiguatingDescription = map((s) => {
64
+ const matchValue = fromString(Comment_ROCrate_decoder, s.trim());
65
+ if (matchValue.tag === 1) {
66
+ throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
67
+ }
68
+ else {
69
+ return matchValue.fields[0];
70
+ }
71
+ }, string);
72
+
73
+ export const Comment_ISAJson_encoder = Comment_encoder;
74
+
75
+ export const Comment_ISAJson_decoder = Comment_decoder;
76
+
77
+ export function ARCtrl_Comment__Comment_fromJsonString_Static_Z721C83C5(s) {
78
+ const matchValue = fromString(Comment_decoder, s);
79
+ if (matchValue.tag === 1) {
80
+ throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
81
+ }
82
+ else {
83
+ return matchValue.fields[0];
84
+ }
85
+ }
86
+
87
+ export function ARCtrl_Comment__Comment_toJsonString_Static_71136F3F(spaces) {
88
+ return (c) => {
89
+ const value = Comment_encoder(c);
90
+ return toString(defaultSpaces(spaces), value);
91
+ };
92
+ }
93
+
94
+ export function ARCtrl_Comment__Comment_fromROCrateJsonString_Static_Z721C83C5(s) {
95
+ const matchValue = fromString(Comment_ROCrate_decoder, s);
96
+ if (matchValue.tag === 1) {
97
+ throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
98
+ }
99
+ else {
100
+ return matchValue.fields[0];
101
+ }
102
+ }
103
+
104
+ /**
105
+ * exports in json-ld format
106
+ */
107
+ export function ARCtrl_Comment__Comment_toROCrateJsonString_Static_71136F3F(spaces) {
108
+ return (c) => {
109
+ const value = Comment_ROCrate_encoder(c);
110
+ return toString(defaultSpaces(spaces), value);
111
+ };
112
+ }
113
+
114
+ export function ARCtrl_Comment__Comment_toISAJsonString_Static_71136F3F(spaces) {
115
+ return (c) => {
116
+ const value = Comment_ISAJson_encoder(c);
117
+ return toString(defaultSpaces(spaces), value);
118
+ };
119
+ }
120
+
121
+ export function ARCtrl_Comment__Comment_fromISAJsonString_Static_Z721C83C5(s) {
122
+ const matchValue = fromString(Comment_ISAJson_decoder, s);
123
+ if (matchValue.tag === 1) {
124
+ throw new Error(toText(printf("Error decoding string: %O"))(matchValue.fields[0]));
125
+ }
126
+ else {
127
+ return matchValue.fields[0];
128
+ }
129
+ }
130
+
@@ -0,0 +1,18 @@
1
+ import { Union } from "../fable_modules/fable-library-js.4.16.0/Types.js";
2
+ import { union_type } from "../fable_modules/fable-library-js.4.16.0/Reflection.js";
3
+
4
+ export class ConverterOptions extends Union {
5
+ constructor(tag, fields) {
6
+ super();
7
+ this.tag = tag;
8
+ this.fields = fields;
9
+ }
10
+ cases() {
11
+ return ["ARCtrl", "ROCrate", "ISAJson"];
12
+ }
13
+ }
14
+
15
+ export function ConverterOptions_$reflection() {
16
+ return union_type("ARCtrl.Json.ConverterOptions", [], ConverterOptions, () => [[], [], []]);
17
+ }
18
+
package/Json/Decode.js ADDED
@@ -0,0 +1,128 @@
1
+ import { helpers as helpers_1 } 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.16.0/Result.js";
4
+ import { printf, toText } from "../fable_modules/fable-library-js.4.16.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.16.0/Seq.js";
7
+ import { ofSeq, contains } from "../fable_modules/fable-library-js.4.16.0/Set.js";
8
+ import { int32ToString, comparePrimitives } from "../fable_modules/fable-library-js.4.16.0/Util.js";
9
+ import { head, length, isEmpty } from "../fable_modules/fable-library-js.4.16.0/List.js";
10
+ import { fold } from "../fable_modules/fable-library-js.4.16.0/Array.js";
11
+ import { tryParse, minValue } from "../fable_modules/fable-library-js.4.16.0/Date.js";
12
+ import { FSharpRef } from "../fable_modules/fable-library-js.4.16.0/Types.js";
13
+
14
+ export function Helpers_prependPath(path, err_, err__1) {
15
+ const err = [err_, err__1];
16
+ return [path + err[0], err[1]];
17
+ }
18
+
19
+ export const Decode_helpers = helpers_1;
20
+
21
+ export function Decode_isURI(s) {
22
+ return true;
23
+ }
24
+
25
+ export const Decode_uri = {
26
+ Decode(s, json) {
27
+ const matchValue = string.Decode(s, json);
28
+ if (matchValue.tag === 1) {
29
+ return new FSharpResult$2(1, [matchValue.fields[0]]);
30
+ }
31
+ else if (Decode_isURI(matchValue.fields[0])) {
32
+ return new FSharpResult$2(0, [matchValue.fields[0]]);
33
+ }
34
+ else {
35
+ const s_3 = matchValue.fields[0];
36
+ return new FSharpResult$2(1, [[s_3, new ErrorReason$1(6, [toText(printf("Expected URI, got %s"))(s_3)])]]);
37
+ }
38
+ },
39
+ };
40
+
41
+ export function Decode_hasUnknownFields(helpers, knownFields, json) {
42
+ return exists((x) => !contains(x, knownFields), helpers.getProperties(json));
43
+ }
44
+
45
+ export function Decode_objectNoAdditionalProperties(allowedProperties, builder) {
46
+ const allowedProperties_1 = ofSeq(allowedProperties, {
47
+ Compare: comparePrimitives,
48
+ });
49
+ return {
50
+ Decode(helpers, value) {
51
+ const getters = Getters$2_$ctor_Z4BE6C149(helpers, value);
52
+ if (Decode_hasUnknownFields(helpers, allowedProperties_1, value)) {
53
+ return new FSharpResult$2(1, [["Unknown fields in object", new ErrorReason$1(0, ["", value])]]);
54
+ }
55
+ else {
56
+ const result = builder(getters);
57
+ const matchValue = Getters$2__get_Errors(getters);
58
+ if (!isEmpty(matchValue)) {
59
+ const errors = matchValue;
60
+ return (length(errors) > 1) ? (new FSharpResult$2(1, [["", new ErrorReason$1(7, [errors])]])) : (new FSharpResult$2(1, [head(matchValue)]));
61
+ }
62
+ else {
63
+ return new FSharpResult$2(0, [result]);
64
+ }
65
+ }
66
+ },
67
+ };
68
+ }
69
+
70
+ export function Decode_noAdditionalProperties(allowedProperties, decoder) {
71
+ const allowedProperties_1 = ofSeq(allowedProperties, {
72
+ Compare: comparePrimitives,
73
+ });
74
+ return {
75
+ Decode(helpers, value) {
76
+ const getters = Getters$2_$ctor_Z4BE6C149(helpers, value);
77
+ return Decode_hasUnknownFields(helpers, allowedProperties_1, value) ? (new FSharpResult$2(1, [["Unknown fields in object", new ErrorReason$1(0, ["", value])]])) : decoder.Decode(helpers, value);
78
+ },
79
+ };
80
+ }
81
+
82
+ export function Decode_resizeArray(decoder) {
83
+ return {
84
+ Decode(helpers, value) {
85
+ if (helpers.isArray(value)) {
86
+ let i = -1;
87
+ return fold((acc, value_1) => {
88
+ let tupledArg;
89
+ i = ((i + 1) | 0);
90
+ if (acc.tag === 0) {
91
+ const acc_1 = acc.fields[0];
92
+ const matchValue = decoder.Decode(helpers, value_1);
93
+ if (matchValue.tag === 0) {
94
+ void (acc_1.push(matchValue.fields[0]));
95
+ return new FSharpResult$2(0, [acc_1]);
96
+ }
97
+ else {
98
+ return new FSharpResult$2(1, [(tupledArg = matchValue.fields[0], Helpers_prependPath((".[" + int32ToString(i)) + "]", tupledArg[0], tupledArg[1]))]);
99
+ }
100
+ }
101
+ else {
102
+ return acc;
103
+ }
104
+ }, new FSharpResult$2(0, [[]]), helpers.asArray(value));
105
+ }
106
+ else {
107
+ return new FSharpResult$2(1, [["", new ErrorReason$1(0, ["an array", value])]]);
108
+ }
109
+ },
110
+ };
111
+ }
112
+
113
+ export const Decode_datetime = {
114
+ Decode(helpers, value) {
115
+ if (helpers.isString(value)) {
116
+ let matchValue;
117
+ let outArg = minValue();
118
+ matchValue = [tryParse(helpers.asString(value), new FSharpRef(() => outArg, (v) => {
119
+ outArg = v;
120
+ })), outArg];
121
+ return matchValue[0] ? (new FSharpResult$2(0, [matchValue[1]])) : (new FSharpResult$2(1, [["", new ErrorReason$1(0, ["a datetime", value])]]));
122
+ }
123
+ else {
124
+ return new FSharpResult$2(1, [["", new ErrorReason$1(0, ["a datetime", value])]]);
125
+ }
126
+ },
127
+ };
128
+
package/Json/Encode.js ADDED
@@ -0,0 +1,45 @@
1
+ import { defaultArg, value as value_2 } from "../fable_modules/fable-library-js.4.16.0/Option.js";
2
+ import { Json } from "../fable_modules/Thoth.Json.Core.0.2.1/Types.fs.js";
3
+ import { map, isEmpty } from "../fable_modules/fable-library-js.4.16.0/Seq.js";
4
+ import { list as list_1, seq } from "../fable_modules/Thoth.Json.Core.0.2.1/Encode.fs.js";
5
+ import { item, map as map_1 } from "../fable_modules/fable-library-js.4.16.0/Array.js";
6
+ import { map as map_2, isEmpty as isEmpty_1 } from "../fable_modules/fable-library-js.4.16.0/List.js";
7
+ import { toString } from "../fable_modules/fable-library-js.4.16.0/Date.js";
8
+
9
+ /**
10
+ * Try to encode the given object using the given encoder, or return Encode.nil if the object is null
11
+ */
12
+ export function tryInclude(name, encoder, value) {
13
+ return [name, (value != null) ? encoder(value_2(value)) : (new Json(3, []))];
14
+ }
15
+
16
+ /**
17
+ * Try to encode the given object using the given encoder, or return Encode.nil if the object is null
18
+ */
19
+ export function tryIncludeSeq(name, encoder, value) {
20
+ return [name, isEmpty(value) ? (new Json(3, [])) : seq(map(encoder, value))];
21
+ }
22
+
23
+ export function tryIncludeArray(name, encoder, value) {
24
+ return [name, (value.length === 0) ? (new Json(3, [])) : (new Json(6, [map_1(encoder, value)]))];
25
+ }
26
+
27
+ export function tryIncludeList(name, encoder, value) {
28
+ return [name, isEmpty_1(value) ? (new Json(3, [])) : list_1(map_2(encoder, value))];
29
+ }
30
+
31
+ export function tryIncludeListOpt(name, encoder, value) {
32
+ let o;
33
+ return [name, (value != null) ? ((o = value, isEmpty_1(o) ? (new Json(3, [])) : list_1(map_2(encoder, o)))) : (new Json(3, []))];
34
+ }
35
+
36
+ export const DefaultSpaces = 0;
37
+
38
+ export function defaultSpaces(spaces) {
39
+ return defaultArg(spaces, DefaultSpaces);
40
+ }
41
+
42
+ export function dateTime(d) {
43
+ return new Json(0, [item(0, toString(d, "O", {}).split("+"))]);
44
+ }
45
+