@nfdi4plants/arctrl 3.0.0-beta.13 → 3.0.0-beta.15
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/dist/ts/index.d.ts +2 -1
- package/dist/ts/index.d.ts.map +1 -1
- package/dist/ts/index.js +2 -1
- package/dist/ts/ts/ARC.d.ts +5 -5
- package/dist/ts/ts/ARC.js +52 -52
- package/dist/ts/ts/Contract/Datamap.d.ts +25 -25
- package/dist/ts/ts/Contract/Datamap.js +34 -34
- package/dist/ts/ts/Conversion/Assay.js +6 -6
- package/dist/ts/ts/Conversion/ColumnIndex.d.ts +1 -0
- package/dist/ts/ts/Conversion/ColumnIndex.d.ts.map +1 -1
- package/dist/ts/ts/Conversion/ColumnIndex.js +24 -5
- package/dist/ts/ts/Conversion/Datamap.d.ts +3 -3
- package/dist/ts/ts/Conversion/Datamap.js +4 -4
- package/dist/ts/ts/Conversion/Run.d.ts.map +1 -1
- package/dist/ts/ts/Conversion/Run.js +30 -9
- package/dist/ts/ts/Conversion/Study.js +6 -6
- package/dist/ts/ts/Conversion/Workflow.js +6 -6
- package/dist/ts/ts/Core/ArcTypes.d.ts +29 -29
- package/dist/ts/ts/Core/ArcTypes.d.ts.map +1 -1
- package/dist/ts/ts/Core/ArcTypes.js +46 -46
- package/dist/ts/ts/Core/{DataMap.d.ts → Datamap.d.ts} +24 -24
- package/dist/ts/ts/Core/{DataMap.d.ts.map → Datamap.d.ts.map} +1 -1
- package/dist/ts/ts/Core/{DataMap.js → Datamap.js} +36 -36
- package/dist/ts/ts/FileSystem/FileSystemTree.d.ts +4 -4
- package/dist/ts/ts/FileSystem/FileSystemTree.js +16 -16
- package/dist/ts/ts/Json/Assay.js +5 -5
- package/dist/ts/ts/Json/{DataMap → Datamap}/DataContext.d.ts.map +1 -1
- package/dist/ts/ts/Json/{DataMap/DataMap.d.ts → Datamap/Datamap.d.ts} +6 -6
- package/dist/ts/ts/Json/{DataMap/DataMap.d.ts.map → Datamap/Datamap.d.ts.map} +1 -1
- package/dist/ts/ts/Json/{DataMap/DataMap.js → Datamap/Datamap.js} +2 -2
- package/dist/ts/ts/Json/ROCrate/LDNode.d.ts +1 -0
- package/dist/ts/ts/Json/ROCrate/LDNode.d.ts.map +1 -1
- package/dist/ts/ts/Json/ROCrate/LDNode.js +18 -7
- package/dist/ts/ts/Json/Run.js +5 -5
- package/dist/ts/ts/Json/Study.js +5 -5
- package/dist/ts/ts/Json/Workflow.js +5 -5
- package/dist/ts/ts/Json.d.ts +3 -3
- package/dist/ts/ts/Json.js +3 -3
- package/dist/ts/ts/JsonIO/Datamap.d.ts +4 -4
- package/dist/ts/ts/JsonIO/Datamap.js +6 -6
- package/dist/ts/ts/ROCrate/ROCrateContext.js +1 -1
- package/dist/ts/ts/Spreadsheet/ArcAssay.js +3 -3
- package/dist/ts/ts/Spreadsheet/ArcRun.js +2 -2
- package/dist/ts/ts/Spreadsheet/ArcStudy.js +3 -3
- package/dist/ts/ts/Spreadsheet/ArcWorkflow.js +2 -2
- package/dist/ts/ts/Spreadsheet/Datamap.d.ts +8 -0
- package/dist/ts/ts/Spreadsheet/{DataMap.d.ts.map → Datamap.d.ts.map} +1 -1
- package/dist/ts/ts/Spreadsheet/{DataMap.js → Datamap.js} +9 -9
- package/dist/ts/ts/Spreadsheet/{DataMapTable/DataMapColumn.d.ts → DatamapTable/DatamapColumn.d.ts} +1 -1
- package/dist/ts/ts/Spreadsheet/{DataMapTable/DataMapColumn.d.ts.map → DatamapTable/DatamapColumn.d.ts.map} +1 -1
- package/dist/ts/ts/Spreadsheet/{DataMapTable/DataMapColumn.js → DatamapTable/DatamapColumn.js} +1 -1
- package/dist/ts/ts/Spreadsheet/{DataMapTable/DataMapHeader.d.ts → DatamapTable/DatamapHeader.d.ts} +1 -1
- package/dist/ts/ts/Spreadsheet/{DataMapTable/DataMapHeader.d.ts.map → DatamapTable/DatamapHeader.d.ts.map} +1 -1
- package/dist/ts/ts/Spreadsheet/{DataMapTable/DataMapTable.d.ts → DatamapTable/DatamapTable.d.ts} +5 -5
- package/dist/ts/ts/Spreadsheet/{DataMapTable/DataMapTable.d.ts.map → DatamapTable/DatamapTable.d.ts.map} +1 -1
- package/dist/ts/ts/Spreadsheet/{DataMapTable/DataMapTable.js → DatamapTable/DatamapTable.js} +6 -6
- package/dist/ts/ts/Xlsx.d.ts +5 -5
- package/dist/ts/ts/Xlsx.js +1 -1
- package/package.json +1 -1
- package/dist/ts/ts/Spreadsheet/DataMap.d.ts +0 -8
- /package/dist/ts/ts/Json/{DataMap → Datamap}/DataContext.d.ts +0 -0
- /package/dist/ts/ts/Json/{DataMap → Datamap}/DataContext.js +0 -0
- /package/dist/ts/ts/Spreadsheet/{DataMapTable/DataMapHeader.js → DatamapTable/DatamapHeader.js} +0 -0
|
@@ -8,18 +8,18 @@ import { DataContext__get_Explication, DataContext__set_Explication_279AAFF2, Da
|
|
|
8
8
|
import { hash, boxHashSeq } from './Helper/HashCodes.js';
|
|
9
9
|
import { class_type } from '../../node_modules/@fable-org/fable-library-js/Reflection.js';
|
|
10
10
|
|
|
11
|
-
const
|
|
12
|
-
const
|
|
13
|
-
const
|
|
14
|
-
const
|
|
15
|
-
const
|
|
16
|
-
const
|
|
17
|
-
const
|
|
18
|
-
const
|
|
19
|
-
const
|
|
20
|
-
const
|
|
21
|
-
const
|
|
22
|
-
function
|
|
11
|
+
const DatamapAux_dataHeader = CompositeHeader_Input(IOType_Data());
|
|
12
|
+
const DatamapAux_explication = new OntologyAnnotation("Clarification", "NCIT", "http://purl.obolibrary.org/obo/NCIT_C94778");
|
|
13
|
+
const DatamapAux_explicationHeader = CompositeHeader_Parameter(DatamapAux_explication);
|
|
14
|
+
const DatamapAux_unit = new OntologyAnnotation("Unit", "UO", "http://purl.obolibrary.org/obo/UO_0000000");
|
|
15
|
+
const DatamapAux_unitHeader = CompositeHeader_Parameter(DatamapAux_unit);
|
|
16
|
+
const DatamapAux_objectType = new OntologyAnnotation("Data Type", "NCIT", "http://purl.obolibrary.org/obo/NCIT_C42645");
|
|
17
|
+
const DatamapAux_objectTypeHeader = CompositeHeader_Parameter(DatamapAux_objectType);
|
|
18
|
+
const DatamapAux_labelHeader = CompositeHeader_FreeText("Label");
|
|
19
|
+
const DatamapAux_descriptionHeader = CompositeHeader_FreeText("Description");
|
|
20
|
+
const DatamapAux_generatedByHeader = CompositeHeader_FreeText("Generated By");
|
|
21
|
+
const DatamapAux_allowedHeaders = ofArray([DatamapAux_dataHeader, DatamapAux_explicationHeader, DatamapAux_unitHeader, DatamapAux_objectTypeHeader, DatamapAux_descriptionHeader, DatamapAux_generatedByHeader]);
|
|
22
|
+
function DatamapAux_getOntologyColumn(f, dataContexts) {
|
|
23
23
|
const collection = map((dc) => {
|
|
24
24
|
const matchValue = f(dc);
|
|
25
25
|
if (matchValue == null) {
|
|
@@ -30,7 +30,7 @@ function DataMapAux_getOntologyColumn(f, dataContexts) {
|
|
|
30
30
|
}, dataContexts);
|
|
31
31
|
return Array.from(collection);
|
|
32
32
|
}
|
|
33
|
-
function
|
|
33
|
+
function DatamapAux_getStringColumn(f, dataContexts) {
|
|
34
34
|
const collection = map((dc) => {
|
|
35
35
|
const matchValue = f(dc);
|
|
36
36
|
if (matchValue == null) {
|
|
@@ -41,7 +41,7 @@ function DataMapAux_getStringColumn(f, dataContexts) {
|
|
|
41
41
|
}, dataContexts);
|
|
42
42
|
return Array.from(collection);
|
|
43
43
|
}
|
|
44
|
-
function
|
|
44
|
+
function DatamapAux_setOntologyColumn(f, column, dataContexts) {
|
|
45
45
|
iterateIndexed((i, cell) => {
|
|
46
46
|
if (cell.tag === /* Term */
|
|
47
47
|
0) {
|
|
@@ -50,7 +50,7 @@ function DataMapAux_setOntologyColumn(f, column, dataContexts) {
|
|
|
50
50
|
}
|
|
51
51
|
}, column);
|
|
52
52
|
}
|
|
53
|
-
function
|
|
53
|
+
function DatamapAux_setStringColumn(f, column, dataContexts) {
|
|
54
54
|
iterateIndexed((i, cell) => {
|
|
55
55
|
if (cell.tag === /* FreeText */
|
|
56
56
|
1) {
|
|
@@ -59,7 +59,7 @@ function DataMapAux_setStringColumn(f, column, dataContexts) {
|
|
|
59
59
|
}
|
|
60
60
|
}, column);
|
|
61
61
|
}
|
|
62
|
-
function
|
|
62
|
+
function DatamapAux_SanityChecks_rowIndexInBoundaries(row, dataContexts) {
|
|
63
63
|
if (row < 0) {
|
|
64
64
|
throw new Error("Row index must be greater or equal to 0.");
|
|
65
65
|
}
|
|
@@ -67,12 +67,12 @@ function DataMapAux_SanityChecks_rowIndexInBoundaries(row, dataContexts) {
|
|
|
67
67
|
throw new Error("Row index must be less than the number of rows.");
|
|
68
68
|
}
|
|
69
69
|
}
|
|
70
|
-
function
|
|
70
|
+
function DatamapAux_SanityChecks_lengthOfNewColumn(newColumn, dataContexts) {
|
|
71
71
|
if (newColumn.length !== dataContexts.length) {
|
|
72
72
|
throw new Error("Length of new column does not match length of data contexts.");
|
|
73
73
|
}
|
|
74
74
|
}
|
|
75
|
-
class
|
|
75
|
+
class Datamap {
|
|
76
76
|
constructor(dataContexts) {
|
|
77
77
|
this.staticHash = 0;
|
|
78
78
|
this["dataContexts@108"] = dataContexts;
|
|
@@ -90,61 +90,61 @@ class DataMap {
|
|
|
90
90
|
return this$["dataContexts@108"];
|
|
91
91
|
}
|
|
92
92
|
static init() {
|
|
93
|
-
return new
|
|
93
|
+
return new Datamap([]);
|
|
94
94
|
}
|
|
95
95
|
GetExplicationColumn() {
|
|
96
96
|
const this$ = this;
|
|
97
|
-
return
|
|
97
|
+
return DatamapAux_getOntologyColumn(DataContext__get_Explication, this$["dataContexts@108"]);
|
|
98
98
|
}
|
|
99
99
|
SetExplicationColumn(cells) {
|
|
100
100
|
const this$ = this;
|
|
101
|
-
|
|
101
|
+
DatamapAux_setOntologyColumn((dc, oa) => {
|
|
102
102
|
DataContext__set_Explication_279AAFF2(dc, oa);
|
|
103
103
|
}, cells, this$["dataContexts@108"]);
|
|
104
104
|
}
|
|
105
105
|
GetUnitColumn() {
|
|
106
106
|
const this$ = this;
|
|
107
|
-
return
|
|
107
|
+
return DatamapAux_getOntologyColumn(DataContext__get_Unit, this$["dataContexts@108"]);
|
|
108
108
|
}
|
|
109
109
|
SetUnitColumn(cells) {
|
|
110
110
|
const this$ = this;
|
|
111
|
-
|
|
111
|
+
DatamapAux_setOntologyColumn((dc, oa) => {
|
|
112
112
|
DataContext__set_Unit_279AAFF2(dc, oa);
|
|
113
113
|
}, cells, this$["dataContexts@108"]);
|
|
114
114
|
}
|
|
115
115
|
GetObjectTypeColumn() {
|
|
116
116
|
const this$ = this;
|
|
117
|
-
return
|
|
117
|
+
return DatamapAux_getOntologyColumn(DataContext__get_ObjectType, this$["dataContexts@108"]);
|
|
118
118
|
}
|
|
119
119
|
SetDataTypeColumn(cells) {
|
|
120
120
|
const this$ = this;
|
|
121
|
-
|
|
121
|
+
DatamapAux_setOntologyColumn((dc, oa) => {
|
|
122
122
|
DataContext__set_ObjectType_279AAFF2(dc, oa);
|
|
123
123
|
}, cells, this$["dataContexts@108"]);
|
|
124
124
|
}
|
|
125
125
|
GetLabelColumn() {
|
|
126
126
|
const this$ = this;
|
|
127
|
-
return
|
|
127
|
+
return DatamapAux_getStringColumn((dc) => dc.Name, this$["dataContexts@108"]);
|
|
128
128
|
}
|
|
129
129
|
SetLabelColumn(cells) {
|
|
130
130
|
const this$ = this;
|
|
131
|
-
|
|
131
|
+
DatamapAux_setStringColumn((dc, s) => {
|
|
132
132
|
dc.Name = s;
|
|
133
133
|
}, cells, this$["dataContexts@108"]);
|
|
134
134
|
}
|
|
135
135
|
GetDescriptionColumn() {
|
|
136
136
|
const this$ = this;
|
|
137
|
-
return
|
|
137
|
+
return DatamapAux_getStringColumn(DataContext__get_Description, this$["dataContexts@108"]);
|
|
138
138
|
}
|
|
139
139
|
SetDescriptionColumn(cells) {
|
|
140
140
|
const this$ = this;
|
|
141
|
-
|
|
141
|
+
DatamapAux_setStringColumn((dc, s) => {
|
|
142
142
|
DataContext__set_Description_6DFDD678(dc, s);
|
|
143
143
|
}, cells, this$["dataContexts@108"]);
|
|
144
144
|
}
|
|
145
145
|
GetDataContext(row, SkipValidation) {
|
|
146
146
|
const this$ = this;
|
|
147
|
-
|
|
147
|
+
DatamapAux_SanityChecks_rowIndexInBoundaries(row, this$["dataContexts@108"]);
|
|
148
148
|
return this$["dataContexts@108"][row];
|
|
149
149
|
}
|
|
150
150
|
static getDataContext(row, SkipValidation) {
|
|
@@ -153,7 +153,7 @@ class DataMap {
|
|
|
153
153
|
Copy() {
|
|
154
154
|
let collection;
|
|
155
155
|
const this$ = this;
|
|
156
|
-
return new
|
|
156
|
+
return new Datamap((collection = map(DataContext__Copy, this$["dataContexts@108"]), Array.from(collection)));
|
|
157
157
|
}
|
|
158
158
|
Equals(obj) {
|
|
159
159
|
const this$ = this;
|
|
@@ -167,11 +167,11 @@ class DataMap {
|
|
|
167
167
|
return "isa.datamap.xlsx";
|
|
168
168
|
}
|
|
169
169
|
}
|
|
170
|
-
function
|
|
171
|
-
return class_type("ARCtrl.
|
|
170
|
+
function Datamap_$reflection() {
|
|
171
|
+
return class_type("ARCtrl.Datamap", void 0, Datamap);
|
|
172
172
|
}
|
|
173
|
-
function
|
|
174
|
-
return new
|
|
173
|
+
function Datamap_$ctor_4E3220A7(dataContexts) {
|
|
174
|
+
return new Datamap(dataContexts);
|
|
175
175
|
}
|
|
176
176
|
|
|
177
|
-
export {
|
|
177
|
+
export { Datamap, DatamapAux_SanityChecks_lengthOfNewColumn, DatamapAux_SanityChecks_rowIndexInBoundaries, DatamapAux_allowedHeaders, DatamapAux_dataHeader, DatamapAux_descriptionHeader, DatamapAux_explication, DatamapAux_explicationHeader, DatamapAux_generatedByHeader, DatamapAux_getOntologyColumn, DatamapAux_getStringColumn, DatamapAux_labelHeader, DatamapAux_objectType, DatamapAux_objectTypeHeader, DatamapAux_setOntologyColumn, DatamapAux_setStringColumn, DatamapAux_unit, DatamapAux_unitHeader, Datamap_$ctor_4E3220A7, Datamap_$reflection };
|
|
@@ -41,10 +41,10 @@ export declare class FileSystemTree<Tag extends keyof FileSystemTree_$cases> ext
|
|
|
41
41
|
static createGitKeepFile(): FileSystemTree_$union;
|
|
42
42
|
static createReadmeFile(): FileSystemTree_$union;
|
|
43
43
|
static createEmptyFolder(name: string): FileSystemTree_$union;
|
|
44
|
-
static createAssayFolder(assayName: string,
|
|
45
|
-
static createStudyFolder(studyName: string,
|
|
46
|
-
static createWorkflowFolder(workflowName: string, hasCWL?: boolean,
|
|
47
|
-
static createRunFolder(runName: string, hasCWL?: boolean, hasYML?: boolean,
|
|
44
|
+
static createAssayFolder(assayName: string, hasDatamap?: boolean): FileSystemTree_$union;
|
|
45
|
+
static createStudyFolder(studyName: string, hasDatamap?: boolean): FileSystemTree_$union;
|
|
46
|
+
static createWorkflowFolder(workflowName: string, hasCWL?: boolean, hasDatamap?: boolean): FileSystemTree_$union;
|
|
47
|
+
static createRunFolder(runName: string, hasCWL?: boolean, hasYML?: boolean, hasDatamap?: boolean): FileSystemTree_$union;
|
|
48
48
|
static createInvestigationFile(): FileSystemTree_$union;
|
|
49
49
|
static createLicenseFile(): FileSystemTree_$union;
|
|
50
50
|
static createAssaysFolder(assays: FileSystemTree_$union[]): FileSystemTree_$union;
|
|
@@ -272,46 +272,46 @@ class FileSystemTree extends Union {
|
|
|
272
272
|
static createEmptyFolder(name) {
|
|
273
273
|
return FileSystemTree.createFolder(name, [FileSystemTree.createGitKeepFile()]);
|
|
274
274
|
}
|
|
275
|
-
static createAssayFolder(assayName,
|
|
276
|
-
const
|
|
275
|
+
static createAssayFolder(assayName, hasDatamap) {
|
|
276
|
+
const hasDatamap_1 = defaultArg(hasDatamap, false);
|
|
277
277
|
const dataset = FileSystemTree.createEmptyFolder("dataset");
|
|
278
278
|
const protocols = FileSystemTree.createEmptyFolder("protocols");
|
|
279
279
|
const readme = FileSystemTree.createReadmeFile();
|
|
280
280
|
const assayFile = FileSystemTree.createFile("isa.assay.xlsx");
|
|
281
|
-
if (
|
|
282
|
-
const
|
|
283
|
-
return FileSystemTree.createFolder(assayName, [dataset, protocols, assayFile, readme,
|
|
281
|
+
if (hasDatamap_1) {
|
|
282
|
+
const datamapFile = FileSystemTree.createFile("isa.datamap.xlsx");
|
|
283
|
+
return FileSystemTree.createFolder(assayName, [dataset, protocols, assayFile, readme, datamapFile]);
|
|
284
284
|
} else {
|
|
285
285
|
return FileSystemTree.createFolder(assayName, [dataset, protocols, assayFile, readme]);
|
|
286
286
|
}
|
|
287
287
|
}
|
|
288
|
-
static createStudyFolder(studyName,
|
|
289
|
-
const
|
|
288
|
+
static createStudyFolder(studyName, hasDatamap) {
|
|
289
|
+
const hasDatamap_1 = defaultArg(hasDatamap, false);
|
|
290
290
|
const resources = FileSystemTree.createEmptyFolder("resources");
|
|
291
291
|
const protocols = FileSystemTree.createEmptyFolder("protocols");
|
|
292
292
|
const readme = FileSystemTree.createReadmeFile();
|
|
293
293
|
const studyFile = FileSystemTree.createFile("isa.study.xlsx");
|
|
294
|
-
if (
|
|
295
|
-
const
|
|
296
|
-
return FileSystemTree.createFolder(studyName, [resources, protocols, studyFile, readme,
|
|
294
|
+
if (hasDatamap_1) {
|
|
295
|
+
const datamapFile = FileSystemTree.createFile("isa.datamap.xlsx");
|
|
296
|
+
return FileSystemTree.createFolder(studyName, [resources, protocols, studyFile, readme, datamapFile]);
|
|
297
297
|
} else {
|
|
298
298
|
return FileSystemTree.createFolder(studyName, [resources, protocols, studyFile, readme]);
|
|
299
299
|
}
|
|
300
300
|
}
|
|
301
|
-
static createWorkflowFolder(workflowName, hasCWL,
|
|
302
|
-
const
|
|
301
|
+
static createWorkflowFolder(workflowName, hasCWL, hasDatamap) {
|
|
302
|
+
const hasDatamap_1 = defaultArg(hasDatamap, false);
|
|
303
303
|
const hasCWL_1 = defaultArg(hasCWL, false);
|
|
304
304
|
const readme = FileSystemTree.createReadmeFile();
|
|
305
305
|
const workflowFile = FileSystemTree.createFile("isa.workflow.xlsx");
|
|
306
|
-
return FileSystemTree.createFolder(workflowName, toArray(delay(() => append(singleton(workflowFile), delay(() => append(singleton(readme), delay(() => append(hasCWL_1 ? singleton(FileSystemTree.createFile("workflow.cwl")) : empty$1(), delay(() =>
|
|
306
|
+
return FileSystemTree.createFolder(workflowName, toArray(delay(() => append(singleton(workflowFile), delay(() => append(singleton(readme), delay(() => append(hasCWL_1 ? singleton(FileSystemTree.createFile("workflow.cwl")) : empty$1(), delay(() => hasDatamap_1 ? singleton(FileSystemTree.createFile("isa.datamap.xlsx")) : empty$1())))))))));
|
|
307
307
|
}
|
|
308
|
-
static createRunFolder(runName, hasCWL, hasYML,
|
|
309
|
-
const
|
|
308
|
+
static createRunFolder(runName, hasCWL, hasYML, hasDatamap) {
|
|
309
|
+
const hasDatamap_1 = defaultArg(hasDatamap, false);
|
|
310
310
|
const hasCWL_1 = defaultArg(hasCWL, false);
|
|
311
311
|
const hasYML_1 = defaultArg(hasYML, false);
|
|
312
312
|
const readme = FileSystemTree.createReadmeFile();
|
|
313
313
|
const runFile = FileSystemTree.createFile("isa.run.xlsx");
|
|
314
|
-
return FileSystemTree.createFolder(runName, toArray(delay(() => append(singleton(runFile), delay(() => append(singleton(readme), delay(() => append(hasCWL_1 ? singleton(FileSystemTree.createFile("run.cwl")) : empty$1(), delay(() => append(hasYML_1 ? singleton(FileSystemTree.createFile("run.yml")) : empty$1(), delay(() =>
|
|
314
|
+
return FileSystemTree.createFolder(runName, toArray(delay(() => append(singleton(runFile), delay(() => append(singleton(readme), delay(() => append(hasCWL_1 ? singleton(FileSystemTree.createFile("run.cwl")) : empty$1(), delay(() => append(hasYML_1 ? singleton(FileSystemTree.createFile("run.yml")) : empty$1(), delay(() => hasDatamap_1 ? singleton(FileSystemTree.createFile("isa.datamap.xlsx")) : empty$1())))))))))));
|
|
315
315
|
}
|
|
316
316
|
static createInvestigationFile() {
|
|
317
317
|
return FileSystemTree.createFile("isa.investigation.xlsx");
|
package/dist/ts/ts/Json/Assay.js
CHANGED
|
@@ -2,7 +2,7 @@ import { choose, ofArray, singleton, empty } from '../../node_modules/@fable-org
|
|
|
2
2
|
import { map, unwrap, defaultArg, value, bind } from '../../node_modules/@fable-org/fable-library-js/Option.js';
|
|
3
3
|
import { tryInclude, tryIncludeSeq, tryIncludeList } from './Encode.js';
|
|
4
4
|
import { OntologyAnnotation_encoder, OntologyAnnotation_decoder, OntologyAnnotation_ROCrate_encoderPropertyValue, OntologyAnnotation_ROCrate_encoderDefinedTerm, OntologyAnnotation_ROCrate_decoderPropertyValue, OntologyAnnotation_ROCrate_decoderDefinedTerm, OntologyAnnotation_ISAJson_encoder, OntologyAnnotation_ISAJson_decoder } from './OntologyAnnotation.js';
|
|
5
|
-
import { encoder as encoder$1, decoder as decoder$2, encoderCompressed as encoderCompressed$2, decoderCompressed as decoderCompressed$2 } from './
|
|
5
|
+
import { encoder as encoder$1, decoder as decoder$2, encoderCompressed as encoderCompressed$2, decoderCompressed as decoderCompressed$2 } from './Datamap/Datamap.js';
|
|
6
6
|
import { encoder as encoder$2, decoder as decoder$1, encoderCompressed as encoderCompressed$1, decoderCompressed as decoderCompressed$1 } from './Table/ArcTable.js';
|
|
7
7
|
import { encoder as encoder$3, decoder as decoder$3, ROCrate_encoder as ROCrate_encoder$1, ROCrate_decoder as ROCrate_decoder$2 } from './Person.js';
|
|
8
8
|
import { encoder as encoder$4, decoder as decoder$4, ROCrate_encoder as ROCrate_encoder$4, ROCrate_decoder as ROCrate_decoder$3, ISAJson_encoder as ISAJson_encoder$3, ISAJson_decoder as ISAJson_decoder$2 } from './Comment.js';
|
|
@@ -38,7 +38,7 @@ function encoder(assay) {
|
|
|
38
38
|
Encode(helpers_2) {
|
|
39
39
|
return helpers_2.encodeString(value_3);
|
|
40
40
|
}
|
|
41
|
-
}), assay.Description), tryInclude("MeasurementType", OntologyAnnotation_encoder, assay.MeasurementType), tryInclude("TechnologyType", OntologyAnnotation_encoder, assay.TechnologyType), tryInclude("TechnologyPlatform", OntologyAnnotation_encoder, assay.TechnologyPlatform), tryInclude("
|
|
41
|
+
}), assay.Description), tryInclude("MeasurementType", OntologyAnnotation_encoder, assay.MeasurementType), tryInclude("TechnologyType", OntologyAnnotation_encoder, assay.TechnologyType), tryInclude("TechnologyPlatform", OntologyAnnotation_encoder, assay.TechnologyPlatform), tryInclude("Datamap", encoder$1, assay.Datamap), tryIncludeSeq("Tables", encoder$2, assay.Tables), tryIncludeSeq("Performers", encoder$3, assay.Performers), tryIncludeSeq("Comments", encoder$4, assay.Comments)]));
|
|
42
42
|
return {
|
|
43
43
|
Encode(helpers_3) {
|
|
44
44
|
const arg = map$1((tupledArg_1) => [tupledArg_1[0], tupledArg_1[1].Encode(helpers_3)], values_1);
|
|
@@ -48,7 +48,7 @@ function encoder(assay) {
|
|
|
48
48
|
}
|
|
49
49
|
const decoder = object((get$) => {
|
|
50
50
|
let objectArg, objectArg_1, objectArg_2, objectArg_3, objectArg_4, objectArg_5, arg_13, objectArg_6, objectArg_7, arg_17, objectArg_8, arg_19, objectArg_9;
|
|
51
|
-
return ArcAssay.create((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("MeasurementType", OntologyAnnotation_decoder))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("TechnologyType", OntologyAnnotation_decoder))), unwrap((objectArg_5 = get$.Optional, objectArg_5.Field("TechnologyPlatform", OntologyAnnotation_decoder))), unwrap((arg_13 = resizeArray(decoder$1), objectArg_6 = get$.Optional, objectArg_6.Field("Tables", arg_13))), unwrap((objectArg_7 = get$.Optional, objectArg_7.Field("
|
|
51
|
+
return ArcAssay.create((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("MeasurementType", OntologyAnnotation_decoder))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("TechnologyType", OntologyAnnotation_decoder))), unwrap((objectArg_5 = get$.Optional, objectArg_5.Field("TechnologyPlatform", OntologyAnnotation_decoder))), unwrap((arg_13 = resizeArray(decoder$1), objectArg_6 = get$.Optional, objectArg_6.Field("Tables", arg_13))), unwrap((objectArg_7 = get$.Optional, objectArg_7.Field("Datamap", decoder$2))), unwrap((arg_17 = resizeArray(decoder$3), objectArg_8 = get$.Optional, objectArg_8.Field("Performers", arg_17))), unwrap((arg_19 = resizeArray(decoder$4), objectArg_9 = get$.Optional, objectArg_9.Field("Comments", arg_19))));
|
|
52
52
|
});
|
|
53
53
|
function encoderCompressed(stringTable, oaTable, cellTable, assay) {
|
|
54
54
|
let value;
|
|
@@ -64,7 +64,7 @@ function encoderCompressed(stringTable, oaTable, cellTable, assay) {
|
|
|
64
64
|
Encode(helpers_2) {
|
|
65
65
|
return helpers_2.encodeString(value_3);
|
|
66
66
|
}
|
|
67
|
-
}), assay.Description), tryInclude("MeasurementType", OntologyAnnotation_encoder, assay.MeasurementType), tryInclude("TechnologyType", OntologyAnnotation_encoder, assay.TechnologyType), tryInclude("TechnologyPlatform", OntologyAnnotation_encoder, assay.TechnologyPlatform), tryIncludeSeq("Tables", (table) => encoderCompressed$1(stringTable, oaTable, cellTable, table), assay.Tables), tryInclude("
|
|
67
|
+
}), assay.Description), tryInclude("MeasurementType", OntologyAnnotation_encoder, assay.MeasurementType), tryInclude("TechnologyType", OntologyAnnotation_encoder, assay.TechnologyType), tryInclude("TechnologyPlatform", OntologyAnnotation_encoder, assay.TechnologyPlatform), tryIncludeSeq("Tables", (table) => encoderCompressed$1(stringTable, oaTable, cellTable, table), assay.Tables), tryInclude("Datamap", (dm) => encoderCompressed$2(stringTable, oaTable, cellTable, dm), assay.Datamap), tryIncludeSeq("Performers", encoder$3, assay.Performers), tryIncludeSeq("Comments", encoder$4, assay.Comments)]));
|
|
68
68
|
return {
|
|
69
69
|
Encode(helpers_3) {
|
|
70
70
|
const arg = map$1((tupledArg_1) => [tupledArg_1[0], tupledArg_1[1].Encode(helpers_3)], values_1);
|
|
@@ -75,7 +75,7 @@ function encoderCompressed(stringTable, oaTable, cellTable, assay) {
|
|
|
75
75
|
function decoderCompressed(stringTable, oaTable, cellTable) {
|
|
76
76
|
return object((get$) => {
|
|
77
77
|
let objectArg, objectArg_1, objectArg_2, objectArg_3, objectArg_4, objectArg_5, arg_13, objectArg_6, arg_15, objectArg_7, arg_17, objectArg_8, arg_19, objectArg_9;
|
|
78
|
-
return ArcAssay.create((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("MeasurementType", OntologyAnnotation_decoder))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("TechnologyType", OntologyAnnotation_decoder))), unwrap((objectArg_5 = get$.Optional, objectArg_5.Field("TechnologyPlatform", OntologyAnnotation_decoder))), unwrap((arg_13 = resizeArray(decoderCompressed$1(stringTable, oaTable, cellTable)), objectArg_6 = get$.Optional, objectArg_6.Field("Tables", arg_13))), unwrap((arg_15 = decoderCompressed$2(stringTable, oaTable, cellTable), objectArg_7 = get$.Optional, objectArg_7.Field("
|
|
78
|
+
return ArcAssay.create((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("MeasurementType", OntologyAnnotation_decoder))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("TechnologyType", OntologyAnnotation_decoder))), unwrap((objectArg_5 = get$.Optional, objectArg_5.Field("TechnologyPlatform", OntologyAnnotation_decoder))), unwrap((arg_13 = resizeArray(decoderCompressed$1(stringTable, oaTable, cellTable)), objectArg_6 = get$.Optional, objectArg_6.Field("Tables", arg_13))), unwrap((arg_15 = decoderCompressed$2(stringTable, oaTable, cellTable), objectArg_7 = get$.Optional, objectArg_7.Field("Datamap", arg_15))), unwrap((arg_17 = resizeArray(decoder$3), objectArg_8 = get$.Optional, objectArg_8.Field("Performers", arg_17))), unwrap((arg_19 = resizeArray(decoder$4), objectArg_9 = get$.Optional, objectArg_9.Field("Comments", arg_19))));
|
|
79
79
|
});
|
|
80
80
|
}
|
|
81
81
|
function ROCrate_genID(a) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataContext.d.ts","sourceRoot":"","sources":["../../../../../src/ARCtrl/ts/Json/
|
|
1
|
+
{"version":3,"file":"DataContext.d.ts","sourceRoot":"","sources":["../../../../../src/ARCtrl/ts/Json/Datamap/DataContext.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,EAAqB,UAAU,EAAE,MAAM,uDAAuD,CAAC;AAKjH,OAAO,EAA+B,WAAW,EAAwK,MAAM,2BAA2B,CAAC;AAK3P,wBAAgB,OAAO,CAAC,EAAE,EAAE,WAAW,GAAG,UAAU,CAoBnD;AAED,eAAO,MAAM,OAAO,EAAE,SAAS,CAAC,WAAW,CAMzC,CAAC"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { Decoder$1, IEncodable } from '../../fable_modules/Thoth.Json.Core.0.7.0/Types.fs.js';
|
|
2
|
-
import {
|
|
2
|
+
import { Datamap } from '../../Core/Datamap.js';
|
|
3
3
|
import { IMap } from '@fable-org/fable-library-js/Util.js';
|
|
4
4
|
import { int32 } from '@fable-org/fable-library-js/Int32.js';
|
|
5
5
|
import { OntologyAnnotation } from '../../Core/OntologyAnnotation.js';
|
|
6
6
|
import { CompositeCell_$union } from '../../Core/Table/CompositeCell.js';
|
|
7
|
-
export declare function encoder(dm:
|
|
8
|
-
export declare const decoder: Decoder$1<
|
|
9
|
-
export declare function encoderCompressed(stringTable: IMap<string, int32>, oaTable: IMap<OntologyAnnotation, int32>, cellTable: IMap<CompositeCell_$union, int32>, dm:
|
|
10
|
-
export declare function decoderCompressed(stringTable: string[], oaTable: OntologyAnnotation[], cellTable: CompositeCell_$union[]): Decoder$1<
|
|
11
|
-
//# sourceMappingURL=
|
|
7
|
+
export declare function encoder(dm: Datamap): IEncodable;
|
|
8
|
+
export declare const decoder: Decoder$1<Datamap>;
|
|
9
|
+
export declare function encoderCompressed(stringTable: IMap<string, int32>, oaTable: IMap<OntologyAnnotation, int32>, cellTable: IMap<CompositeCell_$union, int32>, dm: Datamap): IEncodable;
|
|
10
|
+
export declare function decoderCompressed(stringTable: string[], oaTable: OntologyAnnotation[], cellTable: CompositeCell_$union[]): Decoder$1<Datamap>;
|
|
11
|
+
//# sourceMappingURL=Datamap.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"
|
|
1
|
+
{"version":3,"file":"Datamap.d.ts","sourceRoot":"","sources":["../../../../../src/ARCtrl/ts/Json/Datamap/Datamap.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,SAAS,EAAqB,UAAU,EAAE,MAAM,uDAAuD,CAAC;AACjH,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAEhD,OAAO,EAAE,IAAI,EAAE,MAAM,qCAAqC,CAAC;AAC3D,OAAO,EAAE,KAAK,EAAE,MAAM,sCAAsC,CAAC;AAC7D,OAAO,EAAE,kBAAkB,EAAE,MAAM,kCAAkC,CAAC;AACtE,OAAO,EAAE,oBAAoB,EAAE,MAAM,mCAAmC,CAAC;AAEzE,wBAAgB,OAAO,CAAC,EAAE,EAAE,OAAO,GAAG,UAAU,CAQ/C;AAED,eAAO,MAAM,OAAO,EAAE,SAAS,CAAC,OAAO,CAGrC,CAAC;AAEH,wBAAgB,iBAAiB,CAAC,WAAW,EAAE,IAAI,CAAC,MAAM,EAAE,KAAK,CAAC,EAAE,OAAO,EAAE,IAAI,CAAC,kBAAkB,EAAE,KAAK,CAAC,EAAE,SAAS,EAAE,IAAI,CAAC,oBAAoB,EAAE,KAAK,CAAC,EAAE,EAAE,EAAE,OAAO,GAAG,UAAU,CAEnL;AAED,wBAAgB,iBAAiB,CAAC,WAAW,EAAE,MAAM,EAAE,EAAE,OAAO,EAAE,kBAAkB,EAAE,EAAE,SAAS,EAAE,oBAAoB,EAAE,GAAG,SAAS,CAAC,OAAO,CAAC,CAE7I"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { seq } from '../../fable_modules/Thoth.Json.Core.0.7.0/Encode.fs.js';
|
|
2
2
|
import { map } from '../../../node_modules/@fable-org/fable-library-js/Seq.js';
|
|
3
3
|
import { encoder as encoder$1, decoder as decoder$1 } from './DataContext.js';
|
|
4
|
-
import {
|
|
4
|
+
import { Datamap } from '../../Core/Datamap.js';
|
|
5
5
|
import { object, resizeArray } from '../../fable_modules/Thoth.Json.Core.0.7.0/Decode.fs.js';
|
|
6
6
|
|
|
7
7
|
function encoder(dm) {
|
|
@@ -15,7 +15,7 @@ function encoder(dm) {
|
|
|
15
15
|
}
|
|
16
16
|
const decoder = object((get$) => {
|
|
17
17
|
let arg_1, objectArg;
|
|
18
|
-
return new
|
|
18
|
+
return new Datamap((arg_1 = resizeArray(decoder$1), objectArg = get$.Required, objectArg.Field("dataContexts", arg_1)));
|
|
19
19
|
});
|
|
20
20
|
function encoderCompressed(stringTable, oaTable, cellTable, dm) {
|
|
21
21
|
return encoder(dm);
|
|
@@ -2,6 +2,7 @@ import { Decoder$1, IEncodable } from '../../fable_modules/Thoth.Json.Core.0.7.0
|
|
|
2
2
|
import { LDNode } from '../../ROCrate/LDObject.js';
|
|
3
3
|
export declare function genericEncoder(obj: any): IEncodable;
|
|
4
4
|
export declare function encoder(obj: LDNode): IEncodable;
|
|
5
|
+
export declare const nullDecoder: Decoder$1<void>;
|
|
5
6
|
/**
|
|
6
7
|
* Returns a decoder
|
|
7
8
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LDNode.d.ts","sourceRoot":"","sources":["../../../../../src/ARCtrl/ts/Json/ROCrate/LDNode.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"LDNode.d.ts","sourceRoot":"","sources":["../../../../../src/ARCtrl/ts/Json/ROCrate/LDNode.ts"],"names":[],"mappings":"AAAA,OAAO,EAA0B,SAAS,EAAuE,UAAU,EAAqB,MAAM,uDAAuD,CAAC;AAG9M,OAAO,EAAE,MAAM,EAAkB,MAAM,2BAA2B,CAAC;AAgBnE,wBAAgB,cAAc,CAAC,GAAG,EAAE,GAAG,GAAG,UAAU,CA+DnD;AAED,wBAAgB,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,CA6B/C;AAED,eAAO,MAAM,WAAW,EAAE,SAAS,CAAC,IAAI,CAIvC,CAAC;AAEF;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,YAAY,EAAE,OAAO,GAAG,SAAS,CAAC,GAAG,CAAC,CAgGhE;AAED,eAAO,MAAM,OAAO,EAAE,SAAS,CAAC,MAAM,CAAuE,CAAC;AAE9G,eAAO,MAAM,cAAc,EAAE,SAAS,CAAC,GAAG,CAAqB,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ErrorReason$
|
|
1
|
+
import { ErrorReason$1_BadPrimitive, ErrorReason$1_BadOneOf } from '../../fable_modules/Thoth.Json.Core.0.7.0/Types.fs.js';
|
|
2
2
|
import { dateTime, resizeArrayOrSingleton } from '../Encode.js';
|
|
3
3
|
import { LDValue, LDRef, LDNode } from '../../ROCrate/LDObject.js';
|
|
4
4
|
import { encoder as encoder$1, decoder as decoder$2 } from './LDValue.js';
|
|
@@ -8,10 +8,10 @@ import { list } from '../../fable_modules/Thoth.Json.Core.0.7.0/Encode.fs.js';
|
|
|
8
8
|
import { toList, delay, map, enumerateFromFunctions, append, singleton, empty, collect } from '../../../node_modules/@fable-org/fable-library-js/Seq.js';
|
|
9
9
|
import { encoder as encoder$3, decoder as decoder$1 } from './LDContext.js';
|
|
10
10
|
import { value, unwrap } from '../../../node_modules/@fable-org/fable-library-js/Option.js';
|
|
11
|
-
import {
|
|
11
|
+
import { FSharpResult$2_Ok, FSharpResult$2_Error } from '../../../node_modules/@fable-org/fable-library-js/Result.js';
|
|
12
|
+
import { Getters$2_$ctor_Z4BE6C149, string, Getters$2__get_Errors, map as map$1, oneOf, int, decimal, bool } from '../../fable_modules/Thoth.Json.Core.0.7.0/Decode.fs.js';
|
|
12
13
|
import { Decode_resizeArrayOrSingleton, Helpers_prependPath } from '../Decode.js';
|
|
13
14
|
import { isEmpty, length, head, ofArray } from '../../../node_modules/@fable-org/fable-library-js/List.js';
|
|
14
|
-
import { FSharpResult$2_Error, FSharpResult$2_Ok } from '../../../node_modules/@fable-org/fable-library-js/Result.js';
|
|
15
15
|
import { fold } from '../../../node_modules/@fable-org/fable-library-js/Array.js';
|
|
16
16
|
|
|
17
17
|
function genericEncoder(obj) {
|
|
@@ -98,11 +98,16 @@ function encoder(obj) {
|
|
|
98
98
|
}
|
|
99
99
|
};
|
|
100
100
|
}
|
|
101
|
+
const nullDecoder = {
|
|
102
|
+
Decode(helpers, value) {
|
|
103
|
+
return helpers.isNullValue(value) ? FSharpResult$2_Ok(void 0) : FSharpResult$2_Error(["", ErrorReason$1_BadPrimitive("null", value)]);
|
|
104
|
+
}
|
|
105
|
+
};
|
|
101
106
|
function getDecoder(expectObject) {
|
|
102
107
|
const decode = (expectObject_1) => {
|
|
103
108
|
const decodeObject = {
|
|
104
109
|
Decode(helpers, value$1) {
|
|
105
|
-
let arg_7, objectArg_3
|
|
110
|
+
let arg_7, objectArg_3;
|
|
106
111
|
if (helpers.isObject(value$1)) {
|
|
107
112
|
const getters = Getters$2_$ctor_Z4BE6C149(helpers, value$1);
|
|
108
113
|
const properties = helpers.getProperties(value$1);
|
|
@@ -124,7 +129,13 @@ function getDecoder(expectObject) {
|
|
|
124
129
|
while (enumerator["System.Collections.IEnumerator.MoveNext"]()) {
|
|
125
130
|
const property = enumerator["System.Collections.Generic.IEnumerator`1.get_Current"]();
|
|
126
131
|
if (property !== "@id" && property !== "@type" && property !== "@context") {
|
|
127
|
-
|
|
132
|
+
let r;
|
|
133
|
+
const arg_9 = decode(false);
|
|
134
|
+
const objectArg_4 = get$.Required;
|
|
135
|
+
r = objectArg_4.Field(property, arg_9);
|
|
136
|
+
if (!equals(r, defaultOf())) {
|
|
137
|
+
o.SetProperty(property, r);
|
|
138
|
+
}
|
|
128
139
|
}
|
|
129
140
|
}
|
|
130
141
|
} finally {
|
|
@@ -179,7 +190,7 @@ function getDecoder(expectObject) {
|
|
|
179
190
|
if (expectObject_1) {
|
|
180
191
|
return map$1((value_4) => value_4, decodeObject);
|
|
181
192
|
} else {
|
|
182
|
-
return oneOf(ofArray([map$1((value_5) => value_5, decoder$2), map$1((value_6) => value_6, decodeObject), map$1((value_7) => value_7, decoder$3), map$1((value_8) => value_8, resizeArray), map$1((value_9) => value_9, string), map$1((value_10) => value_10, int), map$1((value_11) => value_11, decimal)]));
|
|
193
|
+
return oneOf(ofArray([map$1((value_5) => value_5, decoder$2), map$1((value_6) => value_6, decodeObject), map$1((value_7) => value_7, decoder$3), map$1((value_8) => value_8, resizeArray), map$1((value_9) => value_9, string), map$1((value_10) => value_10, int), map$1((value_11) => value_11, decimal), map$1((value_12) => value_12, bool), map$1(() => void 0, nullDecoder)]));
|
|
183
194
|
}
|
|
184
195
|
};
|
|
185
196
|
return decode(expectObject);
|
|
@@ -187,4 +198,4 @@ function getDecoder(expectObject) {
|
|
|
187
198
|
const decoder = map$1((value) => value, getDecoder(true));
|
|
188
199
|
const genericDecoder = getDecoder(false);
|
|
189
200
|
|
|
190
|
-
export { decoder, encoder, genericDecoder, genericEncoder, getDecoder };
|
|
201
|
+
export { decoder, encoder, genericDecoder, genericEncoder, getDecoder, nullDecoder };
|
package/dist/ts/ts/Json/Run.js
CHANGED
|
@@ -2,7 +2,7 @@ import { choose, ofArray } from '../../node_modules/@fable-org/fable-library-js/
|
|
|
2
2
|
import { map, unwrap } from '../../node_modules/@fable-org/fable-library-js/Option.js';
|
|
3
3
|
import { tryInclude, tryIncludeSeq } from './Encode.js';
|
|
4
4
|
import { OntologyAnnotation_encoder, OntologyAnnotation_decoder } from './OntologyAnnotation.js';
|
|
5
|
-
import { encoder as encoder$1, decoder as decoder$2, encoderCompressed as encoderCompressed$1, decoderCompressed as decoderCompressed$2 } from './
|
|
5
|
+
import { encoder as encoder$1, decoder as decoder$2, encoderCompressed as encoderCompressed$1, decoderCompressed as decoderCompressed$2 } from './Datamap/Datamap.js';
|
|
6
6
|
import { encoder as encoder$2, decoder as decoder$1, encoderCompressed as encoderCompressed$2, decoderCompressed as decoderCompressed$1 } from './Table/ArcTable.js';
|
|
7
7
|
import { encoder as encoder$3, decoder as decoder$3 } from './Person.js';
|
|
8
8
|
import { encoder as encoder$4, decoder as decoder$4 } from './Comment.js';
|
|
@@ -24,7 +24,7 @@ function encoder(run) {
|
|
|
24
24
|
Encode(helpers_2) {
|
|
25
25
|
return helpers_2.encodeString(value_3);
|
|
26
26
|
}
|
|
27
|
-
}), run.Description), tryInclude("MeasurementType", OntologyAnnotation_encoder, run.MeasurementType), tryInclude("TechnologyType", OntologyAnnotation_encoder, run.TechnologyType), tryInclude("TechnologyPlatform", OntologyAnnotation_encoder, run.TechnologyPlatform), tryInclude("
|
|
27
|
+
}), run.Description), tryInclude("MeasurementType", OntologyAnnotation_encoder, run.MeasurementType), tryInclude("TechnologyType", OntologyAnnotation_encoder, run.TechnologyType), tryInclude("TechnologyPlatform", OntologyAnnotation_encoder, run.TechnologyPlatform), tryInclude("Datamap", encoder$1, run.Datamap), tryIncludeSeq("WorkflowIdentifiers", (value_5) => ({
|
|
28
28
|
Encode(helpers_3) {
|
|
29
29
|
return helpers_3.encodeString(value_5);
|
|
30
30
|
}
|
|
@@ -38,7 +38,7 @@ function encoder(run) {
|
|
|
38
38
|
}
|
|
39
39
|
const decoder = object((get$) => {
|
|
40
40
|
let objectArg, objectArg_1, objectArg_2, objectArg_3, objectArg_4, objectArg_5, arg_13, objectArg_6, arg_15, objectArg_7, objectArg_8, arg_19, objectArg_9, arg_21, objectArg_10;
|
|
41
|
-
return ArcRun.create((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("MeasurementType", OntologyAnnotation_decoder))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("TechnologyType", OntologyAnnotation_decoder))), unwrap((objectArg_5 = get$.Optional, objectArg_5.Field("TechnologyPlatform", OntologyAnnotation_decoder))), unwrap((arg_13 = resizeArray(string), objectArg_6 = get$.Optional, objectArg_6.Field("WorkflowIdentifiers", arg_13))), unwrap((arg_15 = resizeArray(decoder$1), objectArg_7 = get$.Optional, objectArg_7.Field("Tables", arg_15))), unwrap((objectArg_8 = get$.Optional, objectArg_8.Field("
|
|
41
|
+
return ArcRun.create((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("MeasurementType", OntologyAnnotation_decoder))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("TechnologyType", OntologyAnnotation_decoder))), unwrap((objectArg_5 = get$.Optional, objectArg_5.Field("TechnologyPlatform", OntologyAnnotation_decoder))), unwrap((arg_13 = resizeArray(string), objectArg_6 = get$.Optional, objectArg_6.Field("WorkflowIdentifiers", arg_13))), unwrap((arg_15 = resizeArray(decoder$1), objectArg_7 = get$.Optional, objectArg_7.Field("Tables", arg_15))), unwrap((objectArg_8 = get$.Optional, objectArg_8.Field("Datamap", decoder$2))), unwrap((arg_19 = resizeArray(decoder$3), objectArg_9 = get$.Optional, objectArg_9.Field("Performers", arg_19))), void 0, void 0, unwrap((arg_21 = resizeArray(decoder$4), objectArg_10 = get$.Optional, objectArg_10.Field("Comments", arg_21))));
|
|
42
42
|
});
|
|
43
43
|
function encoderCompressed(stringTable, oaTable, cellTable, run) {
|
|
44
44
|
let value;
|
|
@@ -54,7 +54,7 @@ function encoderCompressed(stringTable, oaTable, cellTable, run) {
|
|
|
54
54
|
Encode(helpers_2) {
|
|
55
55
|
return helpers_2.encodeString(value_3);
|
|
56
56
|
}
|
|
57
|
-
}), run.Description), tryInclude("MeasurementType", OntologyAnnotation_encoder, run.MeasurementType), tryInclude("TechnologyType", OntologyAnnotation_encoder, run.TechnologyType), tryInclude("TechnologyPlatform", OntologyAnnotation_encoder, run.TechnologyPlatform), tryInclude("
|
|
57
|
+
}), run.Description), tryInclude("MeasurementType", OntologyAnnotation_encoder, run.MeasurementType), tryInclude("TechnologyType", OntologyAnnotation_encoder, run.TechnologyType), tryInclude("TechnologyPlatform", OntologyAnnotation_encoder, run.TechnologyPlatform), tryInclude("Datamap", (dm) => encoderCompressed$1(stringTable, oaTable, cellTable, dm), run.Datamap), tryIncludeSeq("WorkflowIdentifiers", (value_5) => ({
|
|
58
58
|
Encode(helpers_3) {
|
|
59
59
|
return helpers_3.encodeString(value_5);
|
|
60
60
|
}
|
|
@@ -69,7 +69,7 @@ function encoderCompressed(stringTable, oaTable, cellTable, run) {
|
|
|
69
69
|
function decoderCompressed(stringTable, oaTable, cellTable) {
|
|
70
70
|
return object((get$) => {
|
|
71
71
|
let objectArg, objectArg_1, objectArg_2, objectArg_3, objectArg_4, objectArg_5, arg_13, objectArg_6, arg_15, objectArg_7, arg_17, objectArg_8, arg_19, objectArg_9, arg_21, objectArg_10;
|
|
72
|
-
return ArcRun.create((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("MeasurementType", OntologyAnnotation_decoder))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("TechnologyType", OntologyAnnotation_decoder))), unwrap((objectArg_5 = get$.Optional, objectArg_5.Field("TechnologyPlatform", OntologyAnnotation_decoder))), unwrap((arg_13 = resizeArray(string), objectArg_6 = get$.Optional, objectArg_6.Field("WorkflowIdentifiers", arg_13))), unwrap((arg_15 = resizeArray(decoderCompressed$1(stringTable, oaTable, cellTable)), objectArg_7 = get$.Optional, objectArg_7.Field("Tables", arg_15))), unwrap((arg_17 = decoderCompressed$2(stringTable, oaTable, cellTable), objectArg_8 = get$.Optional, objectArg_8.Field("
|
|
72
|
+
return ArcRun.create((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("MeasurementType", OntologyAnnotation_decoder))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("TechnologyType", OntologyAnnotation_decoder))), unwrap((objectArg_5 = get$.Optional, objectArg_5.Field("TechnologyPlatform", OntologyAnnotation_decoder))), unwrap((arg_13 = resizeArray(string), objectArg_6 = get$.Optional, objectArg_6.Field("WorkflowIdentifiers", arg_13))), unwrap((arg_15 = resizeArray(decoderCompressed$1(stringTable, oaTable, cellTable)), objectArg_7 = get$.Optional, objectArg_7.Field("Tables", arg_15))), unwrap((arg_17 = decoderCompressed$2(stringTable, oaTable, cellTable), objectArg_8 = get$.Optional, objectArg_8.Field("Datamap", arg_17))), unwrap((arg_19 = resizeArray(decoder$3), objectArg_9 = get$.Optional, objectArg_9.Field("Performers", arg_19))), void 0, void 0, unwrap((arg_21 = resizeArray(decoder$4), objectArg_10 = get$.Optional, objectArg_10.Field("Comments", arg_21))));
|
|
73
73
|
});
|
|
74
74
|
}
|
|
75
75
|
|
package/dist/ts/ts/Json/Study.js
CHANGED
|
@@ -7,7 +7,7 @@ import { encoder as encoder$1, decoder as decoder$1, ROCrate_encoder as ROCrate_
|
|
|
7
7
|
import { encoder as encoder$2, decoder as decoder$2, ROCrate_encoder as ROCrate_encoder$2, ROCrate_decoder as ROCrate_decoder$4, ISAJson_encoder as ISAJson_encoder$3, ISAJson_decoder as ISAJson_decoder$3 } from './Person.js';
|
|
8
8
|
import { OntologyAnnotation_encoder, OntologyAnnotation_decoder, OntologyAnnotation_ROCrate_encoderDefinedTerm, OntologyAnnotation_ROCrate_decoderDefinedTerm, OntologyAnnotation_ISAJson_encoder, OntologyAnnotation_ISAJson_decoder } from './OntologyAnnotation.js';
|
|
9
9
|
import { encoder as encoder$3, decoder as decoder$3, encoderCompressed as encoderCompressed$1, decoderCompressed as decoderCompressed$1 } from './Table/ArcTable.js';
|
|
10
|
-
import { encoder as encoder$4, decoder as decoder$4, encoderCompressed as encoderCompressed$2, decoderCompressed as decoderCompressed$2 } from './
|
|
10
|
+
import { encoder as encoder$4, decoder as decoder$4, encoderCompressed as encoderCompressed$2, decoderCompressed as decoderCompressed$2 } from './Datamap/Datamap.js';
|
|
11
11
|
import { encoder as encoder$5, decoder as decoder$5, ROCrate_encoder as ROCrate_encoder$6, ROCrate_decoder as ROCrate_decoder$5, ISAJson_encoder as ISAJson_encoder$6, ISAJson_decoder as ISAJson_decoder$5 } from './Comment.js';
|
|
12
12
|
import { map as map$1, isEmpty } from '../../node_modules/@fable-org/fable-library-js/Seq.js';
|
|
13
13
|
import { object, string, resizeArray, list as list$1 } from '../fable_modules/Thoth.Json.Core.0.7.0/Decode.fs.js';
|
|
@@ -57,7 +57,7 @@ function encoder(study) {
|
|
|
57
57
|
Encode(helpers_4) {
|
|
58
58
|
return helpers_4.encodeString(value_7);
|
|
59
59
|
}
|
|
60
|
-
}), study.PublicReleaseDate), tryIncludeSeq("Publications", encoder$1, study.Publications), tryIncludeSeq("Contacts", encoder$2, study.Contacts), tryIncludeSeq("StudyDesignDescriptors", OntologyAnnotation_encoder, study.StudyDesignDescriptors), tryIncludeSeq("Tables", encoder$3, study.Tables), tryInclude("
|
|
60
|
+
}), study.PublicReleaseDate), tryIncludeSeq("Publications", encoder$1, study.Publications), tryIncludeSeq("Contacts", encoder$2, study.Contacts), tryIncludeSeq("StudyDesignDescriptors", OntologyAnnotation_encoder, study.StudyDesignDescriptors), tryIncludeSeq("Tables", encoder$3, study.Tables), tryInclude("Datamap", encoder$4, study.Datamap), tryIncludeSeq("RegisteredAssayIdentifiers", (value_9) => ({
|
|
61
61
|
Encode(helpers_5) {
|
|
62
62
|
return helpers_5.encodeString(value_9);
|
|
63
63
|
}
|
|
@@ -71,7 +71,7 @@ function encoder(study) {
|
|
|
71
71
|
}
|
|
72
72
|
const decoder = object((get$) => {
|
|
73
73
|
let objectArg, objectArg_1, objectArg_2, objectArg_3, objectArg_4, arg_11, objectArg_5, arg_13, objectArg_6, arg_15, objectArg_7, arg_17, objectArg_8, objectArg_9, arg_21, objectArg_10, arg_23, objectArg_11;
|
|
74
|
-
return new ArcStudy((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("SubmissionDate", string))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("PublicReleaseDate", string))), unwrap((arg_11 = resizeArray(decoder$1), objectArg_5 = get$.Optional, objectArg_5.Field("Publications", arg_11))), unwrap((arg_13 = resizeArray(decoder$2), objectArg_6 = get$.Optional, objectArg_6.Field("Contacts", arg_13))), unwrap((arg_15 = resizeArray(OntologyAnnotation_decoder), objectArg_7 = get$.Optional, objectArg_7.Field("StudyDesignDescriptors", arg_15))), unwrap((arg_17 = resizeArray(decoder$3), objectArg_8 = get$.Optional, objectArg_8.Field("Tables", arg_17))), unwrap((objectArg_9 = get$.Optional, objectArg_9.Field("
|
|
74
|
+
return new ArcStudy((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("SubmissionDate", string))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("PublicReleaseDate", string))), unwrap((arg_11 = resizeArray(decoder$1), objectArg_5 = get$.Optional, objectArg_5.Field("Publications", arg_11))), unwrap((arg_13 = resizeArray(decoder$2), objectArg_6 = get$.Optional, objectArg_6.Field("Contacts", arg_13))), unwrap((arg_15 = resizeArray(OntologyAnnotation_decoder), objectArg_7 = get$.Optional, objectArg_7.Field("StudyDesignDescriptors", arg_15))), unwrap((arg_17 = resizeArray(decoder$3), objectArg_8 = get$.Optional, objectArg_8.Field("Tables", arg_17))), unwrap((objectArg_9 = get$.Optional, objectArg_9.Field("Datamap", decoder$4))), unwrap((arg_21 = resizeArray(string), objectArg_10 = get$.Optional, objectArg_10.Field("RegisteredAssayIdentifiers", arg_21))), unwrap((arg_23 = resizeArray(decoder$5), objectArg_11 = get$.Optional, objectArg_11.Field("Comments", arg_23))));
|
|
75
75
|
});
|
|
76
76
|
function encoderCompressed(stringTable, oaTable, cellTable, study) {
|
|
77
77
|
let value;
|
|
@@ -95,7 +95,7 @@ function encoderCompressed(stringTable, oaTable, cellTable, study) {
|
|
|
95
95
|
Encode(helpers_4) {
|
|
96
96
|
return helpers_4.encodeString(value_7);
|
|
97
97
|
}
|
|
98
|
-
}), study.PublicReleaseDate), tryIncludeSeq("Publications", encoder$1, study.Publications), tryIncludeSeq("Contacts", encoder$2, study.Contacts), tryIncludeSeq("StudyDesignDescriptors", OntologyAnnotation_encoder, study.StudyDesignDescriptors), tryIncludeSeq("Tables", (table) => encoderCompressed$1(stringTable, oaTable, cellTable, table), study.Tables), tryInclude("
|
|
98
|
+
}), study.PublicReleaseDate), tryIncludeSeq("Publications", encoder$1, study.Publications), tryIncludeSeq("Contacts", encoder$2, study.Contacts), tryIncludeSeq("StudyDesignDescriptors", OntologyAnnotation_encoder, study.StudyDesignDescriptors), tryIncludeSeq("Tables", (table) => encoderCompressed$1(stringTable, oaTable, cellTable, table), study.Tables), tryInclude("Datamap", (dm) => encoderCompressed$2(stringTable, oaTable, cellTable, dm), study.Datamap), tryIncludeSeq("RegisteredAssayIdentifiers", (value_9) => ({
|
|
99
99
|
Encode(helpers_5) {
|
|
100
100
|
return helpers_5.encodeString(value_9);
|
|
101
101
|
}
|
|
@@ -110,7 +110,7 @@ function encoderCompressed(stringTable, oaTable, cellTable, study) {
|
|
|
110
110
|
function decoderCompressed(stringTable, oaTable, cellTable) {
|
|
111
111
|
return object((get$) => {
|
|
112
112
|
let objectArg, objectArg_1, objectArg_2, objectArg_3, objectArg_4, arg_11, objectArg_5, arg_13, objectArg_6, arg_15, objectArg_7, arg_17, objectArg_8, arg_19, objectArg_9, arg_21, objectArg_10, arg_23, objectArg_11;
|
|
113
|
-
return new ArcStudy((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("SubmissionDate", string))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("PublicReleaseDate", string))), unwrap((arg_11 = resizeArray(decoder$1), objectArg_5 = get$.Optional, objectArg_5.Field("Publications", arg_11))), unwrap((arg_13 = resizeArray(decoder$2), objectArg_6 = get$.Optional, objectArg_6.Field("Contacts", arg_13))), unwrap((arg_15 = resizeArray(OntologyAnnotation_decoder), objectArg_7 = get$.Optional, objectArg_7.Field("StudyDesignDescriptors", arg_15))), unwrap((arg_17 = resizeArray(decoderCompressed$1(stringTable, oaTable, cellTable)), objectArg_8 = get$.Optional, objectArg_8.Field("Tables", arg_17))), unwrap((arg_19 = decoderCompressed$2(stringTable, oaTable, cellTable), objectArg_9 = get$.Optional, objectArg_9.Field("
|
|
113
|
+
return new ArcStudy((objectArg = get$.Required, objectArg.Field("Identifier", string)), unwrap((objectArg_1 = get$.Optional, objectArg_1.Field("Title", string))), unwrap((objectArg_2 = get$.Optional, objectArg_2.Field("Description", string))), unwrap((objectArg_3 = get$.Optional, objectArg_3.Field("SubmissionDate", string))), unwrap((objectArg_4 = get$.Optional, objectArg_4.Field("PublicReleaseDate", string))), unwrap((arg_11 = resizeArray(decoder$1), objectArg_5 = get$.Optional, objectArg_5.Field("Publications", arg_11))), unwrap((arg_13 = resizeArray(decoder$2), objectArg_6 = get$.Optional, objectArg_6.Field("Contacts", arg_13))), unwrap((arg_15 = resizeArray(OntologyAnnotation_decoder), objectArg_7 = get$.Optional, objectArg_7.Field("StudyDesignDescriptors", arg_15))), unwrap((arg_17 = resizeArray(decoderCompressed$1(stringTable, oaTable, cellTable)), objectArg_8 = get$.Optional, objectArg_8.Field("Tables", arg_17))), unwrap((arg_19 = decoderCompressed$2(stringTable, oaTable, cellTable), objectArg_9 = get$.Optional, objectArg_9.Field("Datamap", arg_19))), unwrap((arg_21 = resizeArray(string), objectArg_10 = get$.Optional, objectArg_10.Field("RegisteredAssayIdentifiers", arg_21))), unwrap((arg_23 = resizeArray(decoder$5), objectArg_11 = get$.Optional, objectArg_11.Field("Comments", arg_23))));
|
|
114
114
|
});
|
|
115
115
|
}
|
|
116
116
|
function ROCrate_genID(a) {
|