@nfdi4plants/arctrl 3.0.0-beta.7 → 3.0.0-beta.9

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 (32) hide show
  1. package/dist/ts/ts/ARC.d.ts +17 -7
  2. package/dist/ts/ts/ARC.d.ts.map +1 -1
  3. package/dist/ts/ts/ARC.js +217 -92
  4. package/dist/ts/ts/Contract/ArcWorkflow.d.ts +1 -1
  5. package/dist/ts/ts/Contract/ArcWorkflow.d.ts.map +1 -1
  6. package/dist/ts/ts/Contract/ArcWorkflow.js +4 -5
  7. package/dist/ts/ts/Contract/Datamap.d.ts.map +1 -1
  8. package/dist/ts/ts/Contract/Datamap.js +27 -8
  9. package/dist/ts/ts/Conversion.d.ts.map +1 -1
  10. package/dist/ts/ts/Conversion.js +5 -5
  11. package/dist/ts/ts/Core/ArcTypes.d.ts +57 -92
  12. package/dist/ts/ts/Core/ArcTypes.d.ts.map +1 -1
  13. package/dist/ts/ts/Core/ArcTypes.js +425 -311
  14. package/dist/ts/ts/Core/DataMap.d.ts +18 -17
  15. package/dist/ts/ts/Core/DataMap.d.ts.map +1 -1
  16. package/dist/ts/ts/Core/DataMap.js +82 -64
  17. package/dist/ts/ts/Core/IdentifierSetters.d.ts.map +1 -1
  18. package/dist/ts/ts/Core/IdentifierSetters.js +1 -2
  19. package/dist/ts/ts/Json/DataMap/DataMap.d.ts.map +1 -1
  20. package/dist/ts/ts/Json/DataMap/DataMap.js +3 -3
  21. package/dist/ts/ts/Json/Workflow.d.ts +1 -1
  22. package/dist/ts/ts/Json/Workflow.d.ts.map +1 -1
  23. package/dist/ts/ts/Json/Workflow.js +17 -17
  24. package/dist/ts/ts/Spreadsheet/ArcWorkflow.d.ts.map +1 -1
  25. package/dist/ts/ts/Spreadsheet/ArcWorkflow.js +7 -6
  26. package/dist/ts/ts/Spreadsheet/DataMap.d.ts.map +1 -1
  27. package/dist/ts/ts/Spreadsheet/DataMap.js +2 -2
  28. package/dist/ts/ts/Spreadsheet/DataMapTable/DataMapTable.d.ts.map +1 -1
  29. package/dist/ts/ts/Spreadsheet/DataMapTable/DataMapTable.js +4 -4
  30. package/dist/ts/ts/Spreadsheet/Metadata/Workflow.d.ts.map +1 -1
  31. package/dist/ts/ts/Spreadsheet/Metadata/Workflow.js +23 -13
  32. package/package.json +1 -1
package/dist/ts/ts/ARC.js CHANGED
@@ -1,25 +1,25 @@
1
1
  import { FileSystem } from './FileSystem/FileSystem.js';
2
- import { unwrap, defaultArg, value, map as map$2, bind, defaultArgWith } from '../node_modules/@fable-org/fable-library-js/Option.js';
2
+ import { unwrap, defaultArg, value, map as map$1, bind, defaultArgWith } from '../node_modules/@fable-org/fable-library-js/Option.js';
3
3
  import { License } from './License.js';
4
- import { ArcInvestigation, ArcWorkflow__get_Identifier, ArcWorkflow__get_DataMap, ArcWorkflow__set_DataMap_51F1E59E, ArcWorkflow__set_StaticHash_Z524259A4, ArcWorkflow__GetLightHashCode, ArcWorkflow__get_StaticHash, ArcWorkflow__Copy_6FCE9E49, ArcInvestigation_$reflection } from './Core/ArcTypes.js';
4
+ import { ArcInvestigation, ArcInvestigation_$reflection } from './Core/ArcTypes.js';
5
5
  import { fullFillContractBatchAsync } from './ContractIO/ContractIO.js';
6
6
  import { FSharpResult$2_Error, FSharpResult$2_Ok } from '../node_modules/@fable-org/fable-library-js/Result.js';
7
7
  import { Contract } from './Contract/Contract.js';
8
8
  import { PromiseBuilder__Run_212F1D4B, PromiseBuilder__Delay_62FBFDE1 } from './fable_modules/Fable.Promise.3.2.0/Promise.fs.js';
9
9
  import { promise } from './fable_modules/Fable.Promise.3.2.0/PromiseImpl.fs.js';
10
10
  import { getAllFilePathsAsync } from './ContractIO/FileSystemHelper.js';
11
- import { toArray, contains, delay, append, singleton, map, iterate, tryFind, find, empty, collect, toList } from '../node_modules/@fable-org/fable-library-js/Seq.js';
11
+ import { toArray, contains, delay, append, singleton, iterate, tryFind, find, empty, collect, toList } from '../node_modules/@fable-org/fable-library-js/Seq.js';
12
12
  import { defaultOf, stringHash, comparePrimitives, curry2, safeHash, getEnumerator, disposeSafe, equals } from '../node_modules/@fable-org/fable-library-js/Util.js';
13
- import { getAssayFolderPath, getStudyFolderPath } from './FileSystem/Path.js';
13
+ import { getAssayFolderPath, getRunFolderPath, getWorkflowFolderPath, getStudyFolderPath } from './FileSystem/Path.js';
14
14
  import { ARCtrl_ArcAssay__ArcAssay_ToDeleteContract, ARCtrl_ArcAssay__ArcAssay_ToCreateContract_6FCE9E49, ARCtrl_ArcAssay__ArcAssay_ToUpdateContract, ARCtrl_ArcAssay__ArcAssay_tryFromReadContract_Static_7570923F } from './Contract/ArcAssay.js';
15
+ import { ARCtrl_ArcRun__ArcRun_ToDeleteContract, ARCtrl_ArcRun__ArcRun_ToCreateContract_6FCE9E49, ARCtrl_ArcRun__ArcRun_ToUpdateContract, ARCtrl_ArcRun__ArcRun_tryFromReadContract_Static_7570923F } from './Contract/ArcRun.js';
16
+ import { ARCtrl_ArcWorkflow__ArcWorkflow_ToDeleteContract, ARCtrl_ArcWorkflow__ArcWorkflow_ToCreateContract_6FCE9E49, ARCtrl_ArcWorkflow__ArcWorkflow_ToUpdateContract, ARCtrl_ArcWorkflow__ArcWorkflow_tryFromReadContract_Static_7570923F } from './Contract/ArcWorkflow.js';
17
+ import { join, toFail, printf, replace, toText } from '../node_modules/@fable-org/fable-library-js/String.js';
18
+ import { map, choose, fold, concat, contains as contains$2, append as append$1, tryPick, equalsWith, item } from '../node_modules/@fable-org/fable-library-js/Array.js';
15
19
  import { ARCtrl_ArcInvestigation__ArcInvestigation_ToUpdateContract, ARCtrl_ArcInvestigation__ArcInvestigation_tryFromReadContract_Static_7570923F } from './Contract/ArcInvestigation.js';
16
- import { ARCtrl_ArcStudy__ArcStudy_ToUpdateContract, ARCtrl_ArcStudy__ArcStudy_ToCreateContract_6FCE9E49, ARCtrl_ArcStudy__ArcStudy_tryFromReadContract_Static_7570923F } from './Contract/ArcStudy.js';
17
- import { map as map$1, choose, fold, concat, contains as contains$2, append as append$1, tryPick, equalsWith, item } from '../node_modules/@fable-org/fable-library-js/Array.js';
18
- import { replace, join, toFail, printf, toText } from '../node_modules/@fable-org/fable-library-js/String.js';
19
20
  import { createMissingIdentifier, Study_fileNameFromIdentifier, Study_datamapFileNameFromIdentifier, Assay_fileNameFromIdentifier, Assay_datamapFileNameFromIdentifier, Workflow_fileNameFromIdentifier, Workflow_datamapFileNameFromIdentifier, Run_fileNameFromIdentifier, Run_datamapFileNameFromIdentifier } from './Core/Helper/Identifier.js';
20
21
  import { ofSeq, contains as contains$1, unionMany, FSharpSet__Contains } from '../node_modules/@fable-org/fable-library-js/Set.js';
21
22
  import { ResizeArray_iter, ResizeArray_map } from './Core/Helper/Collections.js';
22
- import { DataMap__get_DataContexts, DataMap__set_StaticHash_Z524259A4, DataMap__get_StaticHash } from './Core/DataMap.js';
23
23
  import { FileSystemTree_Folder, FileSystemTree, FileSystemTree_File } from './FileSystem/FileSystemTree.js';
24
24
  import { tryISAReadContractFromPath } from './Contract/ARC.js';
25
25
  import { setInvestigationIdentifier } from './Core/IdentifierSetters.js';
@@ -32,9 +32,8 @@ import { ARCtrl_ArcAssay__ArcAssay_toFsWorkbook_Static_Z2508BE4F } from './Sprea
32
32
  import { ARCtrl_ArcWorkflow__ArcWorkflow_toFsWorkbook_Static_Z1C75CB0E } from './Spreadsheet/ArcWorkflow.js';
33
33
  import { ARCtrl_ArcRun__ArcRun_toFsWorkbook_Static_Z3EFAF6F8 } from './Spreadsheet/ArcRun.js';
34
34
  import { Dictionary_tryGet } from './fable_modules/FsSpreadsheet.7.0.0-alpha.1/Cells/FsCellsCollection.fs.js';
35
+ import { ARCtrl_ArcStudy__ArcStudy_ToCreateContract_6FCE9E49, ARCtrl_ArcStudy__ArcStudy_ToUpdateContract, ARCtrl_ArcStudy__ArcStudy_tryFromReadContract_Static_7570923F } from './Contract/ArcStudy.js';
35
36
  import { ARCtrl_DataMap__DataMap_ToUpdateContractForStudy_Z721C83C5, ARCtrl_DataMap__DataMap_ToCreateContractForStudy_Z721C83C5, ARCtrl_DataMap__DataMap_ToUpdateContractForAssay_Z721C83C5, ARCtrl_DataMap__DataMap_ToCreateContractForAssay_Z721C83C5, ARCtrl_DataMap__DataMap_ToUpdateContractForWorkflow_Z721C83C5, ARCtrl_DataMap__DataMap_ToCreateContractForWorkflow_Z721C83C5, ARCtrl_DataMap__DataMap_ToUpdateContractForRun_Z721C83C5, ARCtrl_DataMap__DataMap_ToCreateContractForRun_Z721C83C5, ARCtrl_DataMap__DataMap_tryFromReadContractForAssay_Static, ARCtrl_DataMap__DataMap_tryFromReadContractForStudy_Static, ARCtrl_DataMap__DataMap_tryFromReadContractForWorkflow_Static, ARCtrl_DataMap__DataMap_tryFromReadContractForRun_Static } from './Contract/Datamap.js';
36
- import { ARCtrl_ArcWorkflow__ArcWorkflow_ToCreateContract_6FCE9E49, ARCtrl_ArcWorkflow__ArcWorkflow_ToUpdateContract, ARCtrl_ArcWorkflow__ArcWorkflow_tryFromReadContract_Static_7570923F } from './Contract/ArcWorkflow.js';
37
- import { ARCtrl_ArcRun__ArcRun_ToCreateContract_6FCE9E49, ARCtrl_ArcRun__ArcRun_ToUpdateContract, ARCtrl_ArcRun__ArcRun_tryFromReadContract_Static_7570923F } from './Contract/ArcRun.js';
38
37
  import { Init_createInitContract_6DFDD678, gitignoreContract, gitattributesContract, Init_createAddRemoteContract_Z721C83C5, Clone_createCloneContract_5000466F } from './Contract/Git.js';
39
38
  import { ofSeq as ofSeq$1 } from '../node_modules/@fable-org/fable-library-js/Map.js';
40
39
  import { fromString } from './fable_modules/Thoth.Json.JavaScript.0.4.1/Decode.fs.js';
@@ -46,17 +45,16 @@ import { FSharpRef } from '../node_modules/@fable-org/fable-library-js/Types.js'
46
45
  import { class_type } from '../node_modules/@fable-org/fable-library-js/Reflection.js';
47
46
 
48
47
  class ARC extends ArcInvestigation {
49
- constructor(identifier, title, description, submissionDate, publicReleaseDate, ontologySourceReferences, publications, contacts, assays, studies, workflows, runs, registeredStudyIdentifiers, comments, remarks, cwl, fs, license) {
48
+ constructor(identifier, title, description, submissionDate, publicReleaseDate, ontologySourceReferences, publications, contacts, assays, studies, workflows, runs, registeredStudyIdentifiers, comments, remarks, fs, license) {
50
49
  super(identifier, unwrap(title), unwrap(description), unwrap(submissionDate), unwrap(publicReleaseDate), unwrap(ontologySourceReferences), unwrap(publications), unwrap(contacts), unwrap(assays), unwrap(studies), unwrap(workflows), unwrap(runs), unwrap(registeredStudyIdentifiers), unwrap(comments), unwrap(remarks));
51
50
  let fs_1;
52
51
  const this$ = new FSharpRef(defaultOf());
53
52
  this$.contents = this;
54
- this._cwl = cwl;
55
53
  this._license = license;
56
54
  this._fs = (fs_1 = defaultArg(fs, FileSystem.create({
57
55
  tree: FileSystemTree_Folder("", [])
58
56
  })), ARCAux_updateFSByARC(this$.contents, license, fs_1));
59
- this["init@104"] = 1;
57
+ this["init@96"] = 1;
60
58
  }
61
59
  get FileSystem() {
62
60
  const this$ = this;
@@ -74,8 +72,8 @@ class ARC extends ArcInvestigation {
74
72
  const this$ = this;
75
73
  this$._license = license;
76
74
  }
77
- static fromArcInvestigation(isa, cwl, fs, license) {
78
- return new ARC(isa.Identifier, unwrap(isa.Title), unwrap(isa.Description), unwrap(isa.SubmissionDate), unwrap(isa.PublicReleaseDate), isa.OntologySourceReferences, isa.Publications, isa.Contacts, isa.Assays, isa.Studies, isa.Workflows, isa.Runs, isa.RegisteredStudyIdentifiers, isa.Comments, isa.Remarks, cwl, unwrap(fs), unwrap(license));
75
+ static fromArcInvestigation(isa, fs, license) {
76
+ return new ARC(isa.Identifier, unwrap(isa.Title), unwrap(isa.Description), unwrap(isa.SubmissionDate), unwrap(isa.PublicReleaseDate), isa.OntologySourceReferences, isa.Publications, isa.Contacts, isa.Assays, isa.Studies, isa.Workflows, isa.Runs, isa.RegisteredStudyIdentifiers, isa.Comments, isa.Remarks, unwrap(fs), unwrap(license));
79
77
  }
80
78
  TryWriteAsync(arcPath) {
81
79
  const this$ = this;
@@ -136,12 +134,116 @@ class ARC extends ArcInvestigation {
136
134
  const assayFolderPath = getAssayFolderPath(assayIdentifier);
137
135
  const filteredPaths = paths.filter((p) => !p.startsWith(assayFolderPath));
138
136
  this$.SetFilePaths(filteredPaths);
139
- return toArray(delay(() => append(singleton(ARCtrl_ArcAssay__ArcAssay_ToDeleteContract(assay)), delay(() => append(singleton(ARCtrl_ArcInvestigation__ArcInvestigation_ToUpdateContract(this$)), delay(() => map(ARCtrl_ArcStudy__ArcStudy_ToUpdateContract, studies)))))));
137
+ return toArray(delay(() => append(singleton(ARCtrl_ArcAssay__ArcAssay_ToDeleteContract(assay)), delay(() => this$.GetUpdateContracts()))));
138
+ }
139
+ GetRunRemoveContracts(runIdentifier) {
140
+ const this$ = this;
141
+ if (!contains(runIdentifier, this$.RunIdentifiers, {
142
+ Equals: (x, y) => x === y,
143
+ GetHashCode: stringHash
144
+ })) {
145
+ throw new Error("ARC does not contain run with given name");
146
+ }
147
+ const run = this$.GetRun(runIdentifier);
148
+ this$.DeleteRun(runIdentifier);
149
+ const paths = this$.FileSystem.Tree.ToFilePaths();
150
+ const runFolderPath = getRunFolderPath(runIdentifier);
151
+ const filteredPaths = paths.filter((p) => !p.startsWith(runFolderPath));
152
+ this$.SetFilePaths(filteredPaths);
153
+ return toArray(delay(() => append(singleton(ARCtrl_ArcRun__ArcRun_ToDeleteContract(run)), delay(() => this$.GetUpdateContracts()))));
154
+ }
155
+ GetWorkflowRemoveContracts(workflowIdentifier) {
156
+ const this$ = this;
157
+ if (!contains(workflowIdentifier, this$.WorkflowIdentifiers, {
158
+ Equals: (x, y) => x === y,
159
+ GetHashCode: stringHash
160
+ })) {
161
+ throw new Error("ARC does not contain workflow with given name");
162
+ }
163
+ const workflow = this$.GetWorkflow(workflowIdentifier);
164
+ this$.DeleteWorkflow(workflowIdentifier);
165
+ const paths = this$.FileSystem.Tree.ToFilePaths();
166
+ const workflowFolderPath = getWorkflowFolderPath(workflowIdentifier);
167
+ const filteredPaths = paths.filter((p) => !p.startsWith(workflowFolderPath));
168
+ this$.SetFilePaths(filteredPaths);
169
+ return toArray(delay(() => append(singleton(ARCtrl_ArcWorkflow__ArcWorkflow_ToDeleteContract(workflow)), delay(() => this$.GetUpdateContracts()))));
140
170
  }
141
171
  TryRemoveAssayAsync(arcPath, assayIdentifier) {
142
172
  const this$ = this;
143
173
  return fullFillContractBatchAsync(arcPath, this$.GetAssayRemoveContracts(assayIdentifier));
144
174
  }
175
+ TryRemoveRunAsync(arcPath, runIdentifier) {
176
+ const this$ = this;
177
+ return fullFillContractBatchAsync(arcPath, this$.GetRunRemoveContracts(runIdentifier));
178
+ }
179
+ TryRemoveWorkflowAsync(arcPath, workflowIdentifier) {
180
+ const this$ = this;
181
+ return fullFillContractBatchAsync(arcPath, this$.GetWorkflowRemoveContracts(workflowIdentifier));
182
+ }
183
+ RemoveRunAsync(arcPath, runIdentifier) {
184
+ const this$ = this;
185
+ return PromiseBuilder__Run_212F1D4B(promise, PromiseBuilder__Delay_62FBFDE1(promise, () => this$.TryRemoveRunAsync(arcPath, runIdentifier).then((_arg) => {
186
+ const result = _arg;
187
+ if (result.tag === /* Error */
188
+ 1) {
189
+ const appended = join("\n", map((e) => e, result.fields[0]));
190
+ toFail(printf("Could not remove run, failed with the following errors %s"))(appended);
191
+ return Promise.resolve();
192
+ } else {
193
+ return Promise.resolve();
194
+ }
195
+ })));
196
+ }
197
+ RemoveWorkflowAsync(arcPath, workflowIdentifier) {
198
+ const this$ = this;
199
+ return PromiseBuilder__Run_212F1D4B(promise, PromiseBuilder__Delay_62FBFDE1(promise, () => this$.TryRemoveWorkflowAsync(arcPath, workflowIdentifier).then((_arg) => {
200
+ const result = _arg;
201
+ if (result.tag === /* Error */
202
+ 1) {
203
+ const appended = join("\n", map((e) => e, result.fields[0]));
204
+ toFail(printf("Could not remove workflow, failed with the following errors %s"))(appended);
205
+ return Promise.resolve();
206
+ } else {
207
+ return Promise.resolve();
208
+ }
209
+ })));
210
+ }
211
+ TryRenameRunAsync(arcPath, oldRunIdentifier, newRunIdentifier) {
212
+ const this$ = this;
213
+ return fullFillContractBatchAsync(arcPath, this$.GetRunRenameContracts(oldRunIdentifier, newRunIdentifier));
214
+ }
215
+ TryRenameWorkflowAsync(arcPath, oldWorkflowIdentifier, newWorkflowIdentifier) {
216
+ const this$ = this;
217
+ return fullFillContractBatchAsync(arcPath, this$.GetWorkflowRenameContracts(oldWorkflowIdentifier, newWorkflowIdentifier));
218
+ }
219
+ RenameRunAsync(arcPath, oldRunIdentifier, newRunIdentifier) {
220
+ const this$ = this;
221
+ return PromiseBuilder__Run_212F1D4B(promise, PromiseBuilder__Delay_62FBFDE1(promise, () => this$.TryRenameRunAsync(arcPath, oldRunIdentifier, newRunIdentifier).then((_arg) => {
222
+ const result = _arg;
223
+ if (result.tag === /* Error */
224
+ 1) {
225
+ const appended = join("\n", map((e) => e, result.fields[0]));
226
+ toFail(printf("Could not rename run, failed with the following errors %s"))(appended);
227
+ return Promise.resolve();
228
+ } else {
229
+ return Promise.resolve();
230
+ }
231
+ })));
232
+ }
233
+ RenameWorkflowAsync(arcPath, oldWorkflowIdentifier, newWorkflowIdentifier) {
234
+ const this$ = this;
235
+ return PromiseBuilder__Run_212F1D4B(promise, PromiseBuilder__Delay_62FBFDE1(promise, () => this$.TryRenameWorkflowAsync(arcPath, oldWorkflowIdentifier, newWorkflowIdentifier).then((_arg) => {
236
+ const result = _arg;
237
+ if (result.tag === /* Error */
238
+ 1) {
239
+ const appended = join("\n", map((e) => e, result.fields[0]));
240
+ toFail(printf("Could not rename workflow, failed with the following errors %s"))(appended);
241
+ return Promise.resolve();
242
+ } else {
243
+ return Promise.resolve();
244
+ }
245
+ })));
246
+ }
145
247
  GetAssayRenameContracts(oldAssayIdentifier, newAssayIdentifier) {
146
248
  const this$ = this;
147
249
  if (!contains(oldAssayIdentifier, this$.AssayIdentifiers, {
@@ -154,10 +256,42 @@ class ARC extends ArcInvestigation {
154
256
  const paths = this$.FileSystem.Tree.ToFilePaths();
155
257
  const oldAssayFolderPath = getAssayFolderPath(oldAssayIdentifier);
156
258
  const newAssayFolderPath = getAssayFolderPath(newAssayIdentifier);
157
- const renamedPaths = map$1((p) => replace(p, oldAssayFolderPath, newAssayFolderPath), paths);
259
+ const renamedPaths = map((p) => replace(p, oldAssayFolderPath, newAssayFolderPath), paths);
158
260
  this$.SetFilePaths(renamedPaths);
159
261
  return toArray(delay(() => append(singleton(Contract.createRename(oldAssayFolderPath, newAssayFolderPath)), delay(() => this$.GetUpdateContracts()))));
160
262
  }
263
+ GetRunRenameContracts(oldRunIdentifier, newRunIdentifier) {
264
+ const this$ = this;
265
+ if (!contains(oldRunIdentifier, this$.RunIdentifiers, {
266
+ Equals: (x, y) => x === y,
267
+ GetHashCode: stringHash
268
+ })) {
269
+ throw new Error("ARC does not contain run with given name");
270
+ }
271
+ super.RenameRun(oldRunIdentifier, newRunIdentifier);
272
+ const paths = this$.FileSystem.Tree.ToFilePaths();
273
+ const oldPath = getRunFolderPath(oldRunIdentifier);
274
+ const newPath = getRunFolderPath(newRunIdentifier);
275
+ const renamedPaths = map((p) => replace(p, oldPath, newPath), paths);
276
+ this$.SetFilePaths(renamedPaths);
277
+ return toArray(delay(() => append(singleton(Contract.createRename(oldPath, newPath)), delay(() => this$.GetUpdateContracts()))));
278
+ }
279
+ GetWorkflowRenameContracts(oldWorkflowIdentifier, newWorkflowIdentifier) {
280
+ const this$ = this;
281
+ if (!contains(oldWorkflowIdentifier, this$.WorkflowIdentifiers, {
282
+ Equals: (x, y) => x === y,
283
+ GetHashCode: stringHash
284
+ })) {
285
+ throw new Error("ARC does not contain workflow with given name");
286
+ }
287
+ super.RenameWorkflow(oldWorkflowIdentifier, newWorkflowIdentifier);
288
+ const paths = this$.FileSystem.Tree.ToFilePaths();
289
+ const oldPath = getWorkflowFolderPath(oldWorkflowIdentifier);
290
+ const newPath = getWorkflowFolderPath(newWorkflowIdentifier);
291
+ const renamedPaths = map((p) => replace(p, oldPath, newPath), paths);
292
+ this$.SetFilePaths(renamedPaths);
293
+ return toArray(delay(() => append(singleton(Contract.createRename(oldPath, newPath)), delay(() => this$.GetUpdateContracts()))));
294
+ }
161
295
  TryRenameAssayAsync(arcPath, oldAssayIdentifier, newAssayIdentifier) {
162
296
  const this$ = this;
163
297
  return fullFillContractBatchAsync(arcPath, this$.GetAssayRenameContracts(oldAssayIdentifier, newAssayIdentifier));
@@ -187,7 +321,7 @@ class ARC extends ArcInvestigation {
187
321
  const paths = this$.FileSystem.Tree.ToFilePaths();
188
322
  const oldStudyFolderPath = getStudyFolderPath(oldStudyIdentifier);
189
323
  const newStudyFolderPath = getStudyFolderPath(newStudyIdentifier);
190
- const renamedPaths = map$1((p) => replace(p, oldStudyFolderPath, newStudyFolderPath), paths);
324
+ const renamedPaths = map((p) => replace(p, oldStudyFolderPath, newStudyFolderPath), paths);
191
325
  this$.SetFilePaths(renamedPaths);
192
326
  return toArray(delay(() => append(singleton(Contract.createRename(oldStudyFolderPath, newStudyFolderPath)), delay(() => this$.GetUpdateContracts()))));
193
327
  }
@@ -201,7 +335,7 @@ class ARC extends ArcInvestigation {
201
335
  const result = _arg;
202
336
  if (result.tag === /* Error */
203
337
  1) {
204
- const appended = join("\n", map$1((e) => e, result.fields[0]));
338
+ const appended = join("\n", map((e) => e, result.fields[0]));
205
339
  toFail(printf("Could not write ARC, failed with the following errors %s"))(appended);
206
340
  return Promise.resolve();
207
341
  } else {
@@ -215,7 +349,7 @@ class ARC extends ArcInvestigation {
215
349
  const result = _arg;
216
350
  if (result.tag === /* Error */
217
351
  1) {
218
- const appended = join("\n", map$1((e) => e, result.fields[0]));
352
+ const appended = join("\n", map((e) => e, result.fields[0]));
219
353
  toFail(printf("Could not update ARC, failed with the following errors %s"))(appended);
220
354
  return Promise.resolve();
221
355
  } else {
@@ -229,7 +363,7 @@ class ARC extends ArcInvestigation {
229
363
  const result = _arg;
230
364
  if (result.tag === /* Error */
231
365
  1) {
232
- const appended = join("\n", map$1((e) => e, result.fields[0]));
366
+ const appended = join("\n", map((e) => e, result.fields[0]));
233
367
  toFail(printf("Could not remove assay, failed with the following errors %s"))(appended);
234
368
  return Promise.resolve();
235
369
  } else {
@@ -243,7 +377,7 @@ class ARC extends ArcInvestigation {
243
377
  const result = _arg;
244
378
  if (result.tag === /* Error */
245
379
  1) {
246
- const appended = join("\n", map$1((e) => e, result.fields[0]));
380
+ const appended = join("\n", map((e) => e, result.fields[0]));
247
381
  toFail(printf("Could not rename assay, failed with the following errors %s"))(appended);
248
382
  return Promise.resolve();
249
383
  } else {
@@ -257,7 +391,7 @@ class ARC extends ArcInvestigation {
257
391
  const result = _arg;
258
392
  if (result.tag === /* Error */
259
393
  1) {
260
- const appended = join("\n", map$1((e) => e, result.fields[0]));
394
+ const appended = join("\n", map((e) => e, result.fields[0]));
261
395
  toFail(printf("Could not remove study, failed with the following errors %s"))(appended);
262
396
  return Promise.resolve();
263
397
  } else {
@@ -271,7 +405,7 @@ class ARC extends ArcInvestigation {
271
405
  const result = _arg;
272
406
  if (result.tag === /* Error */
273
407
  1) {
274
- const appended = join("\n", map$1((e) => e, result.fields[0]));
408
+ const appended = join("\n", map((e) => e, result.fields[0]));
275
409
  toFail(printf("Could not rename study, failed with the following errors %s"))(appended);
276
410
  return Promise.resolve();
277
411
  } else {
@@ -284,7 +418,7 @@ class ARC extends ArcInvestigation {
284
418
  const result = _arg;
285
419
  if (result.tag === /* Error */
286
420
  1) {
287
- const appended = join("\n", map$1((e) => e, result.fields[0]));
421
+ const appended = join("\n", map((e) => e, result.fields[0]));
288
422
  toFail(printf("Could not load ARC, failed with the following errors %s"))(appended);
289
423
  return Promise.resolve(new ARC(createMissingIdentifier()));
290
424
  } else {
@@ -337,7 +471,7 @@ class ARC extends ArcInvestigation {
337
471
  const newFilePath_1 = dataNameFunction_2(c_1);
338
472
  c_1.FilePath = newFilePath_1;
339
473
  }
340
- }, DataMap__get_DataContexts(dm));
474
+ }, dm.DataContexts);
341
475
  };
342
476
  iterate((s) => {
343
477
  const f_1 = (d) => d.GetAbsolutePathForStudy(s.Identifier, checkExistenceFromRoot);
@@ -358,7 +492,7 @@ class ARC extends ArcInvestigation {
358
492
  }
359
493
  static fromFilePaths(filePaths) {
360
494
  const fs = FileSystem.fromFilePaths(filePaths);
361
- return new ARC(createMissingIdentifier(), void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, fs);
495
+ return new ARC(createMissingIdentifier(), void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, void 0, fs);
362
496
  }
363
497
  SetFilePaths(filePaths) {
364
498
  const this$ = this;
@@ -383,7 +517,7 @@ class ARC extends ArcInvestigation {
383
517
  this$.Comments = investigation.Comments;
384
518
  this$.Remarks = investigation.Remarks;
385
519
  this$.RegisteredStudyIdentifiers = investigation.RegisteredStudyIdentifiers;
386
- const studies = map$1((tuple) => tuple[0], ARCAux_getArcStudiesFromContracts(contracts));
520
+ const studies = map((tuple) => tuple[0], ARCAux_getArcStudiesFromContracts(contracts));
387
521
  const assays = ARCAux_getArcAssaysFromContracts(contracts);
388
522
  const workflows = ARCAux_getArcWorkflowsFromContracts(contracts);
389
523
  const runs = ARCAux_getArcRunsFromContracts(contracts);
@@ -433,12 +567,12 @@ class ARC extends ArcInvestigation {
433
567
  assay_1.Tables = updatedTables.Tables;
434
568
  });
435
569
  workflows.forEach((workflow) => {
436
- const datamap_2 = ARCAux_getWorkflowDataMapFromContracts(ArcWorkflow__get_Identifier(workflow), contracts);
437
- if (ArcWorkflow__get_DataMap(workflow) == null) {
438
- ArcWorkflow__set_DataMap_51F1E59E(workflow, datamap_2);
570
+ const datamap_2 = ARCAux_getWorkflowDataMapFromContracts(workflow.Identifier, contracts);
571
+ if (workflow.DataMap == null) {
572
+ workflow.DataMap = datamap_2;
439
573
  }
440
574
  this$.AddWorkflow(workflow);
441
- ArcWorkflow__set_StaticHash_Z524259A4(workflow, ArcWorkflow__GetLightHashCode(workflow));
575
+ workflow.StaticHash = workflow.GetLightHashCode() | 0;
442
576
  });
443
577
  runs.forEach((run) => {
444
578
  const datamap_3 = ARCAux_getRunDataMapFromContracts(run.Identifier, contracts);
@@ -475,7 +609,7 @@ class ARC extends ArcInvestigation {
475
609
  addToDict(filemap, Study_fileNameFromIdentifier(s.Identifier), ["ISA_Study", ARCtrl_ArcStudy__ArcStudy_toFsWorkbook_Static_Z4CEFA522(s)]);
476
610
  if (s.DataMap != null) {
477
611
  const dm = value(s.DataMap);
478
- DataMap__set_StaticHash_Z524259A4(dm, safeHash(dm));
612
+ dm.StaticHash = safeHash(dm) | 0;
479
613
  addToDict(filemap, Study_datamapFileNameFromIdentifier(s.Identifier), ["ISA_Datamap", toFsWorkbook(dm)]);
480
614
  }
481
615
  }, this$.Studies);
@@ -484,17 +618,17 @@ class ARC extends ArcInvestigation {
484
618
  addToDict(filemap, Assay_fileNameFromIdentifier(a.Identifier), ["ISA_Assay", ARCtrl_ArcAssay__ArcAssay_toFsWorkbook_Static_Z2508BE4F(a)]);
485
619
  if (a.DataMap != null) {
486
620
  const dm_1 = value(a.DataMap);
487
- DataMap__set_StaticHash_Z524259A4(dm_1, safeHash(dm_1));
621
+ dm_1.StaticHash = safeHash(dm_1) | 0;
488
622
  addToDict(filemap, Assay_datamapFileNameFromIdentifier(a.Identifier), ["ISA_Datamap", toFsWorkbook(dm_1)]);
489
623
  }
490
624
  }, this$.Assays);
491
625
  iterate((w) => {
492
- ArcWorkflow__set_StaticHash_Z524259A4(w, ArcWorkflow__GetLightHashCode(w));
493
- addToDict(filemap, Workflow_fileNameFromIdentifier(ArcWorkflow__get_Identifier(w)), ["ISA_Workflow", ARCtrl_ArcWorkflow__ArcWorkflow_toFsWorkbook_Static_Z1C75CB0E(w)]);
494
- if (ArcWorkflow__get_DataMap(w) != null) {
495
- const dm_2 = value(ArcWorkflow__get_DataMap(w));
496
- DataMap__set_StaticHash_Z524259A4(dm_2, safeHash(dm_2));
497
- addToDict(filemap, Workflow_datamapFileNameFromIdentifier(ArcWorkflow__get_Identifier(w)), ["ISA_Datamap", toFsWorkbook(dm_2)]);
626
+ w.StaticHash = w.GetLightHashCode() | 0;
627
+ addToDict(filemap, Workflow_fileNameFromIdentifier(w.Identifier), ["ISA_Workflow", ARCtrl_ArcWorkflow__ArcWorkflow_toFsWorkbook_Static_Z1C75CB0E(w)]);
628
+ if (w.DataMap != null) {
629
+ const dm_2 = value(w.DataMap);
630
+ dm_2.StaticHash = safeHash(dm_2) | 0;
631
+ addToDict(filemap, Workflow_datamapFileNameFromIdentifier(w.Identifier), ["ISA_Datamap", toFsWorkbook(dm_2)]);
498
632
  }
499
633
  }, this$.Workflows);
500
634
  iterate((r) => {
@@ -502,7 +636,7 @@ class ARC extends ArcInvestigation {
502
636
  addToDict(filemap, Run_fileNameFromIdentifier(r.Identifier), ["ISA_Run", ARCtrl_ArcRun__ArcRun_toFsWorkbook_Static_Z3EFAF6F8(r)]);
503
637
  if (r.DataMap != null) {
504
638
  const dm_3 = value(r.DataMap);
505
- DataMap__set_StaticHash_Z524259A4(dm_3, safeHash(dm_3));
639
+ dm_3.StaticHash = safeHash(dm_3) | 0;
506
640
  addToDict(filemap, Run_datamapFileNameFromIdentifier(r.Identifier), ["ISA_Datamap", toFsWorkbook(dm_3)]);
507
641
  }
508
642
  }, this$.Runs);
@@ -514,7 +648,7 @@ class ARC extends ArcInvestigation {
514
648
  l.StaticHash = safeHash(l) | 0;
515
649
  addToDict(filemap, l.Path, ["PlainText", l.Content]);
516
650
  }
517
- return map$1((fp) => {
651
+ return map((fp) => {
518
652
  const matchValue_2 = Dictionary_tryGet(fp, filemap);
519
653
  if (matchValue_2 == null) {
520
654
  return Contract.createCreate(fp, "PlainText");
@@ -538,15 +672,15 @@ class ARC extends ArcInvestigation {
538
672
  return append(collect((s) => {
539
673
  const hash_1 = s.GetLightHashCode() | 0;
540
674
  return append(s.StaticHash === 0 ? ARCtrl_ArcStudy__ArcStudy_ToCreateContract_6FCE9E49(s, true) : s.StaticHash !== hash_1 ? singleton(ARCtrl_ArcStudy__ArcStudy_ToUpdateContract(s)) : empty(), delay(() => {
541
- let dm_1;
675
+ let dm, dm_1;
542
676
  s.StaticHash = hash_1 | 0;
543
677
  const matchValue = s.DataMap;
544
678
  let matchResult, dm_2, dm_3;
545
679
  if (matchValue != null) {
546
- if (DataMap__get_StaticHash(value(matchValue)) === 0) {
680
+ if (dm = value(matchValue), dm.StaticHash === 0) {
547
681
  matchResult = 0;
548
682
  dm_2 = value(matchValue);
549
- } else if (dm_1 = value(matchValue), DataMap__get_StaticHash(dm_1) !== safeHash(dm_1)) {
683
+ } else if (dm_1 = value(matchValue), dm_1.StaticHash !== safeHash(dm_1)) {
550
684
  matchResult = 1;
551
685
  dm_3 = value(matchValue);
552
686
  } else {
@@ -558,12 +692,12 @@ class ARC extends ArcInvestigation {
558
692
  switch (matchResult) {
559
693
  case 0:
560
694
  return append(singleton(ARCtrl_DataMap__DataMap_ToCreateContractForStudy_Z721C83C5(dm_2, s.Identifier)), delay(() => {
561
- DataMap__set_StaticHash_Z524259A4(dm_2, safeHash(dm_2));
695
+ dm_2.StaticHash = safeHash(dm_2) | 0;
562
696
  return empty();
563
697
  }));
564
698
  case 1:
565
699
  return append(singleton(ARCtrl_DataMap__DataMap_ToUpdateContractForStudy_Z721C83C5(dm_3, s.Identifier)), delay(() => {
566
- DataMap__set_StaticHash_Z524259A4(dm_3, safeHash(dm_3));
700
+ dm_3.StaticHash = safeHash(dm_3) | 0;
567
701
  return empty();
568
702
  }));
569
703
  default: {
@@ -574,15 +708,15 @@ class ARC extends ArcInvestigation {
574
708
  }, this$.Studies), delay(() => append(collect((a) => {
575
709
  const hash_2 = a.GetLightHashCode() | 0;
576
710
  return append(a.StaticHash === 0 ? ARCtrl_ArcAssay__ArcAssay_ToCreateContract_6FCE9E49(a, true) : a.StaticHash !== hash_2 ? singleton(ARCtrl_ArcAssay__ArcAssay_ToUpdateContract(a)) : empty(), delay(() => {
577
- let dm_5;
711
+ let dm_4, dm_5;
578
712
  a.StaticHash = hash_2 | 0;
579
713
  const matchValue_1 = a.DataMap;
580
714
  let matchResult_1, dm_6, dm_7;
581
715
  if (matchValue_1 != null) {
582
- if (DataMap__get_StaticHash(value(matchValue_1)) === 0) {
716
+ if (dm_4 = value(matchValue_1), dm_4.StaticHash === 0) {
583
717
  matchResult_1 = 0;
584
718
  dm_6 = value(matchValue_1);
585
- } else if (dm_5 = value(matchValue_1), DataMap__get_StaticHash(dm_5) !== safeHash(dm_5)) {
719
+ } else if (dm_5 = value(matchValue_1), dm_5.StaticHash !== safeHash(dm_5)) {
586
720
  matchResult_1 = 1;
587
721
  dm_7 = value(matchValue_1);
588
722
  } else {
@@ -594,12 +728,12 @@ class ARC extends ArcInvestigation {
594
728
  switch (matchResult_1) {
595
729
  case 0:
596
730
  return append(singleton(ARCtrl_DataMap__DataMap_ToCreateContractForAssay_Z721C83C5(dm_6, a.Identifier)), delay(() => {
597
- DataMap__set_StaticHash_Z524259A4(dm_6, safeHash(dm_6));
731
+ dm_6.StaticHash = safeHash(dm_6) | 0;
598
732
  return empty();
599
733
  }));
600
734
  case 1:
601
735
  return append(singleton(ARCtrl_DataMap__DataMap_ToUpdateContractForAssay_Z721C83C5(dm_7, a.Identifier)), delay(() => {
602
- DataMap__set_StaticHash_Z524259A4(dm_7, safeHash(dm_7));
736
+ dm_7.StaticHash = safeHash(dm_7) | 0;
603
737
  return empty();
604
738
  }));
605
739
  default: {
@@ -608,17 +742,17 @@ class ARC extends ArcInvestigation {
608
742
  }
609
743
  }));
610
744
  }, this$.Assays), delay(() => append(collect((w) => {
611
- const hash_3 = ArcWorkflow__GetLightHashCode(w) | 0;
612
- return append(ArcWorkflow__get_StaticHash(w) === 0 ? ARCtrl_ArcWorkflow__ArcWorkflow_ToCreateContract_6FCE9E49(w, true) : ArcWorkflow__get_StaticHash(w) !== hash_3 ? singleton(ARCtrl_ArcWorkflow__ArcWorkflow_ToUpdateContract(w)) : empty(), delay(() => {
613
- let dm_9;
614
- ArcWorkflow__set_StaticHash_Z524259A4(w, hash_3);
615
- const matchValue_2 = ArcWorkflow__get_DataMap(w);
745
+ const hash_3 = w.GetLightHashCode() | 0;
746
+ return append(w.StaticHash === 0 ? ARCtrl_ArcWorkflow__ArcWorkflow_ToCreateContract_6FCE9E49(w, true) : w.StaticHash !== hash_3 ? singleton(ARCtrl_ArcWorkflow__ArcWorkflow_ToUpdateContract(w)) : empty(), delay(() => {
747
+ let dm_8, dm_9;
748
+ w.StaticHash = hash_3 | 0;
749
+ const matchValue_2 = w.DataMap;
616
750
  let matchResult_2, dm_10, dm_11;
617
751
  if (matchValue_2 != null) {
618
- if (DataMap__get_StaticHash(value(matchValue_2)) === 0) {
752
+ if (dm_8 = value(matchValue_2), dm_8.StaticHash === 0) {
619
753
  matchResult_2 = 0;
620
754
  dm_10 = value(matchValue_2);
621
- } else if (dm_9 = value(matchValue_2), DataMap__get_StaticHash(dm_9) !== safeHash(dm_9)) {
755
+ } else if (dm_9 = value(matchValue_2), dm_9.StaticHash !== safeHash(dm_9)) {
622
756
  matchResult_2 = 1;
623
757
  dm_11 = value(matchValue_2);
624
758
  } else {
@@ -629,13 +763,13 @@ class ARC extends ArcInvestigation {
629
763
  }
630
764
  switch (matchResult_2) {
631
765
  case 0:
632
- return append(singleton(ARCtrl_DataMap__DataMap_ToCreateContractForWorkflow_Z721C83C5(dm_10, ArcWorkflow__get_Identifier(w))), delay(() => {
633
- DataMap__set_StaticHash_Z524259A4(dm_10, safeHash(dm_10));
766
+ return append(singleton(ARCtrl_DataMap__DataMap_ToCreateContractForWorkflow_Z721C83C5(dm_10, w.Identifier)), delay(() => {
767
+ dm_10.StaticHash = safeHash(dm_10) | 0;
634
768
  return empty();
635
769
  }));
636
770
  case 1:
637
- return append(singleton(ARCtrl_DataMap__DataMap_ToUpdateContractForWorkflow_Z721C83C5(dm_11, ArcWorkflow__get_Identifier(w))), delay(() => {
638
- DataMap__set_StaticHash_Z524259A4(dm_11, safeHash(dm_11));
771
+ return append(singleton(ARCtrl_DataMap__DataMap_ToUpdateContractForWorkflow_Z721C83C5(dm_11, w.Identifier)), delay(() => {
772
+ dm_11.StaticHash = safeHash(dm_11) | 0;
639
773
  return empty();
640
774
  }));
641
775
  default: {
@@ -646,15 +780,15 @@ class ARC extends ArcInvestigation {
646
780
  }, this$.Workflows), delay(() => append(collect((r) => {
647
781
  const hash_4 = r.GetLightHashCode() | 0;
648
782
  return append(r.StaticHash === 0 ? ARCtrl_ArcRun__ArcRun_ToCreateContract_6FCE9E49(r, true) : r.StaticHash !== hash_4 ? singleton(ARCtrl_ArcRun__ArcRun_ToUpdateContract(r)) : empty(), delay(() => {
649
- let dm_13;
783
+ let dm_12, dm_13;
650
784
  r.StaticHash = hash_4 | 0;
651
785
  const matchValue_3 = r.DataMap;
652
786
  let matchResult_3, dm_14, dm_15;
653
787
  if (matchValue_3 != null) {
654
- if (DataMap__get_StaticHash(value(matchValue_3)) === 0) {
788
+ if (dm_12 = value(matchValue_3), dm_12.StaticHash === 0) {
655
789
  matchResult_3 = 0;
656
790
  dm_14 = value(matchValue_3);
657
- } else if (dm_13 = value(matchValue_3), DataMap__get_StaticHash(dm_13) !== safeHash(dm_13)) {
791
+ } else if (dm_13 = value(matchValue_3), dm_13.StaticHash !== safeHash(dm_13)) {
658
792
  matchResult_3 = 1;
659
793
  dm_15 = value(matchValue_3);
660
794
  } else {
@@ -666,12 +800,12 @@ class ARC extends ArcInvestigation {
666
800
  switch (matchResult_3) {
667
801
  case 0:
668
802
  return append(singleton(ARCtrl_DataMap__DataMap_ToCreateContractForRun_Z721C83C5(dm_14, r.Identifier)), delay(() => {
669
- DataMap__set_StaticHash_Z524259A4(dm_14, safeHash(dm_14));
803
+ dm_14.StaticHash = safeHash(dm_14) | 0;
670
804
  return empty();
671
805
  }));
672
806
  case 1:
673
807
  return append(singleton(ARCtrl_DataMap__DataMap_ToUpdateContractForRun_Z721C83C5(dm_15, r.Identifier)), delay(() => {
674
- DataMap__set_StaticHash_Z524259A4(dm_15, safeHash(dm_15));
808
+ dm_15.StaticHash = safeHash(dm_15) | 0;
675
809
  return empty();
676
810
  }));
677
811
  default: {
@@ -734,7 +868,8 @@ class ARC extends ArcInvestigation {
734
868
  try {
735
869
  while (enumerator_2["System.Collections.IEnumerator.MoveNext"]()) {
736
870
  const workflow = enumerator_2["System.Collections.Generic.IEnumerator`1.get_Current"]();
737
- void nextWorkflows.push(ArcWorkflow__Copy_6FCE9E49(workflow));
871
+ const copy_2 = workflow.Copy();
872
+ void nextWorkflows.push(copy_2);
738
873
  }
739
874
  } finally {
740
875
  disposeSafe(enumerator_2);
@@ -755,19 +890,19 @@ class ARC extends ArcInvestigation {
755
890
  const nextPublications = ResizeArray_map((c_3) => c_3.Copy(), this$.Publications);
756
891
  const nextOntologySourceReferences = ResizeArray_map((c_4) => c_4.Copy(), this$.OntologySourceReferences);
757
892
  const nextStudyIdentifiers = Array.from(this$.RegisteredStudyIdentifiers);
758
- const nextLicense = map$2((_arg) => _arg.Copy(), this$.License);
893
+ const nextLicense = map$1((_arg) => _arg.Copy(), this$.License);
759
894
  const fsCopy = this$._fs.Copy();
760
- return new ARC(this$.Identifier, unwrap(this$.Title), unwrap(this$.Description), unwrap(this$.SubmissionDate), unwrap(this$.PublicReleaseDate), nextOntologySourceReferences, nextPublications, nextContacts, nextAssays, nextStudies, nextWorkflows, nextRuns, nextStudyIdentifiers, nextComments, nextRemarks, this$._cwl, fsCopy, unwrap(nextLicense));
895
+ return new ARC(this$.Identifier, unwrap(this$.Title), unwrap(this$.Description), unwrap(this$.SubmissionDate), unwrap(this$.PublicReleaseDate), nextOntologySourceReferences, nextPublications, nextContacts, nextAssays, nextStudies, nextWorkflows, nextRuns, nextStudyIdentifiers, nextComments, nextRemarks, fsCopy, unwrap(nextLicense));
761
896
  }
762
897
  GetRegisteredPayload(IgnoreHidden) {
763
898
  let tree, paths, array_3;
764
899
  const this$ = this;
765
900
  const copy = this$.Copy();
766
901
  const registeredStudies = copy.Studies.slice();
767
- const registeredAssays = concat(map$1((s) => s.RegisteredAssays.slice(), registeredStudies));
902
+ const registeredAssays = concat(map((s) => s.RegisteredAssays.slice(), registeredStudies));
768
903
  const includeFiles = unionMany([ofSeq(toList(delay(() => append(singleton("isa.investigation.xlsx"), delay(() => append(singleton("README.md"), delay(() => this$.License != null ? singleton(value(this$.License).Path) : empty())))))), {
769
904
  Compare: comparePrimitives
770
- }), unionMany(map$1((s_1) => {
905
+ }), unionMany(map((s_1) => {
771
906
  const studyFoldername = `${"studies"}/${s_1.Identifier}`;
772
907
  return ofSeq(toList(delay(() => append(singleton(`${studyFoldername}/${"isa.study.xlsx"}`), delay(() => append(singleton(`${studyFoldername}/${"README.md"}`), delay(() => collect((table) => collect((kv) => {
773
908
  const textValue = kv[1].ToFreeTextCell().AsFreeText;
@@ -777,7 +912,7 @@ class ARC extends ArcInvestigation {
777
912
  });
778
913
  }, registeredStudies), {
779
914
  Compare: comparePrimitives
780
- }), unionMany(map$1((a) => {
915
+ }), unionMany(map((a) => {
781
916
  const assayFoldername = `${"assays"}/${a.Identifier}`;
782
917
  return ofSeq(toList(delay(() => append(singleton(`${assayFoldername}/${"isa.assay.xlsx"}`), delay(() => append(singleton(`${assayFoldername}/${"README.md"}`), delay(() => collect((table_1) => collect((kv_1) => {
783
918
  const textValue_1 = kv_1[1].ToFreeTextCell().AsFreeText;
@@ -858,7 +993,7 @@ class ARC extends ArcInvestigation {
858
993
  let fileSystem;
859
994
  const paths = Array.from(patternInput[1]);
860
995
  fileSystem = FileSystem.fromFilePaths(paths);
861
- return ARC.fromArcInvestigation(patternInput[0], void 0, fileSystem, unwrap(patternInput[2]));
996
+ return ARC.fromArcInvestigation(patternInput[0], fileSystem, unwrap(patternInput[2]));
862
997
  } catch (ex) {
863
998
  const arg_1 = ex.message;
864
999
  return toFail(printf("Could not parse ARC-RO-Crate metadata: \n%s"))(arg_1);
@@ -919,8 +1054,8 @@ class ARC extends ArcInvestigation {
919
1054
  function ARC_$reflection() {
920
1055
  return class_type("ARCtrl.ARC", void 0, ARC, ArcInvestigation_$reflection());
921
1056
  }
922
- function ARC_$ctor_Z4D7EB22(identifier, title, description, submissionDate, publicReleaseDate, ontologySourceReferences, publications, contacts, assays, studies, workflows, runs, registeredStudyIdentifiers, comments, remarks, cwl, fs, license) {
923
- return new ARC(identifier, title, description, submissionDate, publicReleaseDate, ontologySourceReferences, publications, contacts, assays, studies, workflows, runs, registeredStudyIdentifiers, comments, remarks, cwl, fs, license);
1057
+ function ARC_$ctor_Z443FB9BF(identifier, title, description, submissionDate, publicReleaseDate, ontologySourceReferences, publications, contacts, assays, studies, workflows, runs, registeredStudyIdentifiers, comments, remarks, fs, license) {
1058
+ return new ARC(identifier, title, description, submissionDate, publicReleaseDate, ontologySourceReferences, publications, contacts, assays, studies, workflows, runs, registeredStudyIdentifiers, comments, remarks, fs, license);
924
1059
  }
925
1060
  function ARCAux_getArcAssaysFromContracts(contracts) {
926
1061
  return choose(ARCtrl_ArcAssay__ArcAssay_tryFromReadContract_Static_7570923F, contracts);
@@ -960,16 +1095,16 @@ function ARCAux_getLicenseFromContracts(contracts) {
960
1095
  }
961
1096
  function ARCAux_updateFSByARC(isa, license, fs) {
962
1097
  let assaysFolder;
963
- const assays = map$1((a) => FileSystemTree.createAssayFolder(a.Identifier, a.DataMap != null), toArray(isa.Assays));
1098
+ const assays = map((a) => FileSystemTree.createAssayFolder(a.Identifier, a.DataMap != null), toArray(isa.Assays));
964
1099
  assaysFolder = FileSystemTree.createAssaysFolder(assays);
965
1100
  let studiesFolder;
966
- const studies = map$1((s) => FileSystemTree.createStudyFolder(s.Identifier, s.DataMap != null), toArray(isa.Studies));
1101
+ const studies = map((s) => FileSystemTree.createStudyFolder(s.Identifier, s.DataMap != null), toArray(isa.Studies));
967
1102
  studiesFolder = FileSystemTree.createStudiesFolder(studies);
968
1103
  let workflowsFolder;
969
- const workflows = map$1((w) => FileSystemTree.createWorkflowFolder(ArcWorkflow__get_Identifier(w), ArcWorkflow__get_DataMap(w) != null), toArray(isa.Workflows));
1104
+ const workflows = map((w) => FileSystemTree.createWorkflowFolder(w.Identifier, w.DataMap != null), toArray(isa.Workflows));
970
1105
  workflowsFolder = FileSystemTree.createWorkflowsFolder(workflows);
971
1106
  let runsFolder;
972
- const runs = map$1((r) => FileSystemTree.createRunFolder(r.Identifier, r.DataMap != null), toArray(isa.Runs));
1107
+ const runs = map((r) => FileSystemTree.createRunFolder(r.Identifier, r.DataMap != null), toArray(isa.Runs));
973
1108
  runsFolder = FileSystemTree.createRunsFolder(runs);
974
1109
  const investigation = FileSystemTree.createInvestigationFile();
975
1110
  let tree_1;
@@ -979,15 +1114,5 @@ function ARCAux_updateFSByARC(isa, license, fs) {
979
1114
  });
980
1115
  return fs.Union(tree_1);
981
1116
  }
982
- function ARCAux_updateFSByCWL(cwl, fs) {
983
- const workflows = FileSystemTree.createWorkflowsFolder([]);
984
- const runs = FileSystemTree.createRunsFolder([]);
985
- let tree_1;
986
- const tree = FileSystemTree.createRootFolder([workflows, runs]);
987
- tree_1 = FileSystem.create({
988
- tree
989
- });
990
- return fs.Union(tree_1);
991
- }
992
1117
 
993
- export { ARC, ARCAux_getArcAssaysFromContracts, ARCAux_getArcInvestigationFromContracts, ARCAux_getArcRunsFromContracts, ARCAux_getArcStudiesFromContracts, ARCAux_getArcWorkflowsFromContracts, ARCAux_getAssayDataMapFromContracts, ARCAux_getLicenseFromContracts, ARCAux_getRunDataMapFromContracts, ARCAux_getStudyDataMapFromContracts, ARCAux_getWorkflowDataMapFromContracts, ARCAux_updateFSByARC, ARCAux_updateFSByCWL, ARC_$ctor_Z4D7EB22, ARC_$reflection };
1118
+ export { ARC, ARCAux_getArcAssaysFromContracts, ARCAux_getArcInvestigationFromContracts, ARCAux_getArcRunsFromContracts, ARCAux_getArcStudiesFromContracts, ARCAux_getArcWorkflowsFromContracts, ARCAux_getAssayDataMapFromContracts, ARCAux_getLicenseFromContracts, ARCAux_getRunDataMapFromContracts, ARCAux_getStudyDataMapFromContracts, ARCAux_getWorkflowDataMapFromContracts, ARCAux_updateFSByARC, ARC_$ctor_Z443FB9BF, ARC_$reflection };