Exporting oracles in STON and JSON.

This commit is contained in:
Offray Vladimir Luna Cárdenas 2023-12-01 11:45:13 -05:00
parent 29a8d52f0f
commit a9d376b36c
1 changed files with 11 additions and 0 deletions

View File

@ -0,0 +1,11 @@
accessing
saveOracles
| fileName formats |
fileName := 'oracles'.
formats := {'ston' -> STON. 'json' -> STONJSON} asDictionary.
formats keysAndValuesDo: [:format :class |
MarkupFile
exportAsFileOn: (FileLocator temp / fileName), format
containing: (class toStringPretty: self oracles)
].
^ FileLocator temp