diff options
Diffstat (limited to 'Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src')
-rw-r--r-- | Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.xtend | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.xtend index 4625bfbf..0c59b077 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.xtend | |||
@@ -3,25 +3,27 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse | |||
3 | import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver | 3 | import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver |
4 | import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration | 4 | import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration |
5 | import functionalarchitecture.Function | 5 | import functionalarchitecture.Function |
6 | import functionalarchitecture.FunctionalArchitectureModel | ||
6 | import functionalarchitecture.FunctionalInterface | 7 | import functionalarchitecture.FunctionalInterface |
7 | import functionalarchitecture.FunctionalOutput | 8 | import functionalarchitecture.FunctionalOutput |
8 | import functionalarchitecture.FunctionalarchitecturePackage | 9 | import functionalarchitecture.FunctionalarchitecturePackage |
9 | import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic | 10 | import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic |
10 | import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration | 11 | import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration |
11 | import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel | 12 | import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel |
12 | import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner | ||
13 | import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult | 13 | import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult |
14 | import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.ModelResult | ||
15 | import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore | ||
14 | import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic | 16 | import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic |
15 | import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic | 17 | import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic |
16 | import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace | 18 | import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace |
17 | import java.util.HashMap | 19 | import java.util.HashMap |
18 | import org.eclipse.emf.ecore.resource.Resource | 20 | import org.eclipse.emf.ecore.resource.Resource |
19 | import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl | 21 | import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl |
20 | import functionalarchitecture.FunctionalArchitectureModel | ||
21 | 22 | ||
22 | class FAMTest { | 23 | class FAMTest { |
23 | def static void main(String[] args) { | 24 | def static void main(String[] args) { |
24 | val Ecore2Logic ecore2Logic = new Ecore2Logic | 25 | val Ecore2Logic ecore2Logic = new Ecore2Logic |
26 | val Logic2Ecore logic2Ecore = new Logic2Ecore(ecore2Logic) | ||
25 | val Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic) | 27 | val Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic) |
26 | val InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic | 28 | val InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic |
27 | 29 | ||
@@ -93,6 +95,15 @@ class FAMTest { | |||
93 | ] | 95 | ] |
94 | 96 | ||
95 | var LogicResult solution = reasoner.solve(problem, vampireConfig, workspace) | 97 | var LogicResult solution = reasoner.solve(problem, vampireConfig, workspace) |
98 | |||
99 | //visualisation, see | ||
100 | // var interpretations = reasoner.getInterpretations(solution as ModelResult) | ||
101 | // | ||
102 | // for(interpretation : interpretations) { | ||
103 | // val model = logic2Ecore.transformInterpretation(interpretation,modelGenerationProblem.trace) | ||
104 | // //look here: hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor | ||
105 | // } | ||
106 | //transform interpretation to ecore, and it is easy from there | ||
96 | 107 | ||
97 | /*/ | 108 | /*/ |
98 | * | 109 | * |