occam-verify-cli 1.0.983 → 1.0.985
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/lib/action/verify.js +22 -27
- package/lib/constants.js +1 -41
- package/lib/index.js +1 -2
- package/lib/utilities/fileContext.js +3 -8
- package/lib/utilities/releaseContext.js +2 -2
- package/package.json +10 -11
- package/src/action/verify.js +8 -18
- package/src/constants.js +0 -10
- package/src/index.js +0 -2
- package/src/utilities/fileContext.js +1 -2
- package/src/utilities/releaseContext.js +1 -1
- package/lib/context/aphasic.js +0 -27
- package/lib/context/bounded.js +0 -244
- package/lib/context/branching.js +0 -61
- package/lib/context/file/nominal.js +0 -586
- package/lib/context/illative.js +0 -28
- package/lib/context/liminal.js +0 -200
- package/lib/context/literal.js +0 -44
- package/lib/context/mnemic.js +0 -454
- package/lib/context/nested.js +0 -31
- package/lib/context/nominal.js +0 -57
- package/lib/context/phaneric.js +0 -44
- package/lib/context/thetic.js +0 -28
- package/lib/context.js +0 -445
- package/lib/element/assertion/contained.js +0 -218
- package/lib/element/assertion/defined.js +0 -213
- package/lib/element/assertion/property.js +0 -176
- package/lib/element/assertion/signature.js +0 -170
- package/lib/element/assertion/subproof.js +0 -220
- package/lib/element/assertion/type.js +0 -227
- package/lib/element/assertion.js +0 -49
- package/lib/element/assumption/metaLevel.js +0 -244
- package/lib/element/assumption.js +0 -252
- package/lib/element/combinator/bracketed.js +0 -36
- package/lib/element/combinator.js +0 -104
- package/lib/element/conclusion.js +0 -131
- package/lib/element/constructor/bracketed.js +0 -57
- package/lib/element/constructor.js +0 -129
- package/lib/element/declaration/combinator.js +0 -58
- package/lib/element/declaration/complexType.js +0 -180
- package/lib/element/declaration/constructor.js +0 -93
- package/lib/element/declaration/metavariable.js +0 -77
- package/lib/element/declaration/property.js +0 -88
- package/lib/element/declaration/simpleType.js +0 -148
- package/lib/element/declaration/typePrefix.js +0 -53
- package/lib/element/declaration/variable.js +0 -99
- package/lib/element/declaration.js +0 -15
- package/lib/element/deduction.js +0 -131
- package/lib/element/derivation.js +0 -46
- package/lib/element/equality.js +0 -211
- package/lib/element/equivalence.js +0 -200
- package/lib/element/error.js +0 -27
- package/lib/element/frame.js +0 -238
- package/lib/element/hypothesis.js +0 -135
- package/lib/element/judgement.js +0 -212
- package/lib/element/label.js +0 -135
- package/lib/element/metaType.js +0 -57
- package/lib/element/metavariable.js +0 -452
- package/lib/element/parameter.js +0 -69
- package/lib/element/procedureCall.js +0 -116
- package/lib/element/procedureReference.js +0 -56
- package/lib/element/proof.js +0 -52
- package/lib/element/proofAssertion/premise.js +0 -238
- package/lib/element/proofAssertion/step.js +0 -235
- package/lib/element/proofAssertion/supposition.js +0 -249
- package/lib/element/proofAssertion.js +0 -56
- package/lib/element/property.js +0 -176
- package/lib/element/propertyRelation.js +0 -132
- package/lib/element/reference.js +0 -227
- package/lib/element/rule.js +0 -242
- package/lib/element/section.js +0 -64
- package/lib/element/signature.js +0 -195
- package/lib/element/statement.js +0 -228
- package/lib/element/subDerivation.js +0 -46
- package/lib/element/subproof.js +0 -91
- package/lib/element/substitution/frame.js +0 -256
- package/lib/element/substitution/reference.js +0 -192
- package/lib/element/substitution/statement.js +0 -294
- package/lib/element/substitution/term.js +0 -266
- package/lib/element/substitution.js +0 -183
- package/lib/element/term.js +0 -217
- package/lib/element/topLevelAssertion/axiom.js +0 -158
- package/lib/element/topLevelAssertion/conjecture.js +0 -42
- package/lib/element/topLevelAssertion/lemma.js +0 -39
- package/lib/element/topLevelAssertion/theorem.js +0 -42
- package/lib/element/topLevelAssertion.js +0 -286
- package/lib/element/topLevelMetaAssertion/metaLemma.js +0 -42
- package/lib/element/topLevelMetaAssertion/metatheorem.js +0 -42
- package/lib/element/topLevelMetaAssertion.js +0 -179
- package/lib/element/type.js +0 -240
- package/lib/element/typePrefix.js +0 -85
- package/lib/element/variable.js +0 -206
- package/lib/elements.js +0 -27
- package/lib/metaTypeNames.js +0 -26
- package/lib/metaTypes.js +0 -66
- package/lib/node/argument.js +0 -31
- package/lib/node/assertion/contained.js +0 -51
- package/lib/node/assertion/defined.js +0 -47
- package/lib/node/assertion/property.js +0 -36
- package/lib/node/assertion/signature.js +0 -32
- package/lib/node/assertion/subproof.js +0 -28
- package/lib/node/assertion/type.js +0 -32
- package/lib/node/assertion.js +0 -18
- package/lib/node/assumption/metaLevel.js +0 -27
- package/lib/node/assumption.js +0 -27
- package/lib/node/body/axiom.js +0 -23
- package/lib/node/body/conjecture.js +0 -23
- package/lib/node/body/lemma.js +0 -23
- package/lib/node/body/metaLemma.js +0 -23
- package/lib/node/body/metatheorem.js +0 -23
- package/lib/node/body/rule.js +0 -44
- package/lib/node/body/theorem.js +0 -23
- package/lib/node/body.js +0 -31
- package/lib/node/combinator.js +0 -23
- package/lib/node/conclusion.js +0 -27
- package/lib/node/constructor.js +0 -23
- package/lib/node/declaration/combinator.js +0 -28
- package/lib/node/declaration/complexType.js +0 -72
- package/lib/node/declaration/constructor.js +0 -47
- package/lib/node/declaration/metavariable.js +0 -36
- package/lib/node/declaration/property.js +0 -44
- package/lib/node/declaration/simpleType.js +0 -72
- package/lib/node/declaration/typePrefix.js +0 -32
- package/lib/node/declaration/variable.js +0 -51
- package/lib/node/declaration.js +0 -18
- package/lib/node/deduction.js +0 -27
- package/lib/node/derivation.js +0 -26
- package/lib/node/document.js +0 -18
- package/lib/node/equality.js +0 -33
- package/lib/node/equivalence.js +0 -23
- package/lib/node/equivalences.js +0 -18
- package/lib/node/error.js +0 -18
- package/lib/node/frame.js +0 -38
- package/lib/node/header/axiom.js +0 -28
- package/lib/node/header/conjecture.js +0 -23
- package/lib/node/header/lemma.js +0 -23
- package/lib/node/header/metaLemma.js +0 -23
- package/lib/node/header/metatheorem.js +0 -23
- package/lib/node/header/rule.js +0 -23
- package/lib/node/header/theorem.js +0 -23
- package/lib/node/header.js +0 -47
- package/lib/node/hypothesis.js +0 -27
- package/lib/node/judgement.js +0 -31
- package/lib/node/label.js +0 -23
- package/lib/node/labels.js +0 -23
- package/lib/node/metaArgument.js +0 -23
- package/lib/node/metaType.js +0 -30
- package/lib/node/metavariable.js +0 -39
- package/lib/node/parameter.js +0 -47
- package/lib/node/parenthesisedLabel.js +0 -23
- package/lib/node/parenthesisedLabels.js +0 -27
- package/lib/node/placeholder.js +0 -18
- package/lib/node/procedureCall.js +0 -31
- package/lib/node/procedureReference.js +0 -30
- package/lib/node/proof.js +0 -23
- package/lib/node/proofAssertion/premise.js +0 -28
- package/lib/node/proofAssertion/step.js +0 -52
- package/lib/node/proofAssertion/supposition.js +0 -28
- package/lib/node/proofAssertion.js +0 -27
- package/lib/node/property.js +0 -30
- package/lib/node/propertyRelation.js +0 -31
- package/lib/node/qualification.js +0 -27
- package/lib/node/reference.js +0 -23
- package/lib/node/rule.js +0 -43
- package/lib/node/section.js +0 -39
- package/lib/node/signature.js +0 -23
- package/lib/node/statement.js +0 -103
- package/lib/node/subDerivation.js +0 -26
- package/lib/node/subproof.js +0 -35
- package/lib/node/substitution/frame.js +0 -40
- package/lib/node/substitution/reference.js +0 -40
- package/lib/node/substitution/statement.js +0 -60
- package/lib/node/substitution/term.js +0 -40
- package/lib/node/substitution.js +0 -18
- package/lib/node/term.js +0 -60
- package/lib/node/topLevelAssertion/axiom.js +0 -26
- package/lib/node/topLevelAssertion/conjecture.js +0 -26
- package/lib/node/topLevelAssertion/lemma.js +0 -26
- package/lib/node/topLevelAssertion/theorem.js +0 -26
- package/lib/node/topLevelAssertion.js +0 -46
- package/lib/node/topLevelMetaAssertion/metaLemma.js +0 -26
- package/lib/node/topLevelMetaAssertion/metatheorem.js +0 -26
- package/lib/node/topLevelMetaAssertion.js +0 -42
- package/lib/node/type.js +0 -60
- package/lib/node/typePrefix.js +0 -30
- package/lib/node/types.js +0 -23
- package/lib/node/variable.js +0 -30
- package/lib/nominal/lexer.js +0 -15
- package/lib/nominal/parser.js +0 -24
- package/lib/nonTerminalNodeMap.js +0 -189
- package/lib/pass/zip.js +0 -23
- package/lib/preamble.js +0 -73
- package/lib/process/assign.js +0 -62
- package/lib/process/discharge.js +0 -38
- package/lib/process/equate.js +0 -73
- package/lib/process/instantiate.js +0 -261
- package/lib/process/unification.js +0 -228
- package/lib/process/unify.js +0 -336
- package/lib/process/validate.js +0 -135
- package/lib/process/validation.js +0 -291
- package/lib/process/verify.js +0 -205
- package/lib/ruleNames.js +0 -350
- package/lib/tokenTypes.js +0 -22
- package/lib/utilities/assignment.js +0 -47
- package/lib/utilities/bnf.js +0 -21
- package/lib/utilities/brackets.js +0 -77
- package/lib/utilities/breakPoint.js +0 -38
- package/lib/utilities/context.js +0 -220
- package/lib/utilities/element.js +0 -1851
- package/lib/utilities/equivalence.js +0 -27
- package/lib/utilities/equivalences.js +0 -134
- package/lib/utilities/instance.js +0 -44
- package/lib/utilities/json.js +0 -1109
- package/lib/utilities/string.js +0 -231
- package/lib/utilities/substitutions.js +0 -86
- package/lib/utilities/synoptic.js +0 -159
- package/lib/utilities/type.js +0 -27
- package/src/context/aphasic.js +0 -15
- package/src/context/bounded.js +0 -362
- package/src/context/branching.js +0 -69
- package/src/context/file/nominal.js +0 -955
- package/src/context/illative.js +0 -17
- package/src/context/liminal.js +0 -280
- package/src/context/literal.js +0 -42
- package/src/context/mnemic.js +0 -778
- package/src/context/nested.js +0 -21
- package/src/context/nominal.js +0 -62
- package/src/context/phaneric.js +0 -43
- package/src/context/thetic.js +0 -17
- package/src/context.js +0 -722
- package/src/element/assertion/contained.js +0 -313
- package/src/element/assertion/defined.js +0 -310
- package/src/element/assertion/property.js +0 -252
- package/src/element/assertion/signature.js +0 -239
- package/src/element/assertion/subproof.js +0 -335
- package/src/element/assertion/type.js +0 -328
- package/src/element/assertion.js +0 -65
- package/src/element/assumption/metaLevel.js +0 -373
- package/src/element/assumption.js +0 -374
- package/src/element/combinator/bracketed.js +0 -32
- package/src/element/combinator.js +0 -145
- package/src/element/conclusion.js +0 -185
- package/src/element/constructor/bracketed.js +0 -68
- package/src/element/constructor.js +0 -188
- package/src/element/declaration/combinator.js +0 -66
- package/src/element/declaration/complexType.js +0 -257
- package/src/element/declaration/constructor.js +0 -122
- package/src/element/declaration/metavariable.js +0 -93
- package/src/element/declaration/property.js +0 -108
- package/src/element/declaration/simpleType.js +0 -208
- package/src/element/declaration/typePrefix.js +0 -58
- package/src/element/declaration/variable.js +0 -130
- package/src/element/declaration.js +0 -7
- package/src/element/deduction.js +0 -185
- package/src/element/derivation.js +0 -57
- package/src/element/equality.js +0 -325
- package/src/element/equivalence.js +0 -276
- package/src/element/error.js +0 -26
- package/src/element/frame.js +0 -356
- package/src/element/hypothesis.js +0 -186
- package/src/element/judgement.js +0 -303
- package/src/element/label.js +0 -186
- package/src/element/metaType.js +0 -75
- package/src/element/metavariable.js +0 -662
- package/src/element/parameter.js +0 -90
- package/src/element/procedureCall.js +0 -159
- package/src/element/procedureReference.js +0 -71
- package/src/element/proof.js +0 -61
- package/src/element/proofAssertion/premise.js +0 -354
- package/src/element/proofAssertion/step.js +0 -271
- package/src/element/proofAssertion/supposition.js +0 -377
- package/src/element/proofAssertion.js +0 -74
- package/src/element/property.js +0 -258
- package/src/element/propertyRelation.js +0 -193
- package/src/element/reference.js +0 -345
- package/src/element/rule.js +0 -358
- package/src/element/section.js +0 -78
- package/src/element/signature.js +0 -292
- package/src/element/statement.js +0 -358
- package/src/element/subDerivation.js +0 -56
- package/src/element/subproof.js +0 -116
- package/src/element/substitution/frame.js +0 -392
- package/src/element/substitution/reference.js +0 -274
- package/src/element/substitution/statement.js +0 -452
- package/src/element/substitution/term.js +0 -407
- package/src/element/substitution.js +0 -261
- package/src/element/term.js +0 -339
- package/src/element/topLevelAssertion/axiom.js +0 -244
- package/src/element/topLevelAssertion/conjecture.js +0 -40
- package/src/element/topLevelAssertion/lemma.js +0 -42
- package/src/element/topLevelAssertion/theorem.js +0 -40
- package/src/element/topLevelAssertion.js +0 -436
- package/src/element/topLevelMetaAssertion/metaLemma.js +0 -40
- package/src/element/topLevelMetaAssertion/metatheorem.js +0 -40
- package/src/element/topLevelMetaAssertion.js +0 -276
- package/src/element/type.js +0 -374
- package/src/element/typePrefix.js +0 -113
- package/src/element/variable.js +0 -259
- package/src/elements.js +0 -13
- package/src/metaTypeNames.js +0 -5
- package/src/metaTypes.js +0 -71
- package/src/node/argument.js +0 -30
- package/src/node/assertion/contained.js +0 -53
- package/src/node/assertion/defined.js +0 -46
- package/src/node/assertion/property.js +0 -30
- package/src/node/assertion/signature.js +0 -23
- package/src/node/assertion/subproof.js +0 -16
- package/src/node/assertion/type.js +0 -23
- package/src/node/assertion.js +0 -7
- package/src/node/assumption/metaLevel.js +0 -23
- package/src/node/assumption.js +0 -23
- package/src/node/body/axiom.js +0 -7
- package/src/node/body/conjecture.js +0 -7
- package/src/node/body/lemma.js +0 -7
- package/src/node/body/metaLemma.js +0 -7
- package/src/node/body/metatheorem.js +0 -7
- package/src/node/body/rule.js +0 -42
- package/src/node/body/theorem.js +0 -7
- package/src/node/body.js +0 -30
- package/src/node/combinator.js +0 -16
- package/src/node/conclusion.js +0 -23
- package/src/node/constructor.js +0 -16
- package/src/node/declaration/combinator.js +0 -16
- package/src/node/declaration/complexType.js +0 -88
- package/src/node/declaration/constructor.js +0 -46
- package/src/node/declaration/metavariable.js +0 -30
- package/src/node/declaration/property.js +0 -42
- package/src/node/declaration/simpleType.js +0 -87
- package/src/node/declaration/typePrefix.js +0 -24
- package/src/node/declaration/variable.js +0 -53
- package/src/node/declaration.js +0 -7
- package/src/node/deduction.js +0 -23
- package/src/node/derivation.js +0 -19
- package/src/node/document.js +0 -7
- package/src/node/equality.js +0 -35
- package/src/node/equivalence.js +0 -16
- package/src/node/equivalences.js +0 -7
- package/src/node/error.js +0 -7
- package/src/node/frame.js +0 -40
- package/src/node/header/axiom.js +0 -16
- package/src/node/header/conjecture.js +0 -7
- package/src/node/header/lemma.js +0 -7
- package/src/node/header/metaLemma.js +0 -7
- package/src/node/header/metatheorem.js +0 -7
- package/src/node/header/rule.js +0 -7
- package/src/node/header/theorem.js +0 -7
- package/src/node/header.js +0 -54
- package/src/node/hypothesis.js +0 -23
- package/src/node/judgement.js +0 -30
- package/src/node/label.js +0 -16
- package/src/node/labels.js +0 -16
- package/src/node/metaArgument.js +0 -16
- package/src/node/metaType.js +0 -26
- package/src/node/metavariable.js +0 -42
- package/src/node/parameter.js +0 -51
- package/src/node/parenthesisedLabel.js +0 -16
- package/src/node/parenthesisedLabels.js +0 -23
- package/src/node/placeholder.js +0 -7
- package/src/node/procedureCall.js +0 -30
- package/src/node/procedureReference.js +0 -26
- package/src/node/proof.js +0 -16
- package/src/node/proofAssertion/premise.js +0 -16
- package/src/node/proofAssertion/step.js +0 -52
- package/src/node/proofAssertion/supposition.js +0 -16
- package/src/node/proofAssertion.js +0 -23
- package/src/node/property.js +0 -28
- package/src/node/propertyRelation.js +0 -30
- package/src/node/qualification.js +0 -23
- package/src/node/reference.js +0 -16
- package/src/node/rule.js +0 -51
- package/src/node/section.js +0 -44
- package/src/node/signature.js +0 -16
- package/src/node/statement.js +0 -167
- package/src/node/subDerivation.js +0 -19
- package/src/node/subproof.js +0 -35
- package/src/node/substitution/frame.js +0 -37
- package/src/node/substitution/reference.js +0 -38
- package/src/node/substitution/statement.js +0 -70
- package/src/node/substitution/term.js +0 -38
- package/src/node/substitution.js +0 -7
- package/src/node/term.js +0 -75
- package/src/node/topLevelAssertion/axiom.js +0 -13
- package/src/node/topLevelAssertion/conjecture.js +0 -13
- package/src/node/topLevelAssertion/lemma.js +0 -13
- package/src/node/topLevelAssertion/theorem.js +0 -13
- package/src/node/topLevelAssertion.js +0 -58
- package/src/node/topLevelMetaAssertion/metaLemma.js +0 -13
- package/src/node/topLevelMetaAssertion/metatheorem.js +0 -13
- package/src/node/topLevelMetaAssertion.js +0 -51
- package/src/node/type.js +0 -74
- package/src/node/typePrefix.js +0 -26
- package/src/node/types.js +0 -16
- package/src/node/variable.js +0 -26
- package/src/nominal/lexer.js +0 -5
- package/src/nominal/parser.js +0 -12
- package/src/nonTerminalNodeMap.js +0 -261
- package/src/pass/zip.js +0 -19
- package/src/preamble.js +0 -64
- package/src/process/assign.js +0 -53
- package/src/process/discharge.js +0 -33
- package/src/process/equate.js +0 -94
- package/src/process/instantiate.js +0 -198
- package/src/process/unification.js +0 -332
- package/src/process/unify.js +0 -504
- package/src/process/validate.js +0 -174
- package/src/process/validation.js +0 -410
- package/src/process/verify.js +0 -299
- package/src/ruleNames.js +0 -86
- package/src/tokenTypes.js +0 -4
- package/src/utilities/assignment.js +0 -57
- package/src/utilities/bnf.js +0 -20
- package/src/utilities/brackets.js +0 -87
- package/src/utilities/breakPoint.js +0 -29
- package/src/utilities/context.js +0 -223
- package/src/utilities/element.js +0 -2293
- package/src/utilities/equivalence.js +0 -25
- package/src/utilities/equivalences.js +0 -158
- package/src/utilities/instance.js +0 -40
- package/src/utilities/json.js +0 -1273
- package/src/utilities/string.js +0 -282
- package/src/utilities/substitutions.js +0 -93
- package/src/utilities/synoptic.js +0 -135
- package/src/utilities/type.js +0 -19
package/src/utilities/json.js
DELETED
|
@@ -1,1273 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
import elements from "../elements";
|
|
4
|
-
import MnemicContext from "../context/mnemic";
|
|
5
|
-
|
|
6
|
-
export function nameFromJSON(json, context) {
|
|
7
|
-
let { name } = json;
|
|
8
|
-
|
|
9
|
-
const nameJSON = name; ///
|
|
10
|
-
|
|
11
|
-
name = nameJSON; ///
|
|
12
|
-
|
|
13
|
-
return name;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
export function termFromJSON(json, context) {
|
|
17
|
-
let { term } = json;
|
|
18
|
-
|
|
19
|
-
if (term !== null) {
|
|
20
|
-
const termJSON = term; ///
|
|
21
|
-
|
|
22
|
-
json = termJSON; ///
|
|
23
|
-
|
|
24
|
-
const { Term } = elements;
|
|
25
|
-
|
|
26
|
-
term = Term.fromJSON(json, context);
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
return term;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
export function typeFromJSON(json, context) {
|
|
33
|
-
let { type } = json;
|
|
34
|
-
|
|
35
|
-
if (type !== null) {
|
|
36
|
-
json = type; ///
|
|
37
|
-
|
|
38
|
-
const { string } = json,
|
|
39
|
-
name = string; ///
|
|
40
|
-
|
|
41
|
-
type = findTypeByName(name, context);
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
return type;
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
export function labelFromJSON(json, context) {
|
|
48
|
-
let { label } = json;
|
|
49
|
-
|
|
50
|
-
const { Label } = elements,
|
|
51
|
-
labelJSON = label; ///
|
|
52
|
-
|
|
53
|
-
json = labelJSON; ///
|
|
54
|
-
|
|
55
|
-
label = Label.fromJSON(json, context);
|
|
56
|
-
|
|
57
|
-
return label;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
export function frameFromJSON(json, context) {
|
|
61
|
-
let { frame } = json;
|
|
62
|
-
|
|
63
|
-
if (frame !== null) {
|
|
64
|
-
const frameJSON = frame; ///
|
|
65
|
-
|
|
66
|
-
json = frameJSON; ///
|
|
67
|
-
|
|
68
|
-
const { Frame } = elements;
|
|
69
|
-
|
|
70
|
-
frame = Frame.fromJSON(json, context);
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
return frame;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
export function negatedFromJSON(json, context) {
|
|
77
|
-
const { negated } = json;
|
|
78
|
-
|
|
79
|
-
return negated;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
export function metaTypeFromJSON(json, context) {
|
|
83
|
-
let { metaType } = json;
|
|
84
|
-
|
|
85
|
-
if (metaType !== null) {
|
|
86
|
-
json = metaType; ///
|
|
87
|
-
|
|
88
|
-
const { string } = json,
|
|
89
|
-
name = string; ///
|
|
90
|
-
|
|
91
|
-
metaType = findMetaTypeByName(name, context);
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
return metaType;
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
export function statementFromJSON(json, context) {
|
|
98
|
-
let { statement = null } = json;
|
|
99
|
-
|
|
100
|
-
if (statement !== null) {
|
|
101
|
-
const { Statement } = elements,
|
|
102
|
-
statementJSON = statement; ///
|
|
103
|
-
|
|
104
|
-
json = statementJSON; ///
|
|
105
|
-
|
|
106
|
-
statement = Statement.fromJSON(json, context);
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
return statement;
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
export function deductionFromJSON(json, context) {
|
|
113
|
-
let { deduction } = json;
|
|
114
|
-
|
|
115
|
-
const { Deduction } = elements,
|
|
116
|
-
deductionJSON = deduction; ///
|
|
117
|
-
|
|
118
|
-
json = deductionJSON; ///
|
|
119
|
-
|
|
120
|
-
deduction = Deduction.fromJSON(json, context);
|
|
121
|
-
|
|
122
|
-
return deduction;
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
export function signatureFromJSON(json, context) {
|
|
126
|
-
let { signature = null } = json;
|
|
127
|
-
|
|
128
|
-
if (signature !== null) {
|
|
129
|
-
const { Signature } = elements,
|
|
130
|
-
signatureJSON = signature; ///
|
|
131
|
-
|
|
132
|
-
json = signatureJSON; ///
|
|
133
|
-
|
|
134
|
-
signature = Signature.fromJSON(json, context);
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
return signature;
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
export function referenceFromJSON(json, context) {
|
|
141
|
-
let { reference } = json;
|
|
142
|
-
|
|
143
|
-
const { Reference } = elements,
|
|
144
|
-
referenceJSON = reference; ///
|
|
145
|
-
|
|
146
|
-
json = referenceJSON; ///
|
|
147
|
-
|
|
148
|
-
reference = Reference.fromJSON(json, context);
|
|
149
|
-
|
|
150
|
-
return reference;
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
export function identifierFromJSON(json, context) {
|
|
154
|
-
let { identifier } = json;
|
|
155
|
-
|
|
156
|
-
const identifierJSON = identifier; ///
|
|
157
|
-
|
|
158
|
-
identifier = identifierJSON; ///
|
|
159
|
-
|
|
160
|
-
return identifier;
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
export function conclusionFromJSON(json, context) {
|
|
164
|
-
let { conclusion } = json;
|
|
165
|
-
|
|
166
|
-
const { Conclusion } = elements,
|
|
167
|
-
conclusionJSON = conclusion; ///
|
|
168
|
-
|
|
169
|
-
json = conclusionJSON; ///
|
|
170
|
-
|
|
171
|
-
conclusion = Conclusion.fromJSON(json, context);
|
|
172
|
-
|
|
173
|
-
return conclusion;
|
|
174
|
-
}
|
|
175
|
-
|
|
176
|
-
export function provisionalFromJSON(json, context) {
|
|
177
|
-
const { provisional } = json;
|
|
178
|
-
|
|
179
|
-
return provisional;
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
export function metavariableFromJSON(json, context) {
|
|
183
|
-
let { metavariable } = json;
|
|
184
|
-
|
|
185
|
-
const { Metavariable } = elements,
|
|
186
|
-
metavariableJSON = metavariable; ///
|
|
187
|
-
|
|
188
|
-
json = metavariableJSON; ///
|
|
189
|
-
|
|
190
|
-
metavariable = Metavariable.fromJSON(json, context);
|
|
191
|
-
|
|
192
|
-
return metavariable;
|
|
193
|
-
}
|
|
194
|
-
|
|
195
|
-
export function mnemicContextFromJSON(json, context) {
|
|
196
|
-
const releaseContext = context; ///
|
|
197
|
-
|
|
198
|
-
({ context } = json);
|
|
199
|
-
|
|
200
|
-
json = context; ///
|
|
201
|
-
|
|
202
|
-
context = releaseContext; ///
|
|
203
|
-
|
|
204
|
-
const mnemicContext = MnemicContext.fromJSON(json, context);
|
|
205
|
-
|
|
206
|
-
return mnemicContext;
|
|
207
|
-
}
|
|
208
|
-
|
|
209
|
-
export function procedureCallFromJSON(json, context) {
|
|
210
|
-
let { procedureCall = null } = json;
|
|
211
|
-
|
|
212
|
-
if (procedureCall !== null) {
|
|
213
|
-
const { ProcedureCall } = elements,
|
|
214
|
-
procedureCallJSON = procedureCall; ///
|
|
215
|
-
|
|
216
|
-
json = procedureCallJSON; ///
|
|
217
|
-
|
|
218
|
-
procedureCall = ProcedureCall.fromJSON(json, context);
|
|
219
|
-
}
|
|
220
|
-
|
|
221
|
-
return procedureCall;
|
|
222
|
-
}
|
|
223
|
-
|
|
224
|
-
export function procedureReferenceFromJSON(json, context) {
|
|
225
|
-
let { procedureReference } = json;
|
|
226
|
-
|
|
227
|
-
const { ProcedureReference } = elements,
|
|
228
|
-
procedureReferenceJSON = procedureReference; ///
|
|
229
|
-
|
|
230
|
-
json = procedureReferenceJSON; ///
|
|
231
|
-
|
|
232
|
-
procedureReference = ProcedureReference.fromJSON(json, context);
|
|
233
|
-
|
|
234
|
-
return procedureReference;
|
|
235
|
-
}
|
|
236
|
-
|
|
237
|
-
export function typesFromJSON(json, types, context) {
|
|
238
|
-
const { types: typesJSON } = json;
|
|
239
|
-
|
|
240
|
-
const { Type } = elements;
|
|
241
|
-
|
|
242
|
-
typesJSON.forEach((typeJSON) => {
|
|
243
|
-
const json = typeJSON, ///
|
|
244
|
-
type = Type.fromJSON(json, context);
|
|
245
|
-
|
|
246
|
-
types.push(type);
|
|
247
|
-
});
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
export function termsFromJSON(json, context) {
|
|
251
|
-
let { terms } = json;
|
|
252
|
-
|
|
253
|
-
const { Term } = elements,
|
|
254
|
-
termsJSON = terms; ///
|
|
255
|
-
|
|
256
|
-
terms = termsJSON.map((termJSON) => {
|
|
257
|
-
const json = termJSON, ///
|
|
258
|
-
term = Term.fromJSON(json, context);
|
|
259
|
-
|
|
260
|
-
return term;
|
|
261
|
-
});
|
|
262
|
-
|
|
263
|
-
return terms;
|
|
264
|
-
}
|
|
265
|
-
|
|
266
|
-
export function rulesFromJSON(json, context) {
|
|
267
|
-
let { rules } = json;
|
|
268
|
-
|
|
269
|
-
const { Rule } = elements,
|
|
270
|
-
rulesJSON = rules; ///
|
|
271
|
-
|
|
272
|
-
rules = rulesJSON.map((ruleJSON) => {
|
|
273
|
-
const json = ruleJSON, ///
|
|
274
|
-
rule = Rule.fromJSON(json, context);
|
|
275
|
-
|
|
276
|
-
return rule;
|
|
277
|
-
});
|
|
278
|
-
|
|
279
|
-
return rules;
|
|
280
|
-
}
|
|
281
|
-
|
|
282
|
-
export function framesFromJSON(json, context) {
|
|
283
|
-
let { frames } = json;
|
|
284
|
-
|
|
285
|
-
const { Frame } = elements,
|
|
286
|
-
framesJSON = frames; ///
|
|
287
|
-
|
|
288
|
-
frames = framesJSON.map((frameJSON) => {
|
|
289
|
-
const json = frameJSON, ///
|
|
290
|
-
frame = Frame.fromJSON(json, context);
|
|
291
|
-
|
|
292
|
-
return frame;
|
|
293
|
-
});
|
|
294
|
-
|
|
295
|
-
return frames;
|
|
296
|
-
}
|
|
297
|
-
|
|
298
|
-
export function labelsFromJSON(json, context) {
|
|
299
|
-
let { labels } = json;
|
|
300
|
-
|
|
301
|
-
const { Label } = elements,
|
|
302
|
-
labelsJSON = labels; ///
|
|
303
|
-
|
|
304
|
-
labels = labelsJSON.map((labelJSON) => {
|
|
305
|
-
const json = labelJSON, ///
|
|
306
|
-
label = Label.fromJSON(json, context);
|
|
307
|
-
|
|
308
|
-
return label;
|
|
309
|
-
});
|
|
310
|
-
|
|
311
|
-
return labels;
|
|
312
|
-
}
|
|
313
|
-
|
|
314
|
-
export function axiomsFromJSON(json, context) {
|
|
315
|
-
let { axioms } = json;
|
|
316
|
-
|
|
317
|
-
const { Axiom } = elements,
|
|
318
|
-
axiomsJSON = axioms; ///
|
|
319
|
-
|
|
320
|
-
axioms = axiomsJSON.map((axiomJSON) => {
|
|
321
|
-
const json = axiomJSON, ///
|
|
322
|
-
axiom = Axiom.fromJSON(json, context);
|
|
323
|
-
|
|
324
|
-
return axiom;
|
|
325
|
-
});
|
|
326
|
-
|
|
327
|
-
return axioms;
|
|
328
|
-
}
|
|
329
|
-
|
|
330
|
-
export function premisesFromJSON(json, context) {
|
|
331
|
-
let { premises } = json;
|
|
332
|
-
|
|
333
|
-
const { Premise } = elements,
|
|
334
|
-
premisesJSON = premises; ///
|
|
335
|
-
|
|
336
|
-
premises = premisesJSON.map((premiseJSON) => {
|
|
337
|
-
const json = premiseJSON, ///
|
|
338
|
-
premise = Premise.fromJSON(json, context);
|
|
339
|
-
|
|
340
|
-
return premise;
|
|
341
|
-
});
|
|
342
|
-
|
|
343
|
-
return premises;
|
|
344
|
-
}
|
|
345
|
-
|
|
346
|
-
export function theoremsFromJSON(json, context) {
|
|
347
|
-
let { theorems } = json;
|
|
348
|
-
|
|
349
|
-
const { Theorem } = elements,
|
|
350
|
-
theoremsJSON = theorems; ///
|
|
351
|
-
|
|
352
|
-
theorems = theoremsJSON.map((theoremJSON) => {
|
|
353
|
-
const json = theoremJSON, ///
|
|
354
|
-
theorem = Theorem.fromJSON(json, context);
|
|
355
|
-
|
|
356
|
-
return theorem;
|
|
357
|
-
});
|
|
358
|
-
|
|
359
|
-
return theorems;
|
|
360
|
-
}
|
|
361
|
-
|
|
362
|
-
export function variablesFromJSON(json, context) {
|
|
363
|
-
let { variables } = json;
|
|
364
|
-
|
|
365
|
-
const { Variable } = elements,
|
|
366
|
-
variablesJSON = variables; ///
|
|
367
|
-
|
|
368
|
-
variables = variablesJSON.map((variableJSON) => {
|
|
369
|
-
const json = variableJSON, ///
|
|
370
|
-
variable = Variable.fromJSON(json, context);
|
|
371
|
-
|
|
372
|
-
return variable;
|
|
373
|
-
});
|
|
374
|
-
|
|
375
|
-
return variables;
|
|
376
|
-
}
|
|
377
|
-
|
|
378
|
-
export function propertiesFromJSON(json, context) {
|
|
379
|
-
let { properties } = json;
|
|
380
|
-
|
|
381
|
-
const { Property } = elements,
|
|
382
|
-
propertiesJSON = properties; ///
|
|
383
|
-
|
|
384
|
-
properties = propertiesJSON.map((propertyJSON) => {
|
|
385
|
-
const json = propertyJSON, ///
|
|
386
|
-
property = Property.fromJSON(json, context);
|
|
387
|
-
|
|
388
|
-
return property;
|
|
389
|
-
});
|
|
390
|
-
|
|
391
|
-
return properties;
|
|
392
|
-
}
|
|
393
|
-
|
|
394
|
-
export function equalitiesFromJSON(json, context) {
|
|
395
|
-
let { equalities } = json;
|
|
396
|
-
|
|
397
|
-
const { Equality } = elements,
|
|
398
|
-
equalitiesJSON = equalities; ///
|
|
399
|
-
|
|
400
|
-
equalities = equalitiesJSON.map((equalityJSON) => {
|
|
401
|
-
const json = equalityJSON, ///
|
|
402
|
-
equality = Equality.fromJSON(json, context);
|
|
403
|
-
|
|
404
|
-
return equality;
|
|
405
|
-
});
|
|
406
|
-
|
|
407
|
-
return equalities;
|
|
408
|
-
}
|
|
409
|
-
|
|
410
|
-
export function prefixNameFromJSON(json, context) {
|
|
411
|
-
const { prefixName } = json;
|
|
412
|
-
|
|
413
|
-
return prefixName;
|
|
414
|
-
}
|
|
415
|
-
|
|
416
|
-
export function superTypesFromJSON(json, context) {
|
|
417
|
-
const { superTypes: superTypesJSON } = json;
|
|
418
|
-
|
|
419
|
-
const superTypes = superTypesJSON.map((superTypeJSON) => {
|
|
420
|
-
const json = superTypeJSON, ///
|
|
421
|
-
{ string } = json,
|
|
422
|
-
name = string, ///
|
|
423
|
-
type = findTypeByName(name, context),
|
|
424
|
-
superType = type; ///
|
|
425
|
-
|
|
426
|
-
return superType;
|
|
427
|
-
});
|
|
428
|
-
|
|
429
|
-
return superTypes;
|
|
430
|
-
}
|
|
431
|
-
|
|
432
|
-
export function hypothesesFromJSON(json, context) {
|
|
433
|
-
let { hypotheses } = json;
|
|
434
|
-
|
|
435
|
-
const { Hypothesis } = elements,
|
|
436
|
-
hypothesesJSON = hypotheses; ///
|
|
437
|
-
|
|
438
|
-
hypotheses = hypothesesJSON.map((hypothesisJSON) => {
|
|
439
|
-
const json = hypothesisJSON, ///
|
|
440
|
-
hypothesis = Hypothesis.fromJSON(json, context);
|
|
441
|
-
|
|
442
|
-
return hypothesis;
|
|
443
|
-
});
|
|
444
|
-
|
|
445
|
-
return hypotheses;
|
|
446
|
-
}
|
|
447
|
-
|
|
448
|
-
export function parametersFromJSON(json, context) {
|
|
449
|
-
let { parameters } = json;
|
|
450
|
-
|
|
451
|
-
const { Parameter } = elements,
|
|
452
|
-
parametersJSON = parameters; ///
|
|
453
|
-
|
|
454
|
-
parameters = parametersJSON.map((parameterJSON) => {
|
|
455
|
-
const json = parameterJSON, ///
|
|
456
|
-
parameter = Parameter.fromJSON(json, context);
|
|
457
|
-
|
|
458
|
-
return parameter;
|
|
459
|
-
});
|
|
460
|
-
|
|
461
|
-
return parameters;
|
|
462
|
-
}
|
|
463
|
-
|
|
464
|
-
export function judgementsFromJSON(json, context) {
|
|
465
|
-
let { judgements } = json;
|
|
466
|
-
|
|
467
|
-
const { Judgement } = elements,
|
|
468
|
-
judgementsJSON = judgements; ///
|
|
469
|
-
|
|
470
|
-
judgements = judgementsJSON.map((judgementJSON) => {
|
|
471
|
-
const json = judgementJSON, ///
|
|
472
|
-
judgement = Judgement.fromJSON(json, context);
|
|
473
|
-
|
|
474
|
-
return judgement;
|
|
475
|
-
});
|
|
476
|
-
|
|
477
|
-
return judgements;
|
|
478
|
-
}
|
|
479
|
-
|
|
480
|
-
export function statementsFromJSON(json, context) {
|
|
481
|
-
let { statements } = json;
|
|
482
|
-
|
|
483
|
-
const { Statement } = elements,
|
|
484
|
-
statementsJSON = statements; ///
|
|
485
|
-
|
|
486
|
-
statements = statementsJSON.map((statementJSON) => {
|
|
487
|
-
const json = statementJSON, ///
|
|
488
|
-
statement = Statement.fromJSON(json, context);
|
|
489
|
-
|
|
490
|
-
return statement;
|
|
491
|
-
});
|
|
492
|
-
|
|
493
|
-
return statements;
|
|
494
|
-
}
|
|
495
|
-
|
|
496
|
-
export function assertionsFromJSON(json, context) {
|
|
497
|
-
let { assertions } = json;
|
|
498
|
-
|
|
499
|
-
const { TypeAssertion, DefinedAssertion, PropertyAssertion, SubproofAssertion, SignatureAssertion, ContainedAssertion } = elements,
|
|
500
|
-
assertionsJSON = assertions; ///
|
|
501
|
-
|
|
502
|
-
assertions = assertionsJSON.map((assertionJSON) => {
|
|
503
|
-
const json = assertionJSON, ///
|
|
504
|
-
assertion = TypeAssertion.fromJSON(json, context) ||
|
|
505
|
-
DefinedAssertion.fromJSON(json, context) ||
|
|
506
|
-
PropertyAssertion.fromJSON(json, context) ||
|
|
507
|
-
SubproofAssertion.fromJSON(json, context) ||
|
|
508
|
-
SignatureAssertion.fromJSON(json, context) ||
|
|
509
|
-
ContainedAssertion.fromJSON(json, context);
|
|
510
|
-
|
|
511
|
-
return assertion;
|
|
512
|
-
});
|
|
513
|
-
|
|
514
|
-
return assertions;
|
|
515
|
-
}
|
|
516
|
-
|
|
517
|
-
export function referencesFromJSON(json, context) {
|
|
518
|
-
let { references } = json;
|
|
519
|
-
|
|
520
|
-
const { Reference } = elements,
|
|
521
|
-
referencesJSON = references; ///
|
|
522
|
-
|
|
523
|
-
references = referencesJSON.map((referenceJSON) => {
|
|
524
|
-
const json = referenceJSON, ///
|
|
525
|
-
reference = Reference.fromJSON(json, context);
|
|
526
|
-
|
|
527
|
-
return reference;
|
|
528
|
-
});
|
|
529
|
-
|
|
530
|
-
return references;
|
|
531
|
-
}
|
|
532
|
-
|
|
533
|
-
export function signaturesFromJSON(json, context) {
|
|
534
|
-
let { signatures } = json;
|
|
535
|
-
|
|
536
|
-
const { Signature } = elements,
|
|
537
|
-
signaturesJSON = signatures; ///
|
|
538
|
-
|
|
539
|
-
signatures = signaturesJSON.map((signatureJSON) => {
|
|
540
|
-
const json = signatureJSON, ///
|
|
541
|
-
signature = Signature.fromJSON(json, context);
|
|
542
|
-
|
|
543
|
-
return signature;
|
|
544
|
-
});
|
|
545
|
-
|
|
546
|
-
return signatures;
|
|
547
|
-
}
|
|
548
|
-
|
|
549
|
-
export function conjecturesFromJSON(json, context) {
|
|
550
|
-
let { conjectures } = json;
|
|
551
|
-
|
|
552
|
-
const { Conjecture } = elements,
|
|
553
|
-
conjecturesJSON = conjectures; ///
|
|
554
|
-
|
|
555
|
-
conjectures = conjecturesJSON.map((conjectureJSON) => {
|
|
556
|
-
const json = conjectureJSON, ///
|
|
557
|
-
conjecture = Conjecture.fromJSON(json, context);
|
|
558
|
-
|
|
559
|
-
return conjecture;
|
|
560
|
-
});
|
|
561
|
-
|
|
562
|
-
return conjectures;
|
|
563
|
-
}
|
|
564
|
-
|
|
565
|
-
export function combinatorsFromJSON(json, context) {
|
|
566
|
-
let { combinators } = json;
|
|
567
|
-
|
|
568
|
-
const { Combinator } = elements,
|
|
569
|
-
combinatorsJSON = combinators; ///
|
|
570
|
-
|
|
571
|
-
combinators = combinatorsJSON.map((combinatorJSON) => {
|
|
572
|
-
const json = combinatorJSON, ///
|
|
573
|
-
combinator = Combinator.fromJSON(json, context);
|
|
574
|
-
|
|
575
|
-
return combinator;
|
|
576
|
-
});
|
|
577
|
-
|
|
578
|
-
return combinators;
|
|
579
|
-
}
|
|
580
|
-
|
|
581
|
-
export function assumptionsFromJSON(json, context) {
|
|
582
|
-
let { assumptions } = json;
|
|
583
|
-
|
|
584
|
-
const { Assumption } = elements,
|
|
585
|
-
assumptionsJSON = assumptions; ///
|
|
586
|
-
|
|
587
|
-
assumptions = assumptionsJSON.map((assumptionJSON) => {
|
|
588
|
-
const json = assumptionJSON, ///
|
|
589
|
-
assumption = Assumption.fromJSON(json, context);
|
|
590
|
-
|
|
591
|
-
return assumption;
|
|
592
|
-
});
|
|
593
|
-
|
|
594
|
-
return assumptions;
|
|
595
|
-
}
|
|
596
|
-
|
|
597
|
-
export function typePrefixesFromJSON(json, context) {
|
|
598
|
-
let { typePrefixes } = json;
|
|
599
|
-
|
|
600
|
-
const { TypePrefix } = elements,
|
|
601
|
-
typePrefixesJSON = typePrefixes; ///
|
|
602
|
-
|
|
603
|
-
typePrefixes = typePrefixesJSON.map((typePrefixJSON) => {
|
|
604
|
-
const json = typePrefixJSON, ///
|
|
605
|
-
typePrefix = TypePrefix.fromJSON(json, context);
|
|
606
|
-
|
|
607
|
-
return typePrefix;
|
|
608
|
-
});
|
|
609
|
-
|
|
610
|
-
return typePrefixes;
|
|
611
|
-
}
|
|
612
|
-
|
|
613
|
-
export function constructorsFromJSON(json, context) {
|
|
614
|
-
let { constructors } = json;
|
|
615
|
-
|
|
616
|
-
const { Constructor } = elements,
|
|
617
|
-
constructorsJSON = constructors; ///
|
|
618
|
-
|
|
619
|
-
constructors = constructorsJSON.map((constructorJSON) => {
|
|
620
|
-
const json = constructorJSON, ///
|
|
621
|
-
constructor = Constructor.fromJSON(json, context);
|
|
622
|
-
|
|
623
|
-
return constructor;
|
|
624
|
-
});
|
|
625
|
-
|
|
626
|
-
return constructors;
|
|
627
|
-
}
|
|
628
|
-
|
|
629
|
-
export function metatheoremsFromJSON(json, context) {
|
|
630
|
-
let { metatheorems } = json;
|
|
631
|
-
|
|
632
|
-
const { Metatheorem } = elements,
|
|
633
|
-
metatheoremsJSON = metatheorems; ///
|
|
634
|
-
|
|
635
|
-
metatheorems = metatheoremsJSON.map((metatheoremJSON) => {
|
|
636
|
-
const json = metatheoremJSON, ///
|
|
637
|
-
metatheorem = Metatheorem.fromJSON(json, context);
|
|
638
|
-
|
|
639
|
-
return metatheorem;
|
|
640
|
-
});
|
|
641
|
-
|
|
642
|
-
return metatheorems;
|
|
643
|
-
}
|
|
644
|
-
|
|
645
|
-
export function suppositionsFromJSON(json, context) {
|
|
646
|
-
let { suppositions } = json;
|
|
647
|
-
|
|
648
|
-
const { Supposition } = elements,
|
|
649
|
-
suppositionsJSON = suppositions; ///
|
|
650
|
-
|
|
651
|
-
suppositions = suppositionsJSON.map((suppositionJSON) => {
|
|
652
|
-
const json = suppositionJSON, ///
|
|
653
|
-
supposition = Supposition.fromJSON(json, context);
|
|
654
|
-
|
|
655
|
-
return supposition;
|
|
656
|
-
});
|
|
657
|
-
|
|
658
|
-
return suppositions;
|
|
659
|
-
}
|
|
660
|
-
|
|
661
|
-
export function substitutionsFromJSON(json, context) {
|
|
662
|
-
let { substitutions } = json; ///
|
|
663
|
-
|
|
664
|
-
const substitutionsJSON = substitutions; ///
|
|
665
|
-
|
|
666
|
-
substitutions = substitutionsJSON.map((substitutionJSON) => {
|
|
667
|
-
const json = substitutionJSON, ///
|
|
668
|
-
substitution = substitutionFromSubstitutionJSON(json, context);
|
|
669
|
-
|
|
670
|
-
return substitution;
|
|
671
|
-
});
|
|
672
|
-
|
|
673
|
-
return substitutions;
|
|
674
|
-
}
|
|
675
|
-
|
|
676
|
-
export function metavariablesFromJSON(json, context) {
|
|
677
|
-
let { metavariables } = json;
|
|
678
|
-
|
|
679
|
-
const { Metavariable } = elements,
|
|
680
|
-
metavariablesJSON = metavariables; ///
|
|
681
|
-
|
|
682
|
-
metavariables = metavariablesJSON.map((metavariableJSON) => {
|
|
683
|
-
const json = metavariableJSON, ///
|
|
684
|
-
metavariable = Metavariable.fromJSON(json, context);
|
|
685
|
-
|
|
686
|
-
return metavariable;
|
|
687
|
-
});
|
|
688
|
-
|
|
689
|
-
return metavariables;
|
|
690
|
-
}
|
|
691
|
-
|
|
692
|
-
export function mnemicContextsFromJSON(json, context) {
|
|
693
|
-
const releaseContext = context; ///
|
|
694
|
-
|
|
695
|
-
const { contexts } = json;
|
|
696
|
-
|
|
697
|
-
const mnemicContexts = contexts.map((context) => {
|
|
698
|
-
json = context; ///
|
|
699
|
-
|
|
700
|
-
context = releaseContext; ///
|
|
701
|
-
|
|
702
|
-
const mnemicContext = MnemicContext.fromJSON(json, context);
|
|
703
|
-
|
|
704
|
-
return mnemicContext; ///
|
|
705
|
-
});
|
|
706
|
-
|
|
707
|
-
return mnemicContexts;
|
|
708
|
-
}
|
|
709
|
-
|
|
710
|
-
export function declaredVariablesFromJSON(json, context) {
|
|
711
|
-
let { declaredVariables } = json;
|
|
712
|
-
|
|
713
|
-
const { Variable } = elements,
|
|
714
|
-
declaredVariablesJSON = declaredVariables; ///
|
|
715
|
-
|
|
716
|
-
declaredVariables = declaredVariablesJSON.map((declaredVariableJSON) => {
|
|
717
|
-
const json = declaredVariableJSON, ///
|
|
718
|
-
variable = Variable.fromJSON(json, context),
|
|
719
|
-
declaredVariable = variable; ///
|
|
720
|
-
|
|
721
|
-
return declaredVariable;
|
|
722
|
-
});
|
|
723
|
-
|
|
724
|
-
return declaredVariables;
|
|
725
|
-
}
|
|
726
|
-
|
|
727
|
-
export function propertyRelationsFromJSON(json, context) {
|
|
728
|
-
let { propertyRelations } = json;
|
|
729
|
-
|
|
730
|
-
const { PropertyRelation } = elements,
|
|
731
|
-
propertyRelationsJSON = propertyRelations; ///
|
|
732
|
-
|
|
733
|
-
propertyRelations = propertyRelationsJSON.map((propertyRelationJSON) => {
|
|
734
|
-
const json = propertyRelationJSON, ///
|
|
735
|
-
propertyRelation = PropertyRelation.fromJSON(json, context);
|
|
736
|
-
|
|
737
|
-
return propertyRelation;
|
|
738
|
-
});
|
|
739
|
-
|
|
740
|
-
return propertyRelations;
|
|
741
|
-
}
|
|
742
|
-
|
|
743
|
-
export function metaLevelAssumptionsFromJSON(json, context) {
|
|
744
|
-
let { metaLevelAssumptions } = json;
|
|
745
|
-
|
|
746
|
-
const { MetaLevelAssumption } = elements,
|
|
747
|
-
metaLevelAssumptionsJSON = metaLevelAssumptions; ///
|
|
748
|
-
|
|
749
|
-
metaLevelAssumptions = metaLevelAssumptionsJSON.map((metaLevelAssumptionJSON) => {
|
|
750
|
-
const json = metaLevelAssumptionJSON, ///
|
|
751
|
-
metaLevelAssumption = MetaLevelAssumption.fromJSON(json, context);
|
|
752
|
-
|
|
753
|
-
return metaLevelAssumption;
|
|
754
|
-
});
|
|
755
|
-
|
|
756
|
-
return metaLevelAssumptions;
|
|
757
|
-
}
|
|
758
|
-
|
|
759
|
-
export function declaredMetavariablesFromJSON(json, context) {
|
|
760
|
-
let { declaredMetavariables } = json;
|
|
761
|
-
|
|
762
|
-
const { Metavariable } = elements,
|
|
763
|
-
declaredMetavariablesJSON = declaredMetavariables; ///
|
|
764
|
-
|
|
765
|
-
declaredMetavariables = declaredMetavariablesJSON.map((declaredMetavariableJSON) => {
|
|
766
|
-
const json = declaredMetavariableJSON, ///
|
|
767
|
-
metavariable = Metavariable.fromJSON(json, context),
|
|
768
|
-
declaredMetavariable = metavariable; ///
|
|
769
|
-
|
|
770
|
-
return declaredMetavariable;
|
|
771
|
-
});
|
|
772
|
-
|
|
773
|
-
return declaredMetavariables;
|
|
774
|
-
}
|
|
775
|
-
|
|
776
|
-
export function nameToNameJSON(name) {
|
|
777
|
-
const nameJSON = name; ///
|
|
778
|
-
|
|
779
|
-
return nameJSON;
|
|
780
|
-
}
|
|
781
|
-
|
|
782
|
-
export function termToTermJSON(term) {
|
|
783
|
-
const termJSON = (term !== null) ?
|
|
784
|
-
term.toJSON() :
|
|
785
|
-
null;
|
|
786
|
-
|
|
787
|
-
return termJSON;
|
|
788
|
-
}
|
|
789
|
-
|
|
790
|
-
export function typeToTypeJSON(type) {
|
|
791
|
-
let typeJSON = null;
|
|
792
|
-
|
|
793
|
-
if (type !== null) {
|
|
794
|
-
const abridged = true;
|
|
795
|
-
|
|
796
|
-
typeJSON = type.toJSON(abridged);
|
|
797
|
-
}
|
|
798
|
-
|
|
799
|
-
return typeJSON;
|
|
800
|
-
}
|
|
801
|
-
|
|
802
|
-
export function frameToFrameJSON(frame) {
|
|
803
|
-
const frameJSON = (frame !== null) ?
|
|
804
|
-
frame.toJSON() :
|
|
805
|
-
null;
|
|
806
|
-
|
|
807
|
-
return frameJSON;
|
|
808
|
-
}
|
|
809
|
-
|
|
810
|
-
export function labelToLabelJSON(label) {
|
|
811
|
-
const labelJSON = label.toJSON();
|
|
812
|
-
|
|
813
|
-
return labelJSON;
|
|
814
|
-
}
|
|
815
|
-
|
|
816
|
-
export function negatedToNegatedJSON(negated) {
|
|
817
|
-
const negatedJSON = negated; ///
|
|
818
|
-
|
|
819
|
-
return negatedJSON;
|
|
820
|
-
}
|
|
821
|
-
|
|
822
|
-
export function ariableToVariableJSON(ariable) {
|
|
823
|
-
const ariableJSON = ariable.toJSON();
|
|
824
|
-
|
|
825
|
-
return ariableJSON;
|
|
826
|
-
}
|
|
827
|
-
|
|
828
|
-
export function metaTypeToMetaTypeJSON(metaType) {
|
|
829
|
-
const metaTypeJSON = (metaType !== null) ?
|
|
830
|
-
metaType.toJSON() :
|
|
831
|
-
null;
|
|
832
|
-
|
|
833
|
-
return metaTypeJSON;
|
|
834
|
-
}
|
|
835
|
-
|
|
836
|
-
export function referenceToReferenceJSON(reference) {
|
|
837
|
-
const referenceJSON = reference.toJSON();
|
|
838
|
-
|
|
839
|
-
return referenceJSON;
|
|
840
|
-
}
|
|
841
|
-
|
|
842
|
-
export function statementToStatementJSON(statement) {
|
|
843
|
-
const statementJSON = (statement !== null) ?
|
|
844
|
-
statement.toJSON() :
|
|
845
|
-
null;
|
|
846
|
-
|
|
847
|
-
return statementJSON;
|
|
848
|
-
}
|
|
849
|
-
|
|
850
|
-
export function deductionToDeductionJSON(deduction) {
|
|
851
|
-
const deductionJSON = deduction.toJSON();
|
|
852
|
-
|
|
853
|
-
return deductionJSON;
|
|
854
|
-
}
|
|
855
|
-
|
|
856
|
-
export function signatureToSignatureJSON(signature) {
|
|
857
|
-
const signatureJSON = (signature !== null) ?
|
|
858
|
-
signature.toJSON() :
|
|
859
|
-
null;
|
|
860
|
-
|
|
861
|
-
return signatureJSON;
|
|
862
|
-
}
|
|
863
|
-
|
|
864
|
-
export function identifierToIdentifierJSON(identifier) {
|
|
865
|
-
const identifierJSON = identifier; ///
|
|
866
|
-
|
|
867
|
-
return identifierJSON;
|
|
868
|
-
}
|
|
869
|
-
|
|
870
|
-
export function conclusionToConclusionJSON(conclusion) {
|
|
871
|
-
const conclusionJSON = conclusion.toJSON();
|
|
872
|
-
|
|
873
|
-
return conclusionJSON;
|
|
874
|
-
}
|
|
875
|
-
|
|
876
|
-
export function provisionalToProvisionalJSON(provisional) {
|
|
877
|
-
const provisionalJSON = provisional; ///
|
|
878
|
-
|
|
879
|
-
return provisionalJSON;
|
|
880
|
-
}
|
|
881
|
-
|
|
882
|
-
export function metavariableToMetavariableJSON(metavariable) {
|
|
883
|
-
const metavariableJSON = metavariable.toJSON();
|
|
884
|
-
|
|
885
|
-
return metavariableJSON;
|
|
886
|
-
}
|
|
887
|
-
|
|
888
|
-
export function procedureCallToProcedureCallJSON(procedureCall) {
|
|
889
|
-
const procedureCallJSON = (procedureCall !== null) ?
|
|
890
|
-
procedureCall.toJSON() :
|
|
891
|
-
null;
|
|
892
|
-
|
|
893
|
-
return procedureCallJSON;
|
|
894
|
-
}
|
|
895
|
-
|
|
896
|
-
export function mnemicContextToMnemicContextJSON(mnemicContext) {
|
|
897
|
-
const mnemicContextJSON = mnemicContext.toJSON();
|
|
898
|
-
|
|
899
|
-
return mnemicContextJSON;
|
|
900
|
-
}
|
|
901
|
-
|
|
902
|
-
export function procedureReferenceToProcedureReferenceJSON(procedureReference) {
|
|
903
|
-
const procedureReferenceJSON = procedureReference.toJSON();
|
|
904
|
-
|
|
905
|
-
return procedureReferenceJSON;
|
|
906
|
-
}
|
|
907
|
-
|
|
908
|
-
export function declaredMetavariableToDEclaredMetavariableJSON(declaredMetavariable) {
|
|
909
|
-
const declaredMetavariableJSON = declaredMetavariable.toJSON();
|
|
910
|
-
|
|
911
|
-
return declaredMetavariableJSON;
|
|
912
|
-
}
|
|
913
|
-
|
|
914
|
-
export function substitutionFromSubstitutionJSON(json, context) {
|
|
915
|
-
const { TermSubstitution, FrameSubstitution, StatementSubstitution, ReferenceSubstitution } = elements,
|
|
916
|
-
substitution = TermSubstitution.fromJSON(json, context) ||
|
|
917
|
-
FrameSubstitution.fromJSON(json, context) ||
|
|
918
|
-
StatementSubstitution.fromJSON(json, context) ||
|
|
919
|
-
ReferenceSubstitution.fromJSON(json, context);
|
|
920
|
-
|
|
921
|
-
return substitution;
|
|
922
|
-
}
|
|
923
|
-
|
|
924
|
-
export function termsToTermsJSON(terms) {
|
|
925
|
-
const termsJSON = terms.map((term) => {
|
|
926
|
-
const termJSON = term.toJSON();
|
|
927
|
-
|
|
928
|
-
return termJSON;
|
|
929
|
-
});
|
|
930
|
-
|
|
931
|
-
return termsJSON;
|
|
932
|
-
}
|
|
933
|
-
|
|
934
|
-
export function typesToTypesJSON(types) {
|
|
935
|
-
const typesJSON = types.map((type) => {
|
|
936
|
-
const typeJSON = type.toJSON();
|
|
937
|
-
|
|
938
|
-
return typeJSON;
|
|
939
|
-
});
|
|
940
|
-
|
|
941
|
-
return typesJSON;
|
|
942
|
-
}
|
|
943
|
-
|
|
944
|
-
export function rulesToRulesJSON(rules) {
|
|
945
|
-
const rulesJSON = rules.map((rule) => {
|
|
946
|
-
const ruleJSON = rule.toJSON();
|
|
947
|
-
|
|
948
|
-
return ruleJSON;
|
|
949
|
-
});
|
|
950
|
-
|
|
951
|
-
return rulesJSON;
|
|
952
|
-
}
|
|
953
|
-
|
|
954
|
-
export function labelsToLabelsJSON(labels) {
|
|
955
|
-
const labelsJSON = labels.map((label) => {
|
|
956
|
-
const labelJSON = label.toJSON();
|
|
957
|
-
|
|
958
|
-
return labelJSON;
|
|
959
|
-
});
|
|
960
|
-
|
|
961
|
-
return labelsJSON;
|
|
962
|
-
}
|
|
963
|
-
|
|
964
|
-
export function framesToFramesJSON(frames) {
|
|
965
|
-
const framesJSON = frames.map((frame) => {
|
|
966
|
-
const frameJSON = frame.toJSON();
|
|
967
|
-
|
|
968
|
-
return frameJSON;
|
|
969
|
-
});
|
|
970
|
-
|
|
971
|
-
return framesJSON;
|
|
972
|
-
}
|
|
973
|
-
|
|
974
|
-
export function axiomsToAxiomsJSON(axioms) {
|
|
975
|
-
const axiomsJSON = axioms.map((axiom) => {
|
|
976
|
-
const axiomJSON = axiom.toJSON();
|
|
977
|
-
|
|
978
|
-
return axiomJSON;
|
|
979
|
-
});
|
|
980
|
-
|
|
981
|
-
return axiomsJSON;
|
|
982
|
-
}
|
|
983
|
-
|
|
984
|
-
export function premisesToPremisesJSON(premises) {
|
|
985
|
-
const premisesJSON = premises.map((premise) => {
|
|
986
|
-
const premiseJSON = premise.toJSON();
|
|
987
|
-
|
|
988
|
-
return premiseJSON;
|
|
989
|
-
});
|
|
990
|
-
|
|
991
|
-
return premisesJSON;
|
|
992
|
-
}
|
|
993
|
-
|
|
994
|
-
export function theoremsToTheoremsJSON(theorems) {
|
|
995
|
-
const theoremsJSON = theorems.map((theorem) => {
|
|
996
|
-
const theoremJSON = theorem.toJSON();
|
|
997
|
-
|
|
998
|
-
return theoremJSON;
|
|
999
|
-
});
|
|
1000
|
-
|
|
1001
|
-
return theoremsJSON;
|
|
1002
|
-
}
|
|
1003
|
-
|
|
1004
|
-
export function variablesToVariablesJSON(variables) {
|
|
1005
|
-
const variablesJSON = variables.map((variable) => {
|
|
1006
|
-
const variableJSON = variable.toJSON();
|
|
1007
|
-
|
|
1008
|
-
return variableJSON;
|
|
1009
|
-
});
|
|
1010
|
-
|
|
1011
|
-
return variablesJSON;
|
|
1012
|
-
}
|
|
1013
|
-
|
|
1014
|
-
export function hypothesesToHypothesesJSON(hypotheses) {
|
|
1015
|
-
const hypothesesJSON = hypotheses.map((hypothesis) => {
|
|
1016
|
-
const hypothesisJSON = hypothesis.toJSON();
|
|
1017
|
-
|
|
1018
|
-
return hypothesisJSON;
|
|
1019
|
-
});
|
|
1020
|
-
|
|
1021
|
-
return hypothesesJSON;
|
|
1022
|
-
}
|
|
1023
|
-
|
|
1024
|
-
export function prefixnameToPrevixNameJSON(prefixname) {
|
|
1025
|
-
const prefixNameJSON = prefixname; ///
|
|
1026
|
-
|
|
1027
|
-
return prefixNameJSON;
|
|
1028
|
-
}
|
|
1029
|
-
|
|
1030
|
-
export function superTypesToSuperTypesJSON(superTypes) {
|
|
1031
|
-
const superTypesJSON = superTypes.map((superType) => {
|
|
1032
|
-
const abridged = true,
|
|
1033
|
-
superTypeJSON = superType.toJSON(abridged);
|
|
1034
|
-
|
|
1035
|
-
return superTypeJSON;
|
|
1036
|
-
});
|
|
1037
|
-
|
|
1038
|
-
return superTypesJSON;
|
|
1039
|
-
}
|
|
1040
|
-
|
|
1041
|
-
export function parametersToParametersJSON(parameters) {
|
|
1042
|
-
const parametersJSON = parameters.map((parameter) => {
|
|
1043
|
-
const parameterJSON = parameter.toJSON();
|
|
1044
|
-
|
|
1045
|
-
return parameterJSON;
|
|
1046
|
-
});
|
|
1047
|
-
|
|
1048
|
-
return parametersJSON;
|
|
1049
|
-
}
|
|
1050
|
-
|
|
1051
|
-
export function propertiesToPropertiesJSON(properties) {
|
|
1052
|
-
const propertiesJSON = properties.map((property) => {
|
|
1053
|
-
const propertyJSON = property.toJSON();
|
|
1054
|
-
|
|
1055
|
-
return propertyJSON;
|
|
1056
|
-
});
|
|
1057
|
-
|
|
1058
|
-
return propertiesJSON;
|
|
1059
|
-
}
|
|
1060
|
-
|
|
1061
|
-
export function judgementsToJudgementsJSON(judgements) {
|
|
1062
|
-
const judgementsJSON = judgements.map((judgement) => {
|
|
1063
|
-
const judgementJSON = judgement.toJSON();
|
|
1064
|
-
|
|
1065
|
-
return judgementJSON;
|
|
1066
|
-
});
|
|
1067
|
-
|
|
1068
|
-
return judgementsJSON;
|
|
1069
|
-
}
|
|
1070
|
-
|
|
1071
|
-
export function equalitiesToEqualitiesJSON(equalities) {
|
|
1072
|
-
const equalitiesJSON = equalities.map((equality) => {
|
|
1073
|
-
const equalityJSON = equality.toJSON();
|
|
1074
|
-
|
|
1075
|
-
return equalityJSON;
|
|
1076
|
-
});
|
|
1077
|
-
|
|
1078
|
-
return equalitiesJSON;
|
|
1079
|
-
}
|
|
1080
|
-
|
|
1081
|
-
export function statementsToStatementsJSON(statements) {
|
|
1082
|
-
const statementsJSON = statements.map((statement) => {
|
|
1083
|
-
const statementJSON = statement.toJSON();
|
|
1084
|
-
|
|
1085
|
-
return statementJSON;
|
|
1086
|
-
});
|
|
1087
|
-
|
|
1088
|
-
return statementsJSON;
|
|
1089
|
-
}
|
|
1090
|
-
|
|
1091
|
-
export function signaturesToSignaturesJSON(signatures) {
|
|
1092
|
-
const signaturesJSON = signatures.map((signature) => {
|
|
1093
|
-
const signatureJSON = signature.toJSON();
|
|
1094
|
-
|
|
1095
|
-
return signatureJSON;
|
|
1096
|
-
});
|
|
1097
|
-
|
|
1098
|
-
return signaturesJSON;
|
|
1099
|
-
}
|
|
1100
|
-
|
|
1101
|
-
export function assertionsToAssertionsJSON(assertions) {
|
|
1102
|
-
const assertionsJSON = assertions.map((assertion) => {
|
|
1103
|
-
const assertionJSON = assertion.toJSON();
|
|
1104
|
-
|
|
1105
|
-
return assertionJSON;
|
|
1106
|
-
});
|
|
1107
|
-
|
|
1108
|
-
return assertionsJSON;
|
|
1109
|
-
}
|
|
1110
|
-
|
|
1111
|
-
export function referencesToReferencesJSON(references) {
|
|
1112
|
-
const referencesJSON = references.map((reference) => {
|
|
1113
|
-
const referenceJSON = reference.toJSON();
|
|
1114
|
-
|
|
1115
|
-
return referenceJSON;
|
|
1116
|
-
});
|
|
1117
|
-
|
|
1118
|
-
return referencesJSON;
|
|
1119
|
-
}
|
|
1120
|
-
|
|
1121
|
-
export function conjecturesToConjecturesJSON(conjectures) {
|
|
1122
|
-
const conjecturesJSON = conjectures.map((conjecture) => {
|
|
1123
|
-
const conjectureJSON = conjecture.toJSON();
|
|
1124
|
-
|
|
1125
|
-
return conjectureJSON;
|
|
1126
|
-
});
|
|
1127
|
-
|
|
1128
|
-
return conjecturesJSON;
|
|
1129
|
-
}
|
|
1130
|
-
|
|
1131
|
-
export function combinatorsToCombinatorsJSON(combinators) {
|
|
1132
|
-
const combinatorsJSON = combinators.map((combinator) => {
|
|
1133
|
-
const combinatorJSON = combinator.toJSON();
|
|
1134
|
-
|
|
1135
|
-
return combinatorJSON;
|
|
1136
|
-
});
|
|
1137
|
-
|
|
1138
|
-
return combinatorsJSON;
|
|
1139
|
-
}
|
|
1140
|
-
|
|
1141
|
-
export function assumptionsToAssumptionsJSON(assumptions) {
|
|
1142
|
-
const assumptionsJSON = assumptions.map((assumption) => {
|
|
1143
|
-
const assumptionJSON = assumption.toJSON();
|
|
1144
|
-
|
|
1145
|
-
return assumptionJSON;
|
|
1146
|
-
});
|
|
1147
|
-
|
|
1148
|
-
return assumptionsJSON;
|
|
1149
|
-
}
|
|
1150
|
-
|
|
1151
|
-
export function suppositionsToSuppositionsJSON(suppositions) {
|
|
1152
|
-
const suppositionsJSON = suppositions.map((supposition) => {
|
|
1153
|
-
const suppositionJSON = supposition.toJSON();
|
|
1154
|
-
|
|
1155
|
-
return suppositionJSON;
|
|
1156
|
-
});
|
|
1157
|
-
|
|
1158
|
-
return suppositionsJSON;
|
|
1159
|
-
}
|
|
1160
|
-
|
|
1161
|
-
export function constructorsToConstructorsJSON(constructors) {
|
|
1162
|
-
const constructorsJSON = constructors.map((constructor) => {
|
|
1163
|
-
const constructorJSON = constructor.toJSON();
|
|
1164
|
-
|
|
1165
|
-
return constructorJSON;
|
|
1166
|
-
});
|
|
1167
|
-
|
|
1168
|
-
return constructorsJSON;
|
|
1169
|
-
}
|
|
1170
|
-
|
|
1171
|
-
export function metatheoremsToMetatheoremsJSON(metatheorems) {
|
|
1172
|
-
const metatheoremsJSON = metatheorems.map((metatheorem) => {
|
|
1173
|
-
const metatheoremJSON = metatheorem.toJSON();
|
|
1174
|
-
|
|
1175
|
-
return metatheoremJSON;
|
|
1176
|
-
});
|
|
1177
|
-
|
|
1178
|
-
return metatheoremsJSON;
|
|
1179
|
-
}
|
|
1180
|
-
|
|
1181
|
-
export function typePrefixesToTypePrefixesJSON(typePrefixes) {
|
|
1182
|
-
const typePrefixesJSON = typePrefixes.map((typePrefix) => {
|
|
1183
|
-
const typePrefixJSON = typePrefix.toJSON();
|
|
1184
|
-
|
|
1185
|
-
return typePrefixJSON;
|
|
1186
|
-
});
|
|
1187
|
-
|
|
1188
|
-
return typePrefixesJSON;
|
|
1189
|
-
}
|
|
1190
|
-
|
|
1191
|
-
export function substitutionsToSubstitutionsJSON(substitutions) {
|
|
1192
|
-
const substitutionsJSON = substitutions.map((substitution) => {
|
|
1193
|
-
const substitutionJSON = substitution.toJSON();
|
|
1194
|
-
|
|
1195
|
-
return substitutionJSON;
|
|
1196
|
-
});
|
|
1197
|
-
|
|
1198
|
-
return substitutionsJSON;
|
|
1199
|
-
}
|
|
1200
|
-
|
|
1201
|
-
export function metavariablesToMetavariablesJSON(metavariables) {
|
|
1202
|
-
const metavariablesJSON = metavariables.map((metavariable) => {
|
|
1203
|
-
const metavariableJSON = metavariable.toJSON();
|
|
1204
|
-
|
|
1205
|
-
return metavariableJSON;
|
|
1206
|
-
});
|
|
1207
|
-
|
|
1208
|
-
return metavariablesJSON;
|
|
1209
|
-
}
|
|
1210
|
-
|
|
1211
|
-
export function mnemicContextsToMnemicContextsJSON(mnemicContexts) {
|
|
1212
|
-
const mnemicContextsJSON = mnemicContexts.map((mnemicContext) => {
|
|
1213
|
-
const mnemicContextJSON = mnemicContext.toJSON();
|
|
1214
|
-
|
|
1215
|
-
return mnemicContextJSON;
|
|
1216
|
-
});
|
|
1217
|
-
|
|
1218
|
-
return mnemicContextsJSON;
|
|
1219
|
-
}
|
|
1220
|
-
|
|
1221
|
-
export function propertyRelationsToPropertyRelationsJSON(propertyRelations) {
|
|
1222
|
-
const propertyRelationsJSON = propertyRelations.map((propertyRelation) => {
|
|
1223
|
-
const propertyRelationJSON = propertyRelation.toJSON();
|
|
1224
|
-
|
|
1225
|
-
return propertyRelationJSON;
|
|
1226
|
-
});
|
|
1227
|
-
|
|
1228
|
-
return propertyRelationsJSON;
|
|
1229
|
-
}
|
|
1230
|
-
|
|
1231
|
-
export function declaredVariablesToDeclaredVariablesJSON(declaredVariables) {
|
|
1232
|
-
const declaredVariablesJSON = declaredVariables.map((declaredVariable) => {
|
|
1233
|
-
const declaredVariableJSON = declaredVariable.toJSON();
|
|
1234
|
-
|
|
1235
|
-
return declaredVariableJSON;
|
|
1236
|
-
});
|
|
1237
|
-
|
|
1238
|
-
return declaredVariablesJSON;
|
|
1239
|
-
}
|
|
1240
|
-
|
|
1241
|
-
export function metaLevelAssumptionsToMetaLevelAssumptionsJSON(metaLevelAssumptions) {
|
|
1242
|
-
const metaLevelAssumptionsJSON = metaLevelAssumptions.map((metaLevelAssumption) => {
|
|
1243
|
-
const metaLevelAssumptionJSON = metaLevelAssumption.toJSON();
|
|
1244
|
-
|
|
1245
|
-
return metaLevelAssumptionJSON;
|
|
1246
|
-
});
|
|
1247
|
-
|
|
1248
|
-
return metaLevelAssumptionsJSON;
|
|
1249
|
-
}
|
|
1250
|
-
|
|
1251
|
-
export function declaredMetavariablesToDeclaredMetavariablesJSON(declaredMetavariables) {
|
|
1252
|
-
const declaredMetavariablesJSON = declaredMetavariables.map((declaredMetavariable) => {
|
|
1253
|
-
const declaredMetavariableJSON = declaredMetavariable.toJSON();
|
|
1254
|
-
|
|
1255
|
-
return declaredMetavariableJSON;
|
|
1256
|
-
});
|
|
1257
|
-
|
|
1258
|
-
return declaredMetavariablesJSON;
|
|
1259
|
-
}
|
|
1260
|
-
|
|
1261
|
-
function findTypeByName(name, context) {
|
|
1262
|
-
const typeName = name, ///
|
|
1263
|
-
type = context.findTypeByTypeName(typeName);
|
|
1264
|
-
|
|
1265
|
-
return type;
|
|
1266
|
-
}
|
|
1267
|
-
|
|
1268
|
-
function findMetaTypeByName(name, context) {
|
|
1269
|
-
const metaTypeName = name, ///
|
|
1270
|
-
metaType = context.findMetaTypeByMetaTypeName(metaTypeName);
|
|
1271
|
-
|
|
1272
|
-
return metaType;
|
|
1273
|
-
}
|